Sex can be dangerous, even deadly if your partner has plans to eat you. When the male orb-web spider has its first, and sometimes last, sexual encounter it has a trick up its sleeve: detachable genitalia which keep pumping even after their owner's moved on.

The orb-web spider Nephilengys malabarensis is sexually cannibalistic and the male has detachable genitals. These spiders have at most two chances to mate: They have a pair of sperm-transferring organs, actually called their "palps" but analogous to a penis, which detach from their bodies when they disengage from mating — either when the female pushes them away and possibly eats them or they successfully run away to risk death another day.

For spiders this breakage of male’s sperm-transferring organ is common, says researcher Daiquin Li, of the University of Singapore, but it's usually just the tip.

"However, some spider species exhibit extreme genital mutilation or the 'eunuch phenomenon,' where males castrate their entire pedipalp(s) during copulation," Li, author of a new study on this process, told LiveScience.

Extreme sacrifice

This eunuch behavior is a pretty confusing concept to most researchers: They (like most men reading this) really couldn't think of a way that having a break-off penis could be a good thing. They previously thought that this full breakage was just a mistake (since what good, evolutionarily speaking, is a male unable to have sex?), but Li believes it must have some advantage for the male — possibly storing or transferring more sperm.

The researchers collected 50 virgin orb-web spiders — 25 each, male and female — from Singapore and raised them in the lab until they reached sexual maturity. They were mated in pairs by placing the smaller males into the female's web. The researchers recorded how long they mated, who stopped the mating, and how much palp broke off. Eighty eight percent of the time the spiders left the whole palp in the female.

After mating they left the palp in the female for different amounts of time (up to 20 minutes), then measured how much sperm was left in the palp and in the female's sexual organs. The researchers found that the detached genitalia continued to transfer sperm after sex ended.

"About 30 percent of sperm were transferred to the females before the palp breakoff, and about 70 percent of sperm were still left in the broken palp," Li said. "In our experiments, it took about 20 minutes to transfer about 85 percent of [the] sperm."

Prolonging sperm transfer

This means that after the female frightens the male away, or eats him, his genitalia remain in place and can continue sending sperm her way, even long after sex is over — in the lab it took the females about seven hours to get the palp out. This elongated sperm transfer doesn't happen if they just break off the tip of the palp.

"This mate-plugging can partially serve as a plug to prevent other males" from mating with the female, Li said. "In addition, the eunuch males [if they survive] become more aggressive and guard the female so that this can make sure the sperm left in the severed palp can be transferred to the female after breakage," probably leading to better success at becoming a father, even in the afterlife.

Spiders aren't the only species to Lorena Bobbit their own genitals, and Li thinks the same sperm-transfer bonus may apply in other species, as well: "This may apply to other spider species and other animals in which males castrate their genitals, for example, in fire ants, ground beetles, scorpions and cephalopods," he said.

The study will be published Feb. 1 in the journal Biology Letters.

You can follow LiveScience staff writer Jennifer Welsh on Twitter @microbelover. Follow LiveScience for the latest in science news and discoveries on Twitter@livescienceand onFacebook.