Many people embrace happiness but try to push aside sadness and anger. Our culture encourages this—books about how to be happy frequently find their way onto best-seller lists, and “the pursuit of happiness” is written into our Declaration of Independence. Sadness and anger are viewed as problems to overcome on the road to happiness.

But these so-called “negative” emotions can be useful. Here are some of the powerful benefits of bad moods and how to use them to your advantage…

Bad moods make us more careful and less gullible. When people are happy, they tend to have an “everything will be all right” mentality—which can get them into trouble when everything is not all right. When people are ­unhappy, on the other hand, their minds are on a higher state of alert, carefully analyzing what they see and hear. That’s a useful mind-set to have when digging through potentially important details or dealing with slick salespeople.

What to do: If you soon will need to be detail-oriented or skeptical—for ­example, if you’re on your way to negotiate a major purchase—you can intentionally put yourself in a negative mood. Recall an unhappy but not devastating memory, such as a time when your career hit a rough patch. Or listen to a piece of music that always makes you feel melancholy—Samuel Barber’s “Adagio for Strings” may be a good choice.

Bad moods make us more convincing. People who are in negative moods are better able to formulate arguments that sway other people to their points of view, according to a study published in Journal of Personality and Social Psychology. This is probably because people are more detail-­oriented and attentive when they are in bad moods, as noted above, and thus more likely to provide convincing evidence and respond effectively when doubts are voiced. When people feel happy, they are prone to overlooking such details out of potentially misplaced optimism that everyone is sure to see things their way.

What to do: Do not just give yourself a pep talk before you make a presentation (or write a letter or a report) that is intended to bring people around to your way of thinking. Think about the challenges that your position could face. Who might disagree? Why might they disagree? Focusing on the challenges that lie ahead tends to temper overly positive moods.

Bad moods boost memory. Ever wondered how a spouse who cannot remember where he put his keys can remember every detail of all 393 arguments you have had in the past 10 years? It’s because human memory is sharpest at times of unhappiness. A study published in Journal of Experimental Social Psychology found that people’s memories were stronger on gloomy-weather days than on sunny ones, for example. This finding likely stems from the fact that memory was most crucial for the survival of our early ancestors during their unhappiest moments. If an early human was about to be attacked by a predator, for example, his life might have depended on being able to remember which defensive tactics worked best against that predator in prior attacks…and if his watering hole dried up, his survival might have depended on remembering where else water could be found.

What to do: If you are struggling to remember something, allow yourself to experience sadness or anger, perhaps by recalling a sad memory or listening to a sad song. If you still cannot remember, do something relaxing and mind-clearing such as taking a warm shower or a quiet walk in nature. The period of transition immediately following a sad mood is another common time for “aha” breakthroughs.

Bad moods encourage perseverance. When people are in good moods, they see little reason to push themselves hard—why bother when everything a­lready seems great? Unhappy people often are more likely to put in extra effort because they see problems all around them and are motivated to do what it takes to make things better.

What to do: If you catch yourself about to throw in the towel on a tough task when you’re feeling happy, use the sad-memory or music strategy mentioned above to reset your mood, and then give it another go.

Bad moods make us more polite and empathic. When people feel happy, they can become so caught up in their own positive moods that they may fail to fully notice the needs, deeds and moods of the people around them, leading to an apparent lack of empathy and politeness. A happy person might fail to ask his friend, “What’s wrong?” because he missed the slight quiver in his friend’s voice that would have alerted him to the fact that something was wrong. People who are feeling unhappy (but not deeply depressed) are more likely to notice ­details such as these.

What to do: When you are in a good mood, make a conscious effort to evaluate your initial interpretations of other people’s words and actions.

Bad moods can help us come to terms with our priorities and ­problems. Bad moods can be like beacons shining a light on core beliefs and key concerns that we might not yet have fully acknowledged.

What to do: When you find yourself naturally feeling sad or angry, take the time to explore why you feel this way and what you could do about it. For example, perhaps you feel deeply hurt because you did not receive as much recognition as you expected for a good idea. Does the person who didn’t give you your due chronically fail to do so? If so, it might be time to confront this person or bring your good ideas to someone else. Or maybe the problem is not with this person but that you feel generally undervalued. Perhaps volunteering in your free time or serving as a mentor would help.