Sine and cosine in this visualization
For an angle measured in radians from the positive x-axis, the point at that angle on the unit circle is : cosine is its horizontal position, sine its height. A radian is a length along the unit circle, so θ is also the arc travelled from (1, 0), and both functions repeat after one turn, a period of . This page follows one turn, .
The three parts share one unit of length. The height of P, carried across, traces the sine wave with θ to the right; its horizontal position, carried down, traces the cosine wave hanging below with θ downward. The yellow arc from (1, 0) to P has length θ, and the same yellow length lies along both θ axes: one turn unrolls to 2π ≈ 6.283 radii. Flat turns the hanging graph a quarter turn about the centre. That rotation takes each point of the hanging graph to height cos θ at position θ, and takes P to Q, the point a quarter turn ahead. Q's height is P's horizontal position, so the cosine wave is level with the sine wave further on: it is the sine wave shifted to the left.
Turning at one radian per second, P has velocity , of length 1 and at right angles to the radius. Its upward part, cos θ, is the rate at which the height changes, which is the slope of the sine wave: 1 at θ=0, −1 at θ=π, and 0 at peaks and troughs. Spin leaves a red tick every π/6 s. The ticks on the circle are evenly spaced; their shadows bunch near the top and bottom, where the height changes slowly.
Things to notice
- The red ticks record equal times of the spin. They are not sample points, and nothing ties them to the curve's shape beyond the uniform turning.
- Laying the cosine flat is a rigid turn of the whole graph: the curve does not change, only where it lies. The sine is drawn a quarter period past 2π only so that the level partner of every θ in the turn stays on the picture.
- At the special angles (multiples of π/6 and π/4) the values are exact, such as ; elsewhere they are decimals marked ≈.
Controls
- Drag P round the circle, or a point on either wave; near a special angle it catches. The angle can be typed in radians (π/3, or a decimal such as 1.0472, which stays a decimal) or in degrees (60°), from 0 to 2π.
- Presentation mode opens a full-screen view for projectors: Space spins, ← → step through the special angles, H hides every value. Share copies a link to the current view, the last spin's ticks included.
Related
- C01Unit circle
- B08RadianPlanned
- C03Sinusoidal function
- C09Parametric equationPlanned
- D05Derivative
- G04Simple harmonic motion
Further reading: Wikipedia: Sine and cosine; OpenStax, Algebra and Trigonometry 2e, 8.1 Graphs of the Sine and Cosine Functions.