You have to get under someone to get over someone.

This advice often follows the end of a relationship, encouraging people to take advantage of their recently single status with a casual hookup.

And although rebound sex can make for a good plotline in a romantic comedy or an embarrassing anecdote your friends won’t let you forget, it hasn’t really been the subject of scientific research until now.

A recent psychological study found that up to one-third of college students have rebound or revenge sex within a month of ending a relationship.

Psychologists from the University of Missouri studied 170 undergraduate students who had gone through a breakup in the last eight months.

The students filled out online journals for a 10-week period about their sexual exploits and emotions.

Thirty-five percent of the students said they’d had sex to get over their ex, and 25 percent said they’d had revenge sex, according to the study, which was published in February’s issue of Archives of Sexual Behavior.

Those who were left by their partner were more upset and angry, which led them to be more likely to have sex to cope with negative emotions.

Although jumping into bed with someone 30 minutes after a breakup might not be a good idea, it’s still unclear whether rebound sex can really help people emotionally.

Students may actually be having greater difficulty moving on and starting new relationships, said Lynne Cooper, one of the psychologists conducting the study.

The people who reported having rebound or revenge sex after a breakup were more likely to engage in other risky sexual behaviors like sex with strangers and having sex with lots of new people.

“I think it’s just something that people think will make them feel better,” said Emily Cooper, an 18-year-old UF exploratory freshman, “but in the end it just makes them feel worse.”

[A version of this story ran on page 7 on 2/6/2014 under the headline "Having rebound sex to get over your ex could delay your recovery"]