The relationship commitment equation weighs positives minus negatives against investment, and then subtracts the perception of alternatives. The same formula explains why browsing LinkedIn makes you want to quit your job — and why a dwindling dating pool makes an ex's stock mysteriously rise.