Performing a pelvic exam without consent on an anesthetized woman, even for teaching purposes, is unethical and considered sexual battery in some jurisdictions.
Some psychiatrists feel that outpatient commitment has a legitimate role in treating mentally ill individuals, especially those who are not even aware of their disease.