Given a ride I'm about to take; distance, terrain, wind, the speed I want to hold; which bike should I take? A lightweight racing bike. An e-bike with a 250 Wh battery. The same e-bike with a 500 Wh extender. The answer isn't obvious, and it depends on all four inputs.

I built a small tool that answers it. Input the ride, output human-supplied energy in kilojoules for each bike. Lowest wins. The math is worth understanding because it produces results that don't match intuition.

// three forces

Every pedal stroke works against three things: rolling resistance, aerodynamic drag, and gravity.

Rolling resistance is linear in weight and speed. The racing bike is 20 lbs on 100 PSI road tires (\(C_{rr} \approx 0.005\)). The e-bike is 30 lbs on 50 PSI gravel tires (\(C_{rr} \approx 0.007\)). Heavier and 40% more friction, at every speed, for the whole ride.

Aerodynamic drag is where the interesting behavior hides. Power to overcome drag scales as \(v_{\text{air}}^{2} \cdot v_{\text{ground}}\); the square of the speed of the air you're pushing against, times the speed you're actually moving forward at. In calm conditions those are equal and drag power goes as \(v^{3}\). In wind they come apart.

Gravity costs \(m g h\) on every foot climbed. On a round trip the net elevation is zero. You don't recover what you spent.

// wind always costs, in either direction

Here's a result that surprises people. On a round trip at constant ground speed, half into a headwind and half with a tailwind, the total drag energy is:

\[E_{\text{total}} \propto v^{2} + w^{2}\]

Not \(v^{2}\) (as if the wind cancels out). Not \(v^{2} - w^{2}\) (as if the tailwind refund matches the headwind tax). It is \(v^{2}\) plus \(w^{2}\). You pay extra whenever the air is moving, regardless of direction.

The reason is squaring. The headwind leg costs \((v + w)^{2}\). The tailwind leg refunds only \((v - w)^{2}\). Add them, divide by two, and the cross terms cancel; what's left is \(v^{2} + w^{2}\). A 10 mph wind at 15 mph ground speed lifts the round-trip average drag power by about 44%.

// elevation is not round-trip zero

Climbing 1000 feet with an 80 kg rider-plus-bike costs about 240 kJ. If descent were perfectly efficient you would get it all back. In practice you recover about 85%; the rest goes to braking, to drag at the higher descent speeds, and to the fact that you stop pedaling. That leaves 15% as a real cost, even on a loop. Heavier bikes eat more of it.

// the motor's job

The e-bike motor offsets some of the total power need, subject to three constraints. Speed at or below the 20 mph cutoff. Battery not empty. Motor efficiency around 82%; 100 watts of battery becomes 82 watts of mechanical help.

The question is how much motor to use. Too high and the battery dies midway; you finish the ride pushing a 30 lb bike with gravel tires and no help. Too low and you finish with battery to spare, your legs having done more work than they needed to.

// spread the battery over the ride

The optimal motor setting is the one that empties the battery exactly when you finish:

\[P_{\text{motor}} = \frac{E_{\text{battery}}}{t_{\text{ride}}}\]

A 250 Wh battery on a 5-hour ride is 50 watts; not full blast, but steady the whole way. A 500 Wh battery on a 2-hour ride clamps at the 250 W motor cap, which means full strength until the battery runs out, no earlier and no later than the finish.

This removes a variable. The rider does not guess at a motor strategy; the calculator picks the optimum, then reports it back so you know what wattage to dial in on the bike.

// when each bike wins

The racing bike wins whenever its weight-and-tires advantage outruns what the motor can offer. Short rides with steep climbs (the optimal motor setting exceeds the 250 W cap, battery gets stranded). Rides above the motor cutoff (the motor is dead weight). Flat rides in calm air (rolling resistance differences dominate and the racing bike is simply lighter).

The extender battery wins on long rides below the cutoff, where 250 Wh runs out partway and 500 Wh keeps the motor engaged the whole time.

Between those two extremes, the 250 Wh e-bike is the answer. That is where the tool earns its keep; my intuition is not calibrated to switch reliably between the three.

// the tool

Inputs are target speed, rider weight, motor cutoff, max motor wattage, total elevation gain, and one or more legs with their own distance, wind speed, and wind direction. Outputs are human energy in kJ per bike, motor duration, battery remaining, and the optimal motor setting.

Try it at /BikeChooser.