mrinmoydas

Derivatives for the Rest of Us

When math wasn’t mathing, Newton got crafting.

13 min readmath · calculus · history
Young Isaac Newton seated beneath an apple tree at twilight, watching a falling apple and the full Moon
Woolsthorpe, 1665. The apple falls, the Moon falls, same pull. (Click the sky to drop an apple.)

Math class. Someone asks the teacher why we even need calculus. The answer: learn the formula, solve the problem, move on.

I did. Years later, starting Andrej Karpathy’s neural network course, derivatives show up and the memory comes back blank.

Neil deGrasse Tyson, in a viral reel, calls Newton the greatest mind who ever lived. One reason: he invented this math. During a plague. At 22. Most of us spent lockdown making Netflix ask “Are you still watching?”

Neil deGrasse Tyson: Isaac Newton is #1YouTube Short · The 92nd Street Y

Turns out there was a why all along. Here it is, with an apple, the Moon and some floor tiles. Let’s go. 🍎

Part 1 · Newton’s question (1665)

1

An apple falls. Why not the Moon? 🍎#

Cambridge is shut for the plague. Newton is back on his mum's farm, where as a teen he read under trees while the sheep wandered off. No lectures, no Netflix, no friends to speak of. He stares at an apple tree until it gives in.

  🌙   ← why doesn't this fall?
 
  🍎
  ↓  pulled down, always straight down
  🌍

Did it bonk him on the head? No, that's a myth. Sixty years later, Newton, then 83, told his friend William Stukeley the real story: he wondered why it always falls straight down. And if that pull reaches the Moon, why isn't the Moon in his garden?

2

“Every body continues in its state of rest, or of uniform motion in a right line, unless it is compelled to change that state by forces impressed upon it.”#

Newton’s first law · Principia, 1687

In plain English: things are lazy. A moving thing keeps the same speed, in a straight line, until a force changes it. Galileo spotted it first. Teenagers have known it forever.

  🏒 ────────────→  keeps sliding: same speed, straight line
  nothing pushes it after the hit

A force is needed only to change motion: speed up, slow down, or turn.

3

Why the Moon never lands#

Gravity doesn't stop the Moon. It pulls it toward Earth, a little, every instant. Sideways motion plus that steady pull makes a curved path: the orbit. Switch gravity off and the Moon flies off in a straight line. Bye, Moon. 👋

moving sidewaysgravity pulls in
Squashed for drama. The real lunar orbit is nearly a circle.

Why doesn't it crash? Newton answered with a thought experiment. Picture a mountain so tall it pokes above the air, with a cannon on top. Fire a ball sideways. Slow, it lands nearby. Faster, it lands farther, because Earth curves away under it. Fast enough, and Earth curves away as fast as the ball falls. It never lands.

🌍slow: lands nearfaster: lands fartherfast enough: never lands

The Moon is falling all the time. It's just really bad at landing.

4

The problem: averages hide the Moon#

The Moon's path is an oval, so its distance and speed keep changing:

  far from Earth     slower    0.97 km/s
  close to Earth     faster    1.08 km/s
  monthly average    average   1.02 km/s   ❌

The average is right over a month and wrong almost every moment. Kepler (1609, using Tycho Brahe's star records) could describe the oval: faster when closer, slower far away. He couldn't explain it. Newton wanted to prove one force, gravity, causes all of it by changing the speed every instant. He needed a math of instants.

Part 2 · The trick: shrink the window (1665)

5

“Right now” breaks the math. Shrink the window#

Speed is distance ÷ time. But “right now” is an instant, and an instant has no time in it:

 speed     = distance ÷ time
 right now = 0 m ÷ 0 s = ?      ← no answer

The fix starts with your phone charging 📱. Fast at first, then a crawl, right when you need to leave.

 time      battery
 0 min      20%    fast
 10 min     38%
 30 min     62%    slowing down
 60 min     82%    trickle

How fast is it charging right now, at 30 min? Shrink the window:

 window          rate
 10 minutes      0.836 % per min   ← rough average
 1 minute        0.933 % per min
 1 second        0.945 % per min
 0.001 second    0.945 % per min   ← stops changing

Every row is a normal average, no dividing by zero. Shrink until the answer stops moving.

6

That number is the derivative#

Derivative = an average over a window so tiny that shrinking it more changes nothing.

 derivative = "nudge this a hair. How much does that move?"
 + → goes up      0 → flat      − → goes down

On a graph it's the slope: how steep the curve is right there. Newton called it a fluxion: he pictured every quantity as flowing, and the fluxion is how fast it flows. He wrote it as a dot on the letter: ẋ means “how fast x is changing”. Leibniz wrote the same thing as dx/dt.

Part 3 · Fermat’s tiles (1636)

7

Fermat: judge by day#

Thirty years before Newton, Pierre de Fermat was a judge in Toulouse who did math at night, for fun. He found this trick, then barely published it. We'll rebuild it with floor tiles.

Picture a square room floored with square tiles. Side 3 takes 3 × 3 = 9 tiles. That's all x² means here: the tile count of a square room with side x.

Now make the room one tile wider and longer, 3 → 4. The new tiles land in three places: a row along the top (3), a column down the side (3), and one corner tile. 9 + 3 + 3 + 1 = 16 = 4 × 4. ✅

side 3 = 9 tilesside 4 = 16 tiles→3 right3 top1 corner= 7 new
 side 1 → 2      add 3     (1 + 1 + corner)
 side 3 → 4      add 7     (3 + 3 + corner)
 side 10 → 11    add 21    (10 + 10 + corner)
 side x → x+1    add 2x+1  (x + x + corner)

Longer edges, longer new rows. Call the side x.

8

Shrink the strip: x² → 2x 🎉#

Now grow the room by less than a tile. Instead of a whole row, stick a thin LED strip 💡 along two edges. Call its width h. In the picture, h = 0.1.

corner 0.1 × 0.1 = 0.01 ← a specktop strip 10 × 0.1 = 1right strip 10 × 0.1 = 110.1 × 10.1 = 102.01added 2.01
 added = new − old
       = (x + h)² − x²
       = x² + 2xh + h² − x²
       = 2xh + h²                ← 2 strips + corner

Divide by h to get the rate, like % per minute on the phone:

 rate = (2xh + h²) ÷ h = 2x + h
 
 x = 10:
 h = 1      →  20 + 1      = 21
 h = 0.1    →  20 + 0.1    = 20.1
 h = 0.01   →  20 + 0.01   = 20.01
  • The strips part is always 2x. Thinner strip, less area, but we divide by a smaller h too. It cancels.
  • The corner part is always h. Shrink h, and it shrinks to nothing.

The corner isn't ignored. It fades by itself.

Only 2x is left: 2 strips, each as long as the side. Most of us memorised x² → 2x and never saw why. Now you have.

Here dy/dx just means change in y ÷ change in x, where y is the area and x is the side.

9

Wait, is that cheating?#

In step 8 we divided by h, so h isn't 0. Then we dropped h, as if it were 0. Hmm.

 1734, Bishop Berkeley 🤨
   divide by h   → so h is NOT 0
   then drop h   → so h IS 0?!
   "ghosts of departed quantities" 👻
 
 Newton? Died in 1727. Seven years too early to reply 🪦
 
 1821, Cauchy: never set h to 0. Use the limit:
   the number 20 + h closes in on as h shrinks
 
 1860s, Weierstrass makes it a game:
   "get within 0.01 of 20"   → h = 0.001      ✅
   "get within 0.000001"     → h = 0.0000001  ✅
   you always win → 20 is the limit. Exact. No ghosts.

Part 4 · Put it to work (1636–1687)

10

Fermat's best value: slope 0#

Fermat also used the trick to find the best possible answer. The problem: 20 m of fence, biggest rectangle of grass. The four sides add up to 20, so width + length = 10. Which shape wins?

same 20 m of fence, three shapes9 × 1 = 9 m²long and thin7 × 3 = 21 m²better5 × 5 = 25 m²most grass 🏆

Plot the grass for every width x. You get a hill ⛰️:

0123456789100510152025xgrass(3, 21)(7, 21)(5, 25) slope 0 🏆slope +8 ↗slope −8 ↘y = 10x − x²

At the top the curve is flat: slope 0. So skip the guessing:

 width x, so length = 10 − x
 grass = x × (10 − x) = 10x − x²
 slope = 10 − 2x               (x² → 2x, our tiles)
 slope = 0   →   x = 5  ✅

Every AI model trains this way, upside down: walk downhill on the error until the slope is 0. Same 1636 idea.

11

Leibniz's cheat sheet (1675)#

Meanwhile in Paris, Gottfried Leibniz, there on a diplomatic mission that went nowhere, found the same math on his own. He gave us dy/dx and rules for how much things move when you nudge x:

 expression   moves by      why
 5            0             constants never change
 x + 5        1             the 5 just sits there
 3x           3             each nudge counts 3×
 x²           2x            2 strips, we did this in step 8 →
 x³           3x²           3 faces. Curious? step 16 →
 a × b        b·a′ + a·b′   strips + corner, step 15 →
 chain        multiply      nudges multiply, step 17 →
12

Try it on the apple 🍎#

Galileo rolled balls down ramps and timed them. (Yes, really.) He found a pattern:

 time (s)      1      2      3      4
 fallen (m)    4.9    19.6   44.1   78.4
 ÷ 4.9         1      4      9      16     ← squares!
 
 fallen = 4.9 × time²

Same shape as the tiles, with time as x:

 tiles:   x²          → rate 2x
 apple:   4.9 × x²    → speed 4.9 × 2x = 9.8 × x
 
 at 1 s → 9.8 m/s
 at 2 s → 19.6 m/s       9.8 m/s faster every second 🚀

In its first second the apple falls 4.9 m. Keep that number. We're taking it to the Moon. 🌙

13

The answer: one rule for apple and Moon 🍎🌙#

London, 1684. The big guess: gravity weakens with distance squared. Twice as far, 4× weaker. If it were a group chat 💬:

Now the test. The Moon is 60× farther from Earth's centre than the apple. So the pull should be 60 × 60 = 3,600× weaker:

 apple, at the ground   falls 4.9 m in 1 second
 Moon, 60× farther      should fall 4.9 m ÷ 3,600
                        = 1.36 mm
 
 The real Moon, in 1 second:
   moves 1.023 km sideways, orbit radius 384,400 km
   drops (1.023 km)² ÷ (2 × 384,400 km) ≈ 1.36 mm
   Pythagoras: drop ≈ sideways² ÷ (2 × radius)
 
 1.36 mm vs 1.36 mm  →  same pull ✅

One rule for an orchard and the sky. 🤯 (Confession: modern numbers. Newton's 1666 figure for Earth's size was 10% off, so his first check only “answered pretty nearly”.)

And the oval? The derivative lets Newton say: right now, at this distance, gravity changes the Moon's speed by this much. Add up those instants (the integral) and out comes Kepler's oval. 🎯

14

Recap: who built it#

  1. Galileo falling: 4.9 × time²
  2. Kepler orbits are ovals, faster when closer
  3. Fermat x² → 2x; best value at slope 0
  4. Newton the derivative; first apple-Moon test
  5. Leibniz dy/dx and the rules
  6. Newton the Principia (Halley pays)
  7. Berkeley “your tiny h is cheating!”
  8. Lagrange names it “dérivée”: derived from
  9. Cauchy the limit makes it exact

The pieces were old. Newton and Leibniz made them one machine. Built to explain why the Moon doesn't land in an orchard, it now steers rockets and trains every neural net.

Not bad for a kid who couldn't watch sheep.

Bonus Prove the rules with tiles 🟦
15

Rectangle rooms#

square room x × xwiden both sides → 2 strips → 2xrectangle room a × bwiden only a → 1 strip → b

Same algebra as step 8. Widen only a, by h:

 added = (a + h) × b − a × b
       = hb                    ← 1 strip, b long, no corner
 rate  = hb ÷ h = b

Widen both sides and you get two strips (one b long, one a long) plus a fading corner. That's the product rule: b·a′ + a·b′. A square is a rectangle with a = b = x: x + x = 2x. Same rule. 🟦

16

Cube rooms 🧊#

A cube of side x holds x³ little cubes. Grow it by h. Where do the new bits go?

3 faces: x × x × h3 edges: x × h × h1 corner: h × h × hcube of side x, grown by h
 added = (x + h)³ − x³
       = 3x²h + 3xh² + h³          ← faces + edges + corner
 rate  = 3x² + 3xh + h²
 
 x = 10:
 h = 1      →  300 + 30    + 1        = 331
 h = 0.1    →  300 + 3     + 0.01     = 303.01
 h = 0.01   →  300 + 0.3   + 0.0001   = 300.3001
                         fades       fades faster

Shrink h: edges and corner fade. Only the 3 faces stay: 3x². 🎉

17

The chain rule 🔗#

New twist: the room stays 3 tiles wide, but the tiles grow. One change sets off another:

xs = 3xeach tile grows by a nudge3 tiles in a row: the side grows ×3area grows 2 strips, each s long: ×2scorner: tiny, fadestile xside sarea y×3×2s

Tile size 2. Make each tile 0.01 bigger:

            before   after     moved
 x (tile)   2        2.01      0.01
 s (side)   6        6.03      0.03     ×3
 y (area)   36       36.3609   0.3609   ×12
 
 0.01 in → about 0.36 out = ×36 = 3 × 12

Why ×3? Three tiles in a row each grew. Why ×12? The side's two strips are 2s = 12 long. (The extra 0.0009 is the corner, fading as usual.)

Nudges multiply down the chain: 2s × 3 = 6s = 6(3x) = 18x. Check: y = (3x)² = 9x², and the tiles say 9 × 2x = 18x. At x = 2, that's 36. ✅

That's the chain rule. It's also how every neural net learns. (Backpropagation is the chain rule in a trench coat.)

Up next · Part IIAdd it all back together

The derivative chops motion into instants. The integral glues instants back into a path: “gravity pulls this hard, right now” becomes a whole orbit. Keep your floor tiles handy.