The language
Time and rest
How a program moves through time, how rest works between sets and between sessions, and how to lay out a training week.
A training program is not only a list of what to do; it is also a statement of
when to do it. Ninety seconds between sets, a day off between sessions,
three sessions a week. In Coach all of that is said with one exec: rest.
Resting
rest comes with the standard library, so a program
imports it once and calls it with how long the athlete should rest:
import "coach/common/rest.cl"
rest(90|s|)
rest(2|day|)
The time is a measurement of time in any unit:
seconds, minutes, hours or days. The athlete sees the rest in the unit you
wrote it in, so pick the one that reads naturally: 90|s| rather than
1.5|min|, 2|day| rather than 48|h|.
On the athlete’s phone a rest looks different depending on how long it is:
- Short rests, up to five minutes, run as a countdown timer. When it reaches zero it chimes and the program moves on by itself.
- Longer rests simply show how long to rest. The athlete continues when they come back for the next session.
Because rest is an exec like any other, it can be called with any expression.
Here the rest after each set depends on how hard the set was:
import "coach/common/rest.cl"
import "coach/strength/squat.cl"
repeat 5 {
let s = squat([weight: 100|kg|, reps: 5], [reps: true], [location: true])
rest(s.reps < 5 ? 3|min| : 2|min|)
}
Program time
Every program runs on its own clock, which we call program time. It starts at zero when the program starts and moves forward by every duration the program specifies: a three-minute rest, a 45-second plank, a 30-minute run. A set of five reps specifies no duration, so it takes no program time.
This is what the simulator’s plan uses to lay a program out in days and weeks.
Counting days
Everything between two rests of a day or more is one session. There is one rule to remember: a rest of a day or more is counted from the start of the session it follows. It does not matter how long the session took; the next one starts that many days later, at the same time of day.
That means rest(1|day|) after a session puts the next session on the very
next day, with no day off in between. For one day off, rest for two days:
| Between sessions | Write |
|---|---|
| none, train the next day | `rest(1 |
| one day off | `rest(2 |
| two days off | `rest(3 |
Laying out a week
Most programs repeat a weekly rhythm, and the rests of a week always add up to seven days. A few common layouts:
| Sessions | Days | Rests after each session |
|---|---|---|
| 2 a week | Mon, Thu | `3 |
| 3 a week | Mon, Wed, Fri | `2 |
| 4 a week | Mon, Tue, Thu, Fri | `1 |
| 5 a week | Mon to Fri | `1 |
Example
Three full-body sessions a week, Monday, Wednesday and Friday, for eight weeks:
import "coach/common/rest.cl"
import "coach/strength/squat.cl"
group session() {
@title = "Full body"
squat([weight: 80|kg|, reps: 5], [reps: true], [location: true])
}
repeat week:8 {
repeat day:3 {
session()
rest(day == 3 ? 3|day| : 2|day|)
}
}
The inner repeat counts the sessions of the week. After the first and the
second it rests for two days, and after the third, for three, which brings the
athlete back to Monday.
When you have written a weekly schedule, check it in the simulator’s plan. It shows each session on its day, so a miscounted rest stands out immediately.
Rests that never come
A program that never rests never moves forward in time. That is fine for a
single session, but a program that loops over sessions without a rest puts
them all on the same day. If the plan shows hundreds of sets
on day one, a missing rest is the usual reason.