topic badge

7.07 Graphing sine and cosine

Lesson

In our last lesson we identified transformations and key features of sine and cosine functions. We now want to use those skills to sketch graphs. Through understanding the transformations the graph has undergone we can start with a base form of the function ($y=\sin x$y=sinx or $y=\cos x$y=cosx) and transform it in stages to achieve the final sketch. We could also use the following steps to assist in sketching:

  1. Ensure you formula is in the required format: $y=a\sin\left(b\left(x-c\right)\right)+d$y=asin(b(xc))+d Rearrange if necessary, for example you may need to factor the $b$b out to clearly read the value of $c$c for the phase shift.
  2. Write down $a$a, $b$b, $c$c and $d$d.
  3. Sketch in dotted lines for the principal axis: $y=d$y=d, the maximum value: $y=d+a$y=d+a and the minimum value: $y=d-a$y=da
  4.  Find the period: $Period=\frac{2\pi}{b}$Period=2πb
  5. For convenience divide the period by 4 and label the $x$x-axis in multiples of this. The key features/points in the next step will occur at these values.
  6. Sketch in points in the following fashion:
  • For sine graphs: the pattern starts in the middle (principal axis), then up, middle, down, middle. The pattern then repeats. If $a$a is negative the pattern will start in the middle and then go downwards.
  • For cosine graphs: the pattern starts at the top (maximum value), then middle, bottom, middle, top. The pattern then repeats. If $a$a is negative the pattern will start at the bottom and then go upwards.

     7. Shift the points by $c$c units horizontally and then join the points with a smooth curve.

Worked example

Sketch the graph of $y=3\sin2x+1$y=3sin2x+1 for the interval $0\le x\le2\pi$0x2π

Think: What transformations would take $y=\sin x$y=sinx to $y=3\sin2x+1$y=3sin2x+1

  • We would dilate the graph by a factor of 3 from the $x$x-axis. That is, increase the amplitude to 3.
  • We need to dilate the graph by a factor of $\frac{1}{2}$12 horizontally. Hence, the period becomes $\frac{2\pi}{2}=\pi$2π2=π.
  • We need to translate the graph by $1$1 unit vertically.

Do: List the parameters $a=3$a=3$b=2$b=2$c=0$c=0 and $d=1$d=1. Sketch dotted lines for the principal axis: $y=1$y=1, the maximum value: $y=4$y=4 and the minimum value: $y=-2$y=2.

Find the period: $period=\frac{2\pi}{b}$period=2πb$=\pi$=π. Put tick marks on the $x$x-axis at multiples of the $\frac{period}{4}$period4. So here we will mark our axis at each $\frac{\pi}{4}$π4 (You don't need to label each).

Mark the pattern on the graph. Since we are graphing a sine graph with a positive $a$a value, the pattern will start in the middle then next point will be at the top.

As $c=0$c=0 we do not have to horizontally shift the points. Lastly, join the points with a smooth curve.

Reflect: Does the graph match how it should look after transformations? Does its cycle repeat the correct number of times for the domain given?

Practice questions

Question 1

Consider the function $y=\sin x+4$y=sinx+4.

  1. Complete the table of values.

    $x$x $0$0 $\frac{\pi}{2}$π2 $\pi$π $\frac{3\pi}{2}$3π2 $2\pi$2π
    $y$y $\editable{}$ $\editable{}$ $\editable{}$ $\editable{}$ $\editable{}$
  2. Graph the function.

    Loading Graph...

  3. What transformation of the graph of $y=\sin x$y=sinx results in the graph of $y=\sin x+4$y=sinx+4?

    Horizontal translation $4$4 units to the right.

    A

    Horizontal translation $4$4 units to the left.

    B

    Vertical translation $4$4 units down.

    C

    Vertical translation $4$4 units up.

    D
  4. What is the maximum value of $y=\sin x+4$y=sinx+4?

  5. What is the minimum value of $y=\sin x+4$y=sinx+4?

Question 2

Consider the given graph of $y=\sin x$y=sinx.

Loading Graph...

  1. How can we transform the graph of $y=\sin x$y=sinx to create the graph of $y=\sin\left(x-\frac{\pi}{2}\right)+3$y=sin(xπ2)+3?

    Move the graph to the left by $\frac{\pi}{2}$π2 radians and up by $3$3 units.

    A

    Move the graph to the right by $\frac{\pi}{2}$π2 radians and up by $3$3 units.

    B

    Move the graph to the right by $\frac{\pi}{2}$π2 radians and down by $3$3 units.

    C

    Move the graph to the left by $\frac{\pi}{2}$π2 radians and down by $3$3 units.

    D
  2. Hence graph $y=\sin\left(x-\frac{\pi}{2}\right)+3$y=sin(xπ2)+3 on the same set of axes.

    Loading Graph...

  3. What is the period of the curve $y=\sin\left(x-\frac{\pi}{2}\right)+3$y=sin(xπ2)+3 in radians?

Question 3

Consider the function $f\left(x\right)=\cos x$f(x)=cosx and $g\left(x\right)=\cos\left(x-\frac{\pi}{2}\right)$g(x)=cos(xπ2).

  1. Complete the table of values for both functions.

    $x$x $0$0 $\frac{\pi}{2}$π2 $\pi$π $\frac{3\pi}{2}$3π2 $2\pi$2π
    $f\left(x\right)$f(x) $\editable{}$ $\editable{}$ $\editable{}$ $\editable{}$ $\editable{}$
    $g\left(x\right)$g(x) $\editable{}$ $\editable{}$ $\editable{}$ $\editable{}$ $\editable{}$
  2. Using the table of values, what transformation of the graph of $f\left(x\right)$f(x) results in the graph of $g\left(x\right)$g(x)?

    vertical translation $\frac{\pi}{2}$π2 units downwards

    A

    horizontal translation $\frac{\pi}{2}$π2 units to the left

    B

    horizontal translation $\frac{\pi}{2}$π2 units to the right

    C

    vertical translation $\frac{\pi}{2}$π2 units upwards

    D
  3. The graph of $f\left(x\right)$f(x) has been provided below.

    By moving the points, graph $g\left(x\right)$g(x).

    Loading Graph...

Question 4

Consider the function $f\left(x\right)=\cos5x$f(x)=cos5x.

  1. Determine the period of the function in radians.

  2. What is the maximum value of the function?

  3. What is the minimum value of the function?

  4. Graph the function for $0\le x\le\frac{4}{5}\pi$0x45π.

    Loading Graph...

Outcomes

1.2.1.4

examine transformations of the graphs of 𝑓(𝑥), including dilations and reflections, and the graphs of 𝑦=𝑎f(𝑥) and 𝑦=𝑓(𝑏x), translations, and the graphs of 𝑦=𝑓(𝑥+𝑐) and 𝑦=𝑓(𝑥)+𝑑; 𝑎,𝑏,𝑐,𝑑 ∈ R

2.3.2.4

investigate the effect of the parameters 𝐴,𝐵,𝐶 and 𝐷 on the graphs of 𝑦=𝐴sin(𝐵(𝑥+𝐶))+𝐷, 𝑦=𝐴cos(𝐵(𝑥+𝐶))+𝐷 with and without technology

2.3.2.5

sketch the graphs of 𝑦=𝐴sin(𝐵(𝑥+𝐶))+𝐷, 𝑦=𝐴cos(𝐵(𝑥+𝐶))+𝐷 with and without technology

What is Mathspace

About Mathspace