The anticipated physical torture of marathon training is enough to keep most sane people away from training for the vaunted 26.2 mile distance. However, what most non-marathoners don’t realize is that the mental anguish that accompanies marathon training can often be a more difficult foe than the physical grind of running countless miles.

After a string of rock-solid workouts, just one bad run leaves even the best marathoners shuffling home on their cool down with their head down in despair. The thought process on these dreaded days is the same whether you’ve run 2:14 or 4:14: “Does this mean I’m not fit? Am I overtraining? Do I need to change something in my training?”

Fear, frustration, and self-doubt. This swirl of emotions can be enough to drive a runner crazy and often stick with you for days after – bleeding negative thoughts into subsequent workouts and creating a downward spiral of bad runs.

So, how do you deal with a bad workout? How do you pull yourself out of the marathon funk in the middle of a training segment – when the mileage is high and the end is not in sight? In this article, we’ll outline the three most common reasons for having bad workout, how to recognize which one is afflicting you, and how to reset and get back on the right track.

When a bad workout is a result of accumulated fatigue

Marathon training is a delicate balance of putting in the most amount of mileage you can handle with the rest and recovery you need to continually make gains. In essence, you’re walking a tight rope each day, just hoping to maintain that optimal ratio and be recovered in time for your next session.

As a consequence, you’ll often build-up what is called “accumulated fatigue”, which is really just a simple way of expressing the fact that your body doesn’t recover overnight in preparation for your next run. You’ll always carry some fatigue from one training session to the next, more so after hard days than easy days.

Marathon training capitalizes on the concept of accumulated fatigue because most marathon specific workouts are considered “moderate” intensity rather than all-out, lung busting affairs like a set of 400 meter repeats. For example, running 8 miles at marathon pace isn’t difficult when you’re fully rested and amped to run hard, but combine that 8 miles with the fatigue from your previous long run and you can begin to simulate running on tired legs and with low glycogen stores – two critical components of a marathon race.

Therefore, if you’re in the midst of hard marathon training, you’re bound to have two or three workouts during a 12-16 week cycle where you carry too much fatigue from one workout to the next and really struggle – it happens to almost everyone.

The easiest way to identify when a terrible workout is the result of accumulated fatigue is to look back at your training log and count the number of hard workouts or long runs you’ve had in the last 14 days. If that number is 6 or more or you’ve performed at an intensity or volume that you’ve never done before, the cause of your poor workout is most likely the cause of accumulated fatigue.

What to do

When this happens, your best bet is to add a little extra recovery before your next hard workout or long run. Most of the time, simply adding in an extra recovery day or two before your next hard workout will allow your body to get back in balance without sacrificing your long-term progress. In fact, the extra rest will probably allow you to nail your next big workout and reboot your confidence.

When a bad workout is just a bad workout

It may sound cliché, but sometimes a bad workout is just a bad workout. The body is a complex organism with hundreds of complicated physiological processes occurring every second. Combine the body’s unpredictability with a stressful day at the office or hampered sleep and you have the recipe for a tough day on the roads.

Sometimes, you can easily identify the cause of a bad day – lack of sleep, a stressful work trip, or the start of a slight cold. Luckily, these days aren’t as frustrating because at least you have an answer for what happened and you can quickly put it behind you.

However, sometimes you can’t find any good reason for a miserable workout – you had plenty of recovery and you felt great heading into the workout. These are the days when you often feel the most frustrated, but they’re also the best opportunity for you to grow and learn about yourself as a runner.

What to do

When you hit speed bumps in your training that you can’t attribute to accumulated fatigue or some outside source, my recommendation is to “press the reset button”. Envision your mind and body to be like a video game with a reset switch. Press the reset button and wipe the bad workout from your mind and start the next day fresh. In doing so, you prevent the negative thoughts from creeping into your next run and you keep the progress moving forward, not backward.

The two worst things you can do after a dreadful workout are to dwell on the failed run or try to make up the workout the next day. This will only lead to a downward spiral that causes your one bad day to turn into two or three bad workouts.

When a bad workout is a sign you need to back off

All runners wish they had the ability to train hard 365 days a year. Taking downtime after a race or needing to schedule a rest week in the middle of a training cycle isn’t a runner’s idea of a great time. However, recovery is essential to both short-term and long-term progression. Sometimes, a bad workout is your body’s way of letting you know that it needs some extended recovery time or a “down week” in training.

The difference between accumulated fatigue and the body signaling for a down week is that you’ll have more than one bad workout in a row when you need a down week.

Sometimes, it may not even be that terrible of a workout, but rather a few mediocre performances in a row. When this happens, you’ve crossed over that delicate line between optimal training and fatigue and you need an extended recovery period to get back on track.

If you have two or three bad or mediocre workouts in a row, take a look back at your training log and locate the last time you had at least 4-5 very easy training days or a scheduled down week. If you have to go back 4 weeks or longer to find your last recovery week, your body is telling you that it’s time to take a little extra recovery.

What to do

You need to have the courage and mental toughness to take a recovery week and realize it’s only going to make you a better runner in the long-term. This is easy advice to dispense in an article, but it’s difficult for many runners to swallow. However, the legendary coach Alberto Salazar sums it up perfectly:

“You’ve got to have the mental toughness and confidence in yourself where you believe that you can take those days off and you can recover and you can run great. A lot of what we see in athletes that just train all the time and never give themselves adequate recovery is often portrayed as toughness. What I’ve realized over the years is it really is a weakness. It’s an insecurity that you’re not good enough to recover like other athletes: I’m not good enough to do that; I need to keep training; I can’t take time off; I can’t take easy days.”

Don’t fall into the same trap and have the courage and sensibility to give your body a down week when it’s clearly telling you it’s needed. In the long-term, you’ll be a much better runner.

Having a bad day on the roads is tough no matter how you look at it. However, if you take the time to examine your training log, identify the potential issue, and then have the courage to take the necessary steps to get yourself back on track, that one bad workout will remain a mere blip in the training cycle.

A version of this post originally appeared at competitor.com