The study of how sexual orientation has been viewed throughout history and how it has changed over time.