⚠ Learning tool: waveforms are drawn by a browser script and may be imperfect
(floating-point rounding, finite-term truncation/Gibbs, rendering quirks). Treat as a visual aid, not an
authoritative reference; cross-check against a textbook or established software (Wolfram, MATLAB, SciPy).
Formula
\[ y(t) = A\sin(2\pi f t + \varphi)\ \text{and}\ A\cos(2\pi f t + \varphi) \]
The Building Blocks — Sine and Cosine
Formula
\[ y(t) = A\,\sin(2\pi f t + \varphi) \qquad\text{and}\qquad y(t) = A\,\cos(2\pi f t + \varphi) \]
A amplitudef frequency (Hz)t time (s)φ phase (rad)ω = 2πf angular frequency
Notice that cosine is just sine shifted by π/2 to the left. Both are the indivisible atoms of Fourier analysis —
every other waveform on this page is built by stacking many of these.
Frequently asked questions
Why do sine and cosine matter so much in engineering?
Almost every periodic signal in the physical world — AC mains, sound, light, radio — can be written as a sum of sines and cosines. They are the 'atoms' of vibration: a sine wave keeps its shape when you differentiate it, pass it through a linear circuit, or send it down a wire, which is exactly why engineers describe everything in terms of them.
What is the difference between amplitude, frequency and phase?
Amplitude (A) is how tall the wave is — loudness for sound, voltage for a signal. Frequency (f) is how many cycles happen per second, measured in hertz — pitch for sound, colour for light. Phase (φ) shifts the whole wave left or right in time. Drag each slider here and you can see exactly which knob does what.
Why is a cosine just a shifted sine?
cos(x) = sin(x + π/2). They are the same wave a quarter-cycle apart. That 90° relationship is why engineers pair them: any sinusoid of a given frequency can be made from a little sine plus a little cosine, which is the whole basis of the Fourier series.
Where would I meet this in real life?
Tuning a guitar string (a near-pure sine at its fundamental), the 50/60 Hz hum from mains power, the carrier wave of an FM radio station, and the swing of a pendulum all behave like the sinusoids on this page. Audio synthesisers literally start from a sine oscillator and build everything else on top.
What does adding phase actually change physically?
Phase decides where in its cycle a wave starts. Two identical speakers slightly out of phase can cancel each other (that is how noise-cancelling headphones work) or reinforce each other. In power systems, the phase difference between voltage and current determines how much usable power you actually get.