To my way of thinking, marriage is an implied contract where the partners agree to fulfill each other's needs in return for fidelity and exclusivity. The problem is of course that although things may initially be of a sexual nature they often develop into an emotional one. That's how many relationships develop into marriages, too. Unfortunately, relationships based primarily on sex are the ones which are most likely doomed to eventual failure when the initial fire dies away and there's little or nothing else on which to maintain that relationship. I think people place too much importance on sex.
Sex is among the most basic of human instincts and needs.
Combine that with the artificial moralities of social and religious beliefs which often put a stranglehold on those instincts and you have a recipe for stress and conflict. If society ever progresses to the point where sex is not a stigmatizing subject, we'll likely see a rapid decline in the number of problems currently associated with it.