It is normal for a man to have five to six erections during sleep, especially during rapid eye movement (REM). Their absence may indicate a problem with nerve function or blood supply in the penis. There are two methods for measuring changes in penile rigidity and circumference during nocturnal erection: snap gauge and strain gauge. A significant proportion of men who have no sexual dysfunction nonetheless do not have regular nocturnal erections.
Before taking any medication for erectile dysfunction, including over-the-counter supplements and herbal remedies, get your doctor's OK. Medications for erectile dysfunction do not work in all men and might be less effective in certain conditions, such as after prostate surgery or if you have diabetes. Some medications might also be dangerous if you:
The nerves and endothelium of sinusoids and vessels in the penis produce and release transmitters and modulators that control the contractile state of corporal smooth muscles. Although the membrane receptors play an important role, downstream signaling pathways are also important. The RhoA–Rho kinase pathway is involved in the regulation of cavernosal smooth muscle contraction. 
Cavernosography measurement of the vascular pressure in the corpus cavernosum. Saline is infused under pressure into the corpus cavernosum with a butterfly needle, and the flow rate needed to maintain an erection indicates the degree of venous leakage. The leaking veins responsible may be visualized by infusing a mixture of saline and x-ray contrast medium and performing a cavernosogram. In Digital Subtraction Angiography (DSA), the images are acquired digitally.
Instead of the hesitation with which he had accosted the cardinal a quarter of an hour before, there might be read in the eyes of the young king that will against which a struggle might be maintained, and which might be crushed by its own impotence, but which, at least, would preserve, like a wound in the depth of the heart, the remembrance of its defeat.
Exercise and lifestyle modifications may improve erectile function. Weight loss may help by decreasing inflammation, increasing testosterone, and improving self-esteem. Patients should be educated to increase activity, reduce weight, and stop smoking, as these efforts can improve or restore erectile function in men without comorbidities. Precise glycemic control in diabetic patients and pharmacologic treatment of hypertension may be important in preventing or reducing sexual dysfunction. 
Injection therapy involves injecting a substance into the penis to enhance blood flow and cause an erection. The Food and Drug Administration (FDA) approved a drug called alprostadil (Caverject) for this purpose in July of 1995. Alprostadil relaxes smooth muscle tissue to enhance blood flow into the penis. It must be injected shortly before intercourse. Another, similar drug that is sometimes used is papaverine—not yet been approved by the FDA for this use. Either drug may sometimes cause painful erections or priapism (uncomfortable, prolonged erections) that must be treated with a shot of epinephrine.
Another study compared the response of surgically and medically castrated rabbits to vardenafil with that of control rabbits.  Castrated rabbits did not respond to vardenafil, whereas noncastrated rabbits did respond appropriately. This result suggests that a minimum amount of testosterone is necessary for PDE5 inhibitors to produce an erection.
With sex therapy, your counselor looks at the sexual problems you and your partner are having. Sex therapy works with problems such as performance anxiety, which means that you worry so much about whether you will be able to have sex that you are not able to. It also helps when you have erection problems that are not due to physical or drug problems, or premature ejaculation (you come too quickly). It may help you to reach orgasm or to learn to relax enough to avoid pain during sex. Counseling can help you to adjust to the treatment you and your doctor choose.
Or, perhaps, since it's been only eight months, it might actually scare you a bit. It can be unsettling when someone falls head over heels. It can be hard to trust that kind of enthusiasm, especially if you've been burned by someone who went from hot-and-heavy to suddenly cold. Even if you're crazy about him, you might need to slow things down a little. Or maybe it's harder for you to say than it is for him — and that's why it rubs you wrong.
Yohimbine: The main component of an African tree bark, yohimbine is probably one of the most problematic of all natural remedies for ED. Some research suggests that yohimbine can improve a type of sexual dysfunction that is linked with a drug used to treat depression. However, studies have linked yohimbine to a number of side effects, which can include anxiety, increased blood pressure, and a fast, irregular heartbeat. Like all natural remedies, yohimbine should only be used after advice and under supervision from a doctor.
Achieving an erection is a complicated process, requiring transmission of sensations from the genital area to the nervous system and the return of nervous impulses to the muscles and blood vessels of the penis. Anything that interferes with this interchange, such as disease or injury of the blood vessels, muscles, or nerves, can make achieving and maintaining an erection difficult. Psychological factors, such as anxiety and depression, can also interfere with erectile function. Anxiety and depression may also develop as a consequence of impotence.
Conditions that may be associated with ED include diabetes, [25, 26, 27] hypertension,  , and CAD, as well as neurologic disorders, endocrinopathies, benign prostatic hyperplasia,  , sleep apnea  , COPD,  and depression (see Table 1 below). [32, 33, 34, 35] In fact, almost any disease may affect erectile function by altering the nervous, vascular, or hormonal systems. Various diseases may produce changes in the smooth muscle tissue of the corpora cavernosa or influence the patient’s psychological mood and behavior.
The mechanisms by which testosterone plays a role in erectile function are not completely understood. A study evaluating the effect of testosterone on erections in surgically castrated rabbits and control animals, in which the rabbits’ intracavernosal pressures were compared after cavernosal nerve stimulation, determined that castrated rabbits had much lower pressures after stimulation than control rabbits did.  Notably, the pressures increased when castrated rabbits received exogenous testosterone replacement.
The dorsal artery provides for engorgement of the glans during erection, whereas the bulbourethral artery supplies the bulb and the corpus spongiosum. The cavernous artery effects tumescence of the corpus cavernosum and thus is principally responsible for erection. The cavernous artery gives off many helicine arteries, which supply the trabecular erectile tissue and the sinusoids. These helicine arteries are contracted and tortuous in the flaccid state and become dilated and straight during erection. 
Phosphodiesterase inhibitors: This class of medications includes sildenafil, tadalafil, and vardenafil. They work by inhibiting an enzyme called phosphodiesterase type 5 (PDE-5), allowing more blood to enter the penis and helping to produce an erection. These medications are often taken before sex and will cause an erection only when the man is sexually stimulated.
So not only are erectile problems common, they're nothing for you or your special friend to be freaked out about. Check out the nine most common reasons that dudes sometimes can't get it up, and get ready to become the soothing voice of reason the next time the guy you're with has a hard time pitching his tent in your happy valley. Everything (and every penis) is gonna be fine!
When we say it’s a barometer of men’s health, it’s a signal. It’s an indicator that things may be right or not. And so when a man develops an erectile problem– and we’re talking about something that is occurring over time. It’s not something that just occurred overnight. When it occurs overnight, it’s more often than not a psychogenic, an anxiety reaction.
Normal erectile function depends on the release of NO and endothelial-dependent vasodilation of the penile arteries. The ‘artery size’ hypothesis, first described by Dr Montorsi, offers an explanation why men are more likely to develop ED before a myocardial infacrtion. It is believed that atherosclerosis affects all vascular beds equally but smaller arteries are more likely to become occluded than larger arteries.31 32 The penile arteries are 1–2 mm while the coronary arteries are 3–4 mm. Thus, the same degree of endothelial dysfunction and atherosclerosis is more likely to occlude blood flow in the penile arteries compared with the coronary arteries. The penile arteries therefore serve as a sensitive indicator for subsequent CVD. This theory is supported by the fact that ED occurs approximately 3 years prior to cardiac symptoms in virtually all patients with chronic coronary syndrome whereas patients with acute coronary syndrome have a much lower prevalence of sexual dysfunction.32
He can follow the common general physical advice: Sleep well, eat well, exercise, and moderate or abstain from drinking and drugs. He can also visit the doctor to see if there’s any medical reason for his condition (anything from heart disease to diabetes and obesity). Sometimes, impotence is a side effect of prescription drugs. If his anxiety is extreme, it never hurts to see a professional therapist. Whenever there’s even a chance of a medical problem, my advice is always: Why not check with a professional?
I'd recommend the second option. In any long-term relationship, there will come a time when you flirt a little too much. Technology makes those little transgressions seem much more major because there's digital proof. (I'm guessing that you would never have flashed him in the real world. Would you?) Maybe you should just learn from your experience and save your boyfriend the drama. Understand that you made a mistake, and keep your breasts to yourself.
Some may use alcohol as a way to get into the mood and overcome some of the nerves associated with having sex, but too much of a good thing can actually backfire. In fact, having a long history of alcohol abuse may lead to long-term erectile dysfunction. As many as 70 percent of men with chronic erectile dysfunction also have a history of alcohol abuse.
None of the ED drugs is safe to take with cardiac drugs called nitrates because it could cause a dangerous drop in blood pressure. Drugs that many men take for urinary symptoms, called alpha blockers, can also lower blood pressure, so take them at least four hours apart from ED drugs. Your doctor may start you on a smaller dose of the ED drug if you already take an alpha blocker, or may recommend the alpha blocker tamsulosin (Flomax), which affects blood pressure less.
Only a small proportion of cases of erectile dysfunction are caused by hormone abnormalities. The most frequent hormone abnormality is a reduced level of the male sex hormone testosterone required to get an erection which can be restored by appropriate hormone replacement. It's unwise to take testosterone preparations unless you've had tests that confirm a deficiency.
Cosgrove et al reported a higher rate of sexual dysfunction in veterans with posttraumatic stress disorder (PTSD) than in veterans who did not develop this problem.  The domains on the International Index of Erectile Function (IIEF) questionnaire that demonstrated the most change included overall sexual satisfaction and erectile function. [43, 44] Men with PTSD should be evaluated and treated if they have sexual dysfunction.
Relationship problems can make it difficult for you to get or stay hard when you’re attempting to have sex with the person you’re in a relationship with. However, if you have this problem and you’re in a relationship that doesn’t mean your relationship is necessarily the reason. There are lots of other reasons you might not be able to get or stay hard (see above).
*All medications have both common (generic) and brand names. The brand name is what a specific manufacturer calls the product (e.g., Tylenol®). The common name is the medical name for the medication (e.g., acetaminophen). A medication may have many brand names, but only one common name. This article lists medications by their common names. For information on a given medication, check our Drug Information database. For more information on brand names, speak with your doctor or pharmacist.
THIS TOOL DOES NOT PROVIDE MEDICAL ADVICE. It is intended for general informational purposes only and does not address individual circumstances. It is not a substitute for professional medical advice, diagnosis or treatment and should not be relied on to make decisions about your health. Never ignore professional medical advice in seeking treatment because of something you have read on the WebMD Site. If you think you may have a medical emergency, immediately call your doctor or dial 911.