Of particularly concern are antihypertensive medications for CVD (eg, digoxin, disopyramide [Norpace], gemfibrozil [Lopid]), anxiety, depression (eg, lithium, monoamine oxidase inhibitors, selective serotonin reuptake inhibitors, serotonin-norepinephrine reuptake inhibitors, tricyclic antidepressants), or psychosis (eg, chlorpromazine, haloperidol, pimozide [Orap], thioridazine, thiothixene). Antihypertensive drugs, such as diuretics (eg, spironolactone, thiazides) and beta blockers, may be associated with ED. Discontinuation or switching to alternative drugs, such as angiotensin-converting enzyme inhibitors or calcium channel blockers (eg, diltiazem, nifedipine, amlodipine), may reduce ED. The newer angiotensin II receptor antagonists may be less problematic with respect to ED, but long-term data is needed to evaluate this.
A physical cause can be identified in about 80% of cases. These include cardiovascular disease, diabetes mellitus, neurological problems such as following prostatectomy, hypogonadism, and drug side effects. Psychological impotence is where erection or penetration fails due to thoughts or feelings; this is somewhat less frequent, in the order of about 10% of cases. In psychological impotence, there is a strong response to placebo treatment.
The association between low testosterone and ED is not entirely clear. Although these 2 processes certainly overlap in some instances, they are distinct entities. Some 2-21% of men have both hypogonadism and ED; however, it is unclear to what degree treating the former will improve erectile function.  About 35-40% of men with low testosterone see an improvement in their erections with testosterone replacement; however, almost 65% of these men see no improvement. 
There are two kinds of surgery for ED: one involves implantation of a penile prosthesis; the other attempts vascular reconstruction. Expert opinion about surgical implants has changed during recent years; today, surgery is no longer so widely recommended. There are many less-invasive and less-expensive options, and surgery should be considered only as a last resort.
This inflatable penile prosthesis has 3 major components. The 2 cylinders are placed within the corpora cavernosa, a reservoir is placed beneath the rectus muscle, and the pump is placed in the scrotum. When the pump is squeezed, fluid from the reservoir is transferred into the 2 cylinders, producing a firm erection. The deflation mechanism is also located on the pump and differs by manufacturer.
A physical exam checks your total health. Examination focusing on your genitals (penis and testicles) is often done to check for ED. Based on your age and risk factors, the exam may also focus on your heart and blood system: heart, peripheral pulses and blood pressure. Based on your age and family history your doctor may do a rectal exam to check the prostate. These tests are not painful. Most patients do not need a lot of testing before starting treatment.