When something goes wrong at work it’s normal to take that negative experience and hold onto it for the rest of the day — or maybe even for the whole week. That tendency is a product of how our brains are wired. Our view of the world has a fundamental tendency to tilt toward the negative.

There are however psychological tools that allow people to change that and reframe their experiences. When it comes to optimistic thinking, the tools to turn our negative situations into positive ones are in our own hands.

Our minds may be built to look for negative information and to hold onto it, but we can also retrain our minds if we put some effort into it — and start to see that the glass may be a little more full than we initially thought. Here are a few ways you can train your mind to reframe your failures, let go of negativity and focus on the good:

Practice “gain framing”

The “framing effect” is a psychological concept that’s all about howyou frame your stories to others, that how you recall your own experiences can alter the way you see them. There’s a lot of research in the social sciences showing that depending on how you describe a glass to people, it changes how they feel about it. If you describe the glass as half-full, this is called a ‘gain frame,’ because you’re focusing on what’s gained. But if you describe the same glass as half-empty, it’s a loss frame. When we use gain framing to describe our experiences to others, we start to see the given situation in a positive light. It’s about learning to rehearse good news and share it with others.

Acknowledge one good thing

Reframing a negative experience isn’t always easy. When you’re upset, it can help to focus on a different experience entirely — one that you feel good about. While it’s easy to assume that venting will help get rid of your negative emotions, dwelling instead on one good thing that happened that day can prompt your brain to switch directions — which is ultimately very helpful. There’s research indicating that just writing for a few minutes each day about things you’re grateful for can dramatically boost your happiness and well-being.

Respond counterintuitively

How we react inthe moment can make a significant difference, too. What if the next time somebody snapped at you, you forgave them? By responding counterintuitively, offering ourselves time to reframe, we can stop our brains from the cycle of dwelling on the negative, and spreading it. One mean comment can stick with somebody all day… and that tends to propagate itself. How we respond can determine how our minds see the experience in retrospect.