Sexual problems are defined as difficulty during any stage of the sexual act (which includes desire, arousal, orgasm and resolution) that prevents the individual or couple from enjoying sexual activity.
Sexual difficulties may begin early in a person's life, or they may develop after an individual has previously experienced enjoyable and satisfying sex. A problem may develop gradually over time, or may occur suddenly as a total or partial inability to participate in one or more stages of the sexual act. The causes of sexual difficulties can be physical, psychological or both.
Emotional factors affecting sex include both interpersonal problems and psychological problems within the individual. Interpersonal problems include marital or relationship problems, or lack of trust and open communication between partners. Personal psychological problems include depression, sexual fears or guilt, or past sexual trauma.
Physical factors contributing to sexual problems include: 
Drugs, such as alcohol, nicotine, narcotics, stimulants, antihypertensives (medicines that lower blood pressure), antihistamines, and some psychotherapeutic drugs (drugs that treat psychological problems such as depression).

Injuries to the back

Enlarged prostate gland

Problems with blood supply

Nerve damage (spinal cord injuries)

Failure of various organs (heart and lungs)

Endocrine disorders (thyroid, pituitary, or adrenal gland problems)

Hormonal deficiencies (low testosterone, estrogen, or androgens)
Possible signs of sexual dysfunction include:

Lack of interest in sex (loss of libido)

Inability to feel aroused

Inability to attain an erection

Inability to maintain an erection adequately for intercourse

Delay or absence of ejaculation, despite adequate stimulation

Inability to control timing of ejaculation
Diagnostic tools for sexual dysfunction include:
Physical Exam Identify predisposing illness or conditions
History Uncover any history of prior sexual trauma
Types of treatment for sexual dysfunction include:
Medication Increases blood flow to the penis
Surgery Penile Implants for men who cannot retain an erection with medication
Physical Therapy May prove helpful for some people experiencing sexual dysfunction due to physical illnesses, conditions or disabilities.
Information for this section was compiled with the help of the following Web site. Please see them for more information on sexual dysfunction.
U.S. National Library of Medicine