Lissajous Curves (2D)

Two perpendicular oscillations draw the figure; change the frequency ratio, phase and damping and watch crossings, speed and ink length.

Presets

Playback

Frequencies and phase

Amplitude, damping and view

Drawing time

Layers

Model check

The science

The parametric curve

A Lissajous figure is the path of a point whose x and y coordinates oscillate harmonically: x = A sin(a t + δ), y = B sin(b t). When a/b is a ratio of integers p/q in lowest terms the motion repeats after t = 2π/gcd(a,b) and the curve is closed; otherwise it never closes and slowly fills the box.

Counting crossings

For a generic phase the closed curve has 2pq − p − q self-crossings (p, q coprime). The page counts them by brute force on a polyline and compares with this formula. Special phases (for example δ = 0) collapse the curve onto a retraced arc, so for those the count is made at a generic phase.

Ellipse area

For a = b the figure is an ellipse of area π A B |sin δ|: a line at δ = 0, a circle for A = B and δ = 90°. The shoelace sum over 4000 sample points reproduces this value.

Harmonograph

A real harmonograph uses damped pendulums, so the amplitudes decay as e−γt, and a slight detuning ε of one frequency makes the figure precess. This is the damped, detuned form simulated here; it ignores pendulum non-linearity (finite-angle period lengthening) and any coupling between the two pendulums, which are idealised as independent damped harmonic oscillators.

Signals x(t) and y(t)
Pen speed |v|(t)
Self-crossings: counted vs 2pq - p - q
Ink length and damping envelope