Machine learning · 1986 · David E. Rumelhart, Geoffrey E. Hinton & Ronald J. Williams
Learning Representations by Back-Propagating Errors
Popularize efficient layer-by-layer credit assignment with the chain rule so hidden units can learn useful internal representations.
How to read the original
- Read the complete short letter in order; it does not use a numbered section structure.
- Reconstruct the forward activation definitions and the backward chain-rule calculation.
- Compare the learned hidden representations with the stated learning objective, without treating them as semantic labels.
Credit assignment is a derivative calculation
The paper explains how hidden units can learn by propagating derivatives of an output error backward through a multilayer network. The backward quantities are sensitivities, not corrected labels sent into earlier layers. This distinction lets you derive an update from the computation itself instead of memorizing an isolated formula. The following tiny network is an original worked example, not one of the paper’s experiments.
Original reconstruction: one hidden unit and one output
Use a scalar input x=2, hidden activation h=σ(wx+b), output z=vh+c, and loss E=(z−t)^2/2. Here σ(s)=1/(1+exp(−s)), and the target is t=1. Choose w=0, b=0, v=2, and c=0.5. The output is deliberately linear, while the hidden unit is sigmoid; this keeps the calculation short and makes the architecture assumption explicit.
The forward pass gives hidden input 0, so h=0.5. Output z is 2×0.5+0.5=1.5. Error z−t is 0.5 and loss is 0.125. Save x, h, z, and the parameters used for this pass, because the derivatives must describe the same computation.
Begin at the loss: ∂E/∂z=z−t=0.5. The output parameter derivatives are ∂E/∂v=(∂E/∂z)h=0.25 and ∂E/∂c=0.5. Sensitivity at the hidden activation is ∂E/∂h=(∂E/∂z)v=1. The sigmoid derivative at h=0.5 is h(1−h)=0.25, so sensitivity to the hidden preactivation is 0.25. Multiplying by the input gives ∂E/∂w=0.5, while ∂E/∂b=0.25.
With learning rate 0.1, one simultaneous gradient step gives w=−0.05, b=−0.025, v=1.975, and c=0.45. “Simultaneous” means compute every gradient using the original forward-pass parameters before replacing them. Updating v first and using its new value in the hidden derivative mixes two computations and no longer follows the derived gradient.
Check the mechanism independently
A centered finite difference approximates the w derivative by [E(w+ε)−E(w−ε)]/(2ε), holding every other parameter fixed. For ε=10^−5 at the original point, this should be close to 0.5. Try several ε values: too large introduces approximation error; too small can magnify floating-point cancellation. Agreement is useful evidence that the implementation differentiates this objective, not proof that the objective measures the desired application behavior.
If an activation feeds two downstream paths, its total derivative is the sum of contributions from both. Forgetting one path is a common implementation error. This is why reverse traversal of a computation graph accumulates sensitivities rather than simply overwriting them whenever a consumer is visited.
What learning does and does not establish
A sigmoid near zero or one has a small derivative, so a large output discrepancy can still yield a small early-layer update. More generally, optimization depends on initialization, scaling, architecture, and step size. A correct gradient does not guarantee a useful minimum, good generalization, or interpretable hidden units.
Keep the historical and mathematical claims separate. The paper helped establish a practical representation-learning method with important precursors; it did not invent the chain rule. A strong replication reports the exact loss, derivative checks, training behavior, and held-out results. Inspect hidden activations as evidence about the trained computation while avoiding the claim that a unit necessarily represents the concept suggested by its most appealing examples.
For a batch, specify whether the loss sums or averages the examples. Averaging divides the accumulated gradient by the batch size. Changing this convention without adjusting the learning rate changes the update magnitude even when each individual derivative remains correct.
Reconstruction exercise
Repeat the forward and backward calculation with the same original parameters but target t=0.5. Give loss and gradients for w, b, v, and c. Explain how you would finite-difference check w, and identify why computing the hidden gradient after updating v would be an implementation error.
Worked solution
The forward values remain h=0.5 and z=1.5 because the target does not change the forward network. Now z−t=1, so E=0.5. The output gradients are ∂E/∂v=1×0.5=0.5 and ∂E/∂c=1. Hidden activation sensitivity is 1×2=2, and preactivation sensitivity is 2×0.25=0.5. Thus ∂E/∂w=0.5×2=1 and ∂E/∂b=0.5. For a numerical check, evaluate the complete loss twice at w+ε and w−ε, keeping b, v, c, x, and t unchanged, then divide the difference by 2ε. The result should approach one in a suitable numerical range. Updating v before computing the hidden derivative uses a parameter different from the one that produced z and the cached activations. That mixes states and breaks the claim that all updates follow the gradient of the original loss at one parameter point.
Test the limits and transfer the idea
1. Derivation and numerical check · allow 40 minutes
Accumulate gradients at a shared hidden unit
Use h = sigmoid(wx + b), z₁ = 2h, z₂ = -h, and E = (z₁² + (z₂ - 1)²)/2. Set x = 2 and w = b = 0. Draw the computational graph and calculate E, ∂E/∂h, ∂E/∂w, and ∂E/∂b.
Explain the error made by a backward implementation that overwrites the hidden gradient with the contribution from its second child. Verify both parameter derivatives by centered finite differences. The two output coefficients are fixed in this exercise.
Get a starting hint
A value used by two children receives the sum of both downstream gradient contributions. Apply sigmoid′(0) = 1/4 only after adding them.
Compare your reasoning with the worked solution
The forward pass gives h = 1/2, z₁ = 1, z₂ = -1/2, and E = (1 + 9/4)/2 = 13/8. The first branch contributes z₁ × 2 = 2 to ∂E/∂h. The second contributes (z₂ - 1) × (-1) = 3/2. Their sum is 7/2. Consequently ∂E/∂w = (7/2)(1/4)(2) = 7/4 and ∂E/∂b = 7/8.
Overwriting with only the second contribution gives the incorrect hidden derivative 3/2 and parameter derivatives 3/4 and 3/8. The error is structural: the loss changes along every path from a shared value, so each path must contribute.
import math
def loss(w, b):
h = 1 / (1 + math.exp(-(2*w + b)))
return ((2*h)**2 + (-h - 1)**2) / 2
eps = 1e-6
dw = (loss(eps,0)-loss(-eps,0))/(2*eps)
db = (loss(0,eps)-loss(0,-eps))/(2*eps)
assert abs(dw - 1.75) < 1e-7
assert abs(db - 0.875) < 1e-7
This original graph exercises the paper's chain-rule mechanism. A passing finite-difference test supports this implementation at this point; it is not a proof for all inputs. Very large or very small step sizes can respectively introduce truncation error or cancellation, so numerical checking complements the symbolic derivation.
Check your reasoning
- Calculates loss 13/8 and sums both hidden-gradient contributions.
- Obtains derivatives 7/4 and 7/8 and diagnoses the overwrite error.
- Checks both derivatives numerically while recognizing the check is local.
2. Proof and trace · allow 35 minutes
Show why identical units stay identical
Consider a deliberately linear two-hidden-unit network: h₁ = w₁x, h₂ = w₂x, z = v₁h₁ + v₂h₂, and E = (z-t)²/2. Initialize w₁ = w₂ = 1/2 and v₁ = v₂ = 1. For x = 2, t = 0, take one simultaneous gradient-descent update with learning rate 1/10.
Calculate every derivative, updated parameter, and new loss. Then prove that equal parameter pairs remain equal under deterministic gradient descent on any common sequence of examples. Explain why different initialization alone cannot make this linear network represent a nonlinear function.
Get a starting hint
Derive ∂E/∂wᵢ = (z-t)vᵢx and ∂E/∂vᵢ = (z-t)wᵢx. Evaluate all derivatives using the old parameters before updating any parameter.
Compare your reasoning with the worked solution
Initially h₁ = h₂ = 1, z = 2, and E = 2. Each hidden weight has derivative 2 × 1 × 2 = 4. Each output weight has derivative 2 × (1/2) × 2 = 2. The simultaneous update gives w₁ = w₂ = 1/10 and v₁ = v₂ = 4/5. The new output is 2 × (4/5)(1/10)(2) = 8/25 = 0.32, and the loss is (8/25)²/2 = 32/625 = 0.0512.
For the general symmetry argument, assume the two hidden weights are equal and the two output weights are equal before an update. Both hidden units receive the same x. The displayed derivative formulas are then equal for each corresponding parameter pair. Subtracting the same learning rate times equal derivatives preserves equality. Induction proves the property for every update. Summing or averaging gradients over a common batch preserves the argument. Independent randomness, unequal regularization, or an asymmetric architecture would change the assumptions.
For all parameter values, the network simplifies to z = (v₁w₁ + v₂w₂)x. It is still one linear map, so unequal initialization cannot create nonlinear expressive capacity. The exercise isolates symmetry and derivative bookkeeping; the 1986 paper's interest in learned internal representations requires attention to nonlinear units and architecture as well as the backward algorithm.
Check your reasoning
- Uses old parameters for all derivatives and obtains the exact new loss 32/625.
- Proves equality preservation by an induction over updates.
- Separates breaking parameter symmetry from obtaining nonlinear expressivity.
Check your understanding
In the reading’s original example, what is ∂E/∂w?
- 0.25
- 0.125
- 1
- 0.5
Explanation
The chain is (z−t)×v×h(1−h)×x=0.5×2×0.25×2=0.5.
A hidden activation feeds two output paths. How are their derivative contributions combined?
- Choose whichever has larger magnitude.
- Add them before propagating through the hidden operation.
- Multiply them regardless of the graph.
- Ignore the path with smaller loss.
Explanation
The chain rule sums contributions from distinct downstream uses of the same intermediate value.
Original paper and sources
David E. Rumelhart, Geoffrey E. Hinton, and Ronald J. Williams. Learning Representations by Back-Propagating Errors. Nature, 9 October 1986.
Read the original paper →Read the primary paper: University of Toronto, author-hosted paper
- Learning Representations by Back-Propagating Errors: University of Toronto, author-hosted paper