continues from lesson 4 — values defined earlier in the course stay live here
ELI5: to find where a function hits zero, stand at a guess, slide down its tangent line until you hit the x-axis, and use that landing spot as your next guess. Repeat, and you rocket toward the root. The update is x_next = x − f(x) / f′(x). This is what nsolve does under the hood.
Find √2, the positive root of x² − 2, starting at 1.5. One step lands at 1.41667; a second step at 1.41422 — already four correct digits.
✓ passabs(newton2−2)<0.0001four correct digits after just two steps
rootnewton:=nsolve("x2−2","x",1.5)=1.4142nsolve runs the iteration for you — Steps replays each landing
✓ passabs(rootnewton−2)<10−9the very same √2
Real-world hook: Newton's method (and its cousins) is how calculators, solvers, GPS receivers, and graphics engines actually compute square roots, trajectories, and intersections — fast, to full precision.
Try it yourself: do one Newton step on x² − 5 starting from x₀ = 2. (x_next = 2 − (2² − 5)/(2·2).)
newtonstep=2−2⋅222−5=2.2500✏️ Your turn: replace 0 with the result of one Newton step on x² − 5 from x₀ = 2. Work out 2 − f(2)/f′(2) yourself.
✓ passabs(newtonstep−2−2⋅222−5)<10−9green when your single Newton step is correct
That completes Calculus 1. Next, Calculus 2 runs the machine in reverse — from slopes back to areas, with integrals and infinite series.