Yes it is because of the drug atenolol
Atenolol is a beta-blocker
commonly prescribed to men for various heart ailments.Atenolol is known to cause sexual side effects, including impotence
, decreased sex drive and difficulty reaching orgasm. Atenolol causes impotence by blocking the sympathetic activity of the nervous system, interfering with the relaxation of penile blood vessels, making it difficult for men to achieve an erection.
You should consult your doctor for change of prescription.