Category: Trigonometry Level: 201
y = A sin(B(x - h)): amplitude |A|, period 2π/B, shift h
Build y = 2 sin(3x − π/2) from y = sin x one change at a time: stretch it taller, squeeze it narrower, then slide it right.
The basic wave goes from −1 to 1 and repeats every 2π. Every other sine wave is this one, stretched, squeezed, or slid.
y = sin x: amplitude 1, period 2π
Multiply the output by 2. Every height doubles, so the peaks reach 2 and the troughs reach −2. The period does not change.
y = 2 sin x: amplitude 2
Replace x with 3x. The wave runs three times as fast, so one full cycle fits in 2π/3 ≈ 2.094 instead of 2π.
y = 2 sin 3x: period 2π/3 ≈ 2.094
Factor the inside: 3x − π/2 = 3(x − π/6). The minus sign means the wave slides right by π/6, not left. Every peak moves over by the same amount.
2 sin(3x - π/2) = 2 sin(3(x - π/6))
The final wave has amplitude 2, period 2π/3, and starts its first cycle at x = π/6. Three knobs, one wave.
y = 2 sin(3x - π/2): amplitude 2, period 2π/3, shift π/6 right
cd svg-generator python3 -m svgmath render sinusoid-transformations --out /tmp/sinusoid-transformations
Source: svgmath/diagrams/trig_graphs.py