Sine and cosine graphs
The sine graph is a wave that repeats for ever. Tides, sound and alternating current all follow this shape. Four numbers in the equation control how tall the wave is, how wide it is and where it sits.
What you need first
- That sin and cos are functions you can find on a calculator.
- Radians. Angles here are measured in radians, where π radians is the same as 180°. So 2π is a full turn of 360°, and π/2 is a right angle. π is about 3.14.
What you will be able to do
- Read the amplitude, period and midline from an equation.
- Explain why sin(2x) has waves half as wide as sin x.
- Solve a simple equation involving a sine wave.
The basic wave
The graph of y = sin x starts at 0, rises to 1, falls back through 0 to −1, and returns to 0. Then it does the same again. One complete up-and-down takes 2π along the x-axis.
Key words
- Midline
- The horizontal line through the middle of the wave. For sin x it is the x-axis.
- Amplitude
- How far the wave rises above its midline. For sin x it is 1.
- Period
- The length along the x-axis of one complete wave. For sin x it is 2π.
- Phase shift
- How far the wave has been slid to the right.
Four dials
Any sine wave can be written as y = a sin(b(x − c)) + d. Think of a, b, c and d as four dials.
Try it yourself
Before each step, set the sliders back to a = 1, b = 1, c = 0, d = 0. Predict first, then try.
Set a = 1, b = 1, c = 0, d = 0 so the orange wave sits on the blue one. Now predict what a = 3 does.
What you should see
The peaks reach 3 and the troughs reach −3. The wave is three times as tall but no wider. a sets the amplitude.
Put a back to 1. Predict what b = 2 does to the width of each wave.
What you should see
Each wave is half as wide. Two orange waves now fit in the space of one blue wave, so the period is π, not 2π. A bigger b means narrower waves.
Put b back to 1 and set d = 1.
What you should see
The whole wave moves up 1. It now swings between 0 and 2, about the midline y = 1.
Put d back to 0 and drag c to about 1.57, which is π/2.
What you should see
The wave slides right by π/2. Its peak, which was at π/2, is now at π.
| Letter | Controls | Value |
|---|---|---|
| a | Amplitude | The size of a, ignoring any minus sign |
| b | Period | 2π ÷ b |
| c | Phase shift | c to the right |
| d | Midline | The line y = d |
The highest value the wave reaches is d plus the amplitude. The lowest is d minus the amplitude.
Why the period is 2π ÷ b
The sine function completes one wave as the thing inside it goes from 0 to 2π. In sin(bx) the thing inside is bx. It reaches 2π when x = 2π ÷ b. So that is how far along the x-axis one wave takes.
With b = 2, the inside reaches 2π when x is only π. The wave finishes in half the distance.
Cosine is sine with a head start
The cosine graph has exactly the same shape as the sine graph, moved π/2 to the left:
cos x = sin(x + π/2)
To see it, set a = 1, b = 1, d = 0 and drag c to about −1.57. The orange wave now starts at its peak when x = 0, just as cosine does.
Worked example
For y = 3 sin(2x) + 1, state the amplitude, period and range. Then solve 3 sin(2x) + 1 = 2.5 for x between 0 and π.
- Amplitude. a = 3, so the amplitude is 3.
- Period. b = 2, so the period is 2π ÷ 2 = π.
- Range. The midline is y = 1. The wave goes 3 above and 3 below it, so y runs from −2 to 4.
- Start solving: get the sine on its own. Subtract 1, then divide by 3: sin(2x) = 0.5.
- Find the angles. x is between 0 and π, so 2x is between 0 and 2π. In that range, sine equals 0.5 at π/6 and again at 5π/6.
- Undo the doubling. 2x = π/6 or 5π/6, so x = π/12 or 5π/12.
There are two answers because a wave passes through any height twice in each period: once on the way up and once on the way down. The graph above starts on this function. Add the line y = 2.5 in the full calculator and you will see the two crossings between 0 and π.
The tangent graph is different
y = tan x is not a wave. It repeats every π, not every 2π. It has no amplitude, because it climbs without limit. And it has gaps: vertical lines called asymptotes at x = π/2, 3π/2 and so on, where the graph shoots off upwards on one side and comes back from below on the other. Type y = tan(x) into the calculator to see it.
Working in degrees
Everything above is in radians. If your question is in degrees, the period of sin(bx) is 360° ÷ b. The full calculator has a Degrees button above the graph.
Check yourself
Try each one on paper before you open the answer. Getting one wrong is useful: it shows you which part to reread.
State the amplitude and period of y = 2 cos(3x).
Show the answer
Amplitude 2, period 2π ÷ 3. Cosine follows the same rules as sine.
What is the range of y = sin x − 4?
Show the answer
From −5 to −3. The midline is y = −4 and the amplitude is 1.
Write the equation of a sine wave with amplitude 5 and period π.
Show the answer
y = 5 sin(2x). The period is 2π ÷ b = π, so b = 2.
Common mistakes
- Multiplying by b to find the period. You divide: 2π ÷ b.
- Giving a negative amplitude. Amplitude is a distance, so it is never negative. In y = −2 sin x the amplitude is 2 and the wave is upside down.
- Misreading the shift in sin(2x − π). Take out the 2 first: it is sin(2(x − π/2)), a shift of π/2, not π.
What to remember
- a sets the height, b sets the width, c slides the wave sideways, d moves it up or down.
- Period = 2π ÷ b.
- Cosine is the sine wave shifted π/2 to the left.