How to Write the Equation of a Sine Graph
To write a sine equation from a graph, find the midline, amplitude, period, and a midline crossing. Use \(y=A\sin(B(x-h))+D\), where the amplitude is \(|A|\), the period is \(P=2\pi/|B|\), the horizontal shift is \(h\), and the midline is \(y=D\). The parameter \(B\) controls the period; it is not the period itself. These formulas use radians and assume \(A\ne0\), \(B\ne0\).
Related Topics
- How to Graph the Sine Function
- How to Graph the Cosine Function
- How to Graph Inverse of the Sine Function
- How to Graph Inverse of the Cosine Function
Step-by-step to write the equation of a sine graph
To find out how to write the equation of a sine graph, follow the step-by-step guide below:
- Amplitude: Read the maximum \(M\) and minimum \(m\). The amplitude is \((M-m)/2\), a nonnegative distance. In the equation it equals \(|A|\), not necessarily \(A\).
- Period: Measure the horizontal distance \(P\) between consecutive peaks, consecutive troughs, or matching crossings in the same direction. Choose \(B=2\pi/P\). For an axis measured in degrees, use \(B=360^\circ/P\) instead.
- Horizontal shift: For positive \(A\) and \(B\), choose \(h\) at a midline crossing where the graph rises. A downward crossing requires a negative \(A\) with this choice of positive \(B\). Equivalent equations may use a different crossing.
- Vertical shift: Set \(D=(M+m)/2\), the height of the midline.
For amplitude \(2\), period \(4\pi\), a right shift of \(3\), and an upward shift of \(1\), choose \(A=2\), \(B=2\pi/(4\pi)=1/2\), \(h=3\), and \(D=1\). A matching equation is \(y=2\sin\left(\frac{x-3}{2}\right)+1\). Check: its period is \(2\pi/(1/2)=4\pi\), its maximum is \(3\), and its minimum is \(-1\).
You can also use a graphing calculator or a software like Desmos to help you graph the function and find the equation.
The parent functions \(y=\sin x\) and \(y=\cos x\) have amplitude \(1\), range \([-1,1]\), period \(2\pi\), and domain all real numbers. Amplitude is a distance; the interval from \(-1\) to \(1\) describes their range.
Worked example: find an equation from key points
Suppose a sinusoidal graph has maximum \(5\), minimum \(-1\), period \(8\), and crosses the midline upward at \(x=2\). Then \(D=(5+(-1))/2=2\), \(A=(5-(-1))/2=3\), \(B=2\pi/8=\pi/4\), and \(h=2\). One equation is \(y=3\sin\left(\frac{\pi}{4}(x-2)\right)+2\).
Check five equally spaced points in one cycle: \((2,2)\), \((4,5)\), \((6,2)\), \((8,-1)\), and \((10,2)\). Their horizontal spacing is \(P/4=2\). These points confirm the upward crossing, maximum, minimum, and return to the starting height and direction.
Check the equation before you finish
Substitute a peak, a trough, and a midline crossing from the graph. Confirm the maximum and minimum, one full repeat length, and whether the graph rises or falls at your chosen crossing. In \(A\sin(Bx-C)+D\), the horizontal shift is \(C/B\); factor out \(B\) before reading the shift.
For the underlying transformation formulas, see OpenStax: Graphs of the Sine and Cosine Functions. Use the related sine and cosine lessons above to compare equivalent representations.
Write the Equation of a Sine Graph: what to notice and how to work it
What to notice first
Common student mistake
Key formulas and cues
A reliable path
- Choose the modelUse a right triangle, the unit circle, or a transformed graph.
- Track unitsConvert degrees and radians when needed.
- Use identitiesReplace complicated trig expressions with equivalent simpler ones.
Worked examples
Read a sine graph rule
- Amplitude is |3|.
- Period is 2pi/2 = pi.
- Midline is y = -1.
Place five key points
- Start at (0, 0).
- Use quarter-period steps: pi/2, pi, 3pi/2, 2pi.
- The y-values are 0, 1, 0, -1, 0.
Try one before moving on
Write the Equation of a Sine Graph: pop-up practice
Related to This Article
More math articles
- Middle School Math Worksheets: FREE & Printable
- 7th Grade IAR Math FREE Sample Practice Questions
- The Ultimate MCAS Algebra 1 Course (+FREE Worksheets)
- Top 10 8th Grade Common Core Math Practice Questions
- The Best Grade 7 ELA Practice Tests for Massachusetts Students
- Free Grade 4 English Worksheets for Virginia Students
- Grade 3 Math: Volume and Mass
- Disclosure requirements
- Florida FAST Grade 7 Math Worksheets: 95 Free Printable PDFs Aligned to Every Skill
- How to Add Mixed Numbers? (+FREE Worksheet!)



What people say about "How to Write the Equation of a Sine Graph"?
No one replied yet.