This model reimplements a single-cylinder spark-ignition engine's real slider-crank kinematics — piston position is computed from the finite connecting-rod-length equation, not a plain sine wave — and pairs it with a live cylinder-pressure-vs-crank-angle curve, drawn on the scrolling plot to the right of the cylinder. Combustion is modelled with a Wiebe-style mass-fraction-burned curve that starts at the spark event and releases heat over roughly 60° of crank rotation, exactly the way real engine simulation software approximates flame propagation.
Formula 1 and other race engines run knock sensors that listen for detonation on every single combustion event and retard timing on that cylinder within one engine cycle — a feedback loop far faster than any human could react.
A 3D single-cylinder engine driven by exact slider-crank kinematics, paired with a live cylinder pressure-vs-crank-angle curve that shows exactly why ignition fires before top dead centre — and what happens when it fires too early.
A Wiebe-style combustion model shows how the flame's finite burn duration forces the spark to fire before TDC, and how compression ratio and spark advance together control whether the engine makes power cleanly or knocks.
Adjust engine speed, spark advance and compression ratio and watch the pressure curve's peak shift on the live graph. Push spark advance and compression ratio too high together to trigger a knock event.
Peak cylinder pressure in a real engine typically lands 12–20° after top dead centre — firing the spark exactly at TDC actually loses torque, because the flame hasn't finished releasing its energy yet.