Sliders adjust the X and Y position of the hip joint, as well as the radius and cadence of the pedal stroke. Arrow keys adjust the radius and the cadence and use WASD to control the X and Y position of the hip. Space changes the backdrop from black to white.
The pedals move in a circular orbit. The hip is stationary. To place the knee for each leg, the code determines the third point in an isosceles triangle whose two equal sides represent the bicyclist's thigh and calf.