In this case we would recommend going to the mikveh. As you intuited, the harchakot could be adding tension to their relationship as well as making it more difficult to care for her husband. Mikveh immersion for the purpose of other forms of intimacy is permitted. The only caveat is to avoid hotza'at zera levatalah, which is not at issue here. A physically affectionate relationship is not built only on relations.
However, based on what you write, the situation would seem to demand more than halachic intervention. Counseling, or a spouses of the ill support group, might help your relative cope with her situation and her depression. In terms of their relationship, marital counseling might also be in order. We hope that she will consider taking these steps to improve her situation. Referrals for frum counselors can be found through Nefesh International, www.nefesh.org.
It is not completely clear from your questions exactly what sexual difficulties your cousin's husband is suffering. Ejaculation is not necessary to have marital relations. If the problem is lack of erection, there are often medical interventions that can be used to improve the situation. Therefore, in addition to the marital counseling we have suggested, we would also encourage your cousin to discuss this side effect of her husband's condition and/or treatment with the physicians who are treating him. Cancer specialists often work in a multidisciplinary team that includes nurses or social workers designated to deal with these specific issues.