Agrexophrenia is the inability to perform sexually because someone is or may be nearby.
It’s unknown when the term originated, but one of its earliest publicized appearances was in 1967, when Jacob E. Schmidt included it in his “Lecher’s Lexicon: A Sexy, Sizzling Erotic Dictonary.” He said agrexophrenia occurred when people knew other people were close.
Peter Novobatzky and Ammon Shea expounded on the term in their 1999 book “Depraved English,” noting that people with agrexophrenia struggle to perform because they fear being overheard. This may be a legitimate concern, because people are nearby, or not.