Can you read the definition and pick out the right pieces?
Recall Solution 1.1
What we do: apply the definition Gt=∑k=0∞γkRt+k+1 with t=3.
The reward that follows the action at t=3 is Rt+1=R4 — notR3. Plugging k=0,1,2:
G3=R4+γR5+γ2R6+⋯Why: the action at time tcauses the reward Rt+1; the reward you already collected getting tot is history and never appears in Gt.
Recall Solution 1.2
What we do: compare each γ against the endpoints 0 and 1 (recall the allowed range 0≤γ<1).
(a) γ=0 → myopic. Every γk with k≥1 is 0, so only Rt+1 survives.
(b) γ=0.999 → far-sighted. Weights decay only 0.1% per step, so rewards ~1000 steps out still count.
(c) γ=0.5 → myopic-ish (short-sighted). Weight halves each step; by step 4 it's already 1/16.
What we do: factor the constant out; it becomes a pure geometric series (allowed since γ=0.8<1).
Gt=∑k=0∞γk⋅2=2∑k=0∞0.8k=2⋅1−0.81=2⋅5=10.Why: constant reward R gives R⋅1−γ1. Notice an infinite stream of +2's is worth only 10 — discounting tames infinity into a finite number.
Recall Solution 2.2
What we do: the return is always the infinite sum, but here every reward from Rt+5 onward is 0, so the infinite tail contributes nothing and truncation is exact:
Gt=first four terms4+0.5(−2)+0.52(6)+0.53(0)+=0(a terminated episode)0.54⋅0+0.55⋅0+⋯.
The zero-tail adds nothing, so we keep only the four non-zero terms:
Gt=4−1+0.25⋅6+0=4−1+1.5=4.5.Why: the exponent counts steps into the future: Rt+1 gets γ0=1, Rt+2 gets γ1, and so on. The reward 6 that arrives two steps late is worth only 1.5 now. The infinite sum notation is still correct — a terminating episode is just an infinite tail of zeros.
Recall Solution 2.3
What we do: start from the end (where G=0) and fold inward. This is exactly how TD / dynamic programming propagate values.
Gt+3=Rt+4+0.5Gt+4=0+0.5⋅0=0
Gt+2=Rt+3+0.5Gt+3=6+0.5⋅0=6
Gt+1=Rt+2+0.5Gt+2=−2+0.5⋅6=1
Gt=Rt+1+0.5Gt+1=4+0.5⋅1=4.5 ✓
Why: the recursion needs a terminalG=0 to launch — without it there is no place to start folding. The answer matches 2.2, as it must.
Recall Solution 2.4
What we do: apply the definition. With γ=1 every weight γk=1, so the return is the plain undiscounted sum of the four rewards:
Gt=3+1+4+2=10.
This is finite and well-defined because the episode stops after 4 terms — the infinite tail is all zeros, so γ=1 causes no divergence. Why it's safe: the danger of γ=1 is only an infinite number of non-zero terms; a guaranteed-terminating episode has finitely many, so no blow-up.
With γ=0.5:
Gt=3+0.5(1)+0.52(4)+0.53(2)=3+0.5+1+0.25=4.75.Comment: discounting (γ=0.5) shrinks the return from 10 to 4.75 by fading later rewards; γ=1 treats all four rewards as equally valuable. On a terminating episode both are legitimate — γ=1 is the "no time-preference" choice.
What we do: use ∣Gt∣≤1−γRmax with Rmax=5 (recall Rmax = largest reward magnitude).
∣Gt∣≤1−0.95=0.15=50.
As γ→1: 1−γ5→∞. Why: the denominator 1−γ→0, so the bound explodes — long horizons (large γ) can let returns grow without limit in continuing tasks (tasks that never terminate). This is the mathematical reason we usually keep γ<1.
Recall Solution 3.2
What we do: plug γ=0.9 into both formulas.
weight scale1−γ1=0.11=10,mean stepE[k]=0.10.9=9.
The mean stepE[k]=9 is the honest average look-ahead: the average of k under the normalized weights P(k)=(1−γ)γk (defined just above). People quote the weight scale1−γ1=10 because it's the total (un-normalized) weight ∑γk and is one larger; the two nearly coincide as γ→1. Why: the mean sits one below the scale because E[k]=1−γ1−1.
Recall Solution 3.3
What we do: constant-reward formula Gt=1−γR.
Future A (R=+1): γ=0.5⇒0.51=2; γ=0.99⇒0.011=100. Raising γincreases it.
Future B (R=−1): γ=0.5⇒0.5−1=−2; γ=0.99⇒0.01−1=−100. Raising γdecreases it (more negative).
Why:γ amplifies whatever the future is. For positive futures bigger γ helps; for penalty-laden futures it hurts. "Bigger γ = bigger return" is only true when the future is positive.
Return to figure s01 at the top of the page: each blue bar there is one discount weight γk. Exercise 3.2's weight scale1−γ1 is the total blue area, while the mean stepE[k] is the balance point (green dotted line) of that area — the average k once the bars are normalized into a probability distribution. Seeing area-vs-balance-point side by side is exactly why the two horizon numbers differ by one.
What we do: invert Gt=1−γR.
30=1−γ3⇒1−γ=303=0.1⇒γ=0.9.Why: the return-to-reward ratio RGt=1−γ1=10 directly reveals the horizon scale, and γ=1−101=0.9 (safely inside 0≤γ<1).
Recall Solution 4.2
What we do: substitute the reward into the return and recognise a geometric series with ratio γρ.
Gt=∑k=0∞γk(cρk)=c∑k=0∞(γρ)k=1−γρc.Why: two multiplicative factors per step (γ from discounting, ρ from reward growth) merge into a single ratio γρ; convergence needs ∣γρ∣<1.
Numbers: γρ=0.9×1.05=0.945, so
Gt=1−0.9451=0.0551≈18.18.
Sanity: ρ>1 makes rewards grow, so Gt≈18.18 exceeds the constant-reward value 1−0.91=10. Good.
Recall Solution 4.3
What we do: apply the definition, four non-zero terms then a zero-tail (episode terminates).
Gt=−1−0.9−0.92+0.93(100).
Compute: −1−0.9−0.81=−2.71; and 0.93=0.729, so 0.729×100=72.9.
Gt=−2.71+72.9=70.19>0.Why: even though the jackpot is discounted to 72.9 (down from 100), it dwarfs the small early penalties. Entering is worth it. The lesson: delay shrinks a reward but a big enough reward still dominates.
What we do: split off the k=0 term, then factor γ from the rest.
Gt=k=0γ0Rt+1+∑k=1∞γkRt+k+1.
Re-index the tail with j=k−1 (so k=j+1, and j runs 0→∞):
∑k=1∞γkRt+k+1=∑j=0∞γj+1Rt+j+2=γ∑j=0∞γjR(t+1)+j+1=γGt+1.
Therefore Gt=Rt+1+γGt+1. ■Why: the tail is exactly the return starting one step later, scaled by one factor of γ. This self-reference is the seed of every Bellman equation.
Recall Solution 5.2
Step 1 — valid distribution.∑k=0∞(1−γ)γk=(1−γ)⋅1−γ1=1. ✓ (uses the Geometric series sum, valid because γ<1; the (1−γ) is exactly the normalizer built in Exercise 3.2).
Step 2 — the mean.E[k]=∑k=0∞k(1−γ)γk=(1−γ)∑k=0∞kγk=(1−γ)⋅(1−γ)2γ=1−γγ.Why: we used the standard identity ∑kkγk=(1−γ)2γ; the normalizer (1−γ) cancels one power of (1−γ), leaving 1−γγ — one less than the scale 1−γ1.
Recall Solution 5.3
The danger of γ=1: in a continuing task (one with no terminal state) the sum has infinitely many terms; with γ=1 the bound 1−γRmax=010 is undefined and Gt can diverge to ∞. γ=1 is only safe when termination is guaranteed (an episodic task, as in Exercise 2.4). This is why the allowed range on this page is 0≤γ<1.
Choosing γ: require 1−γRmax≤200, i.e. 1−γ10≤200.
1−γ≥20010=0.05⇒γ≤0.95.
So any γ≤0.95 (e.g. γ=0.95) caps ∣Gt∣≤200. Why: the bound 1−γRmax is monotone in γ; solving the inequality gives the ceiling on γ that keeps returns tame. Turning the maximisation of Gt into a well-posed objective is exactly what the Reward hypothesis (all goals = maximising expected cumulative reward) needs.
Gt=∑γkRt+k+1 (return) ::: total discounted future reward, with 0≤γ<1.
Gt=Rt+1+γGt+1 ::: recursion, needs terminal G=0 to unfold.
∑γk=1−γ1 ::: weight scale (total of all discount weights) / horizon.
E[k]=1−γγ ::: true mean look-ahead (one less than the scale).
∣Gt∣≤1−γRmax ::: return is finite for γ<1.
γ=1 on a terminating episode ::: legal — the plain undiscounted sum of finitely many rewards.