Skip to main content

Chapter 13 Trigonometric functions

Section 13.1 Periodic behaviour

Example 13.1.1. Oscillation of a mass on a spring.

Consider a spring with a mass attached to one end and the other end attached to a wall. For simplicity, we will assume that the mass rests on a frictionless surface. Let \(s(t) \) represent the position of the spring relative to the wall at time \(t \text{,}\) and let \(\rmsubscript{s}{eq} \) represent the “equilibrium” position.
A mass attached to a spring, at equilibrium position.
(a) At the equilibrium position, where the spring is neither compressed nor stretched.
A mass attached to a spring, at a negative position with the spring compressed.
(b) At a negative position, where the spring is compressed.
A mass attached to a spring, at a positive position with the spring stretched.
(c) At a positive position, where the spring is stretched.
Figure 13.1.2. A mass attached to a spring.
Imagine what will happen if the mass is held at a position that compresses the spring, and then is released. The initial velocity of the mass is \(0 \text{,}\) as it is starting from rest, but the force of the spring causes it to accelerate. The mass reaches its highest velocity as it passes the equilibrium position, since past that point the spring is now stretched and begins to pull back on the mass. The force of the stretched spring now causes the spring to slow down, stop, and begin to move back towards the wall. We now consider the mass to have negative velocity as it is moving in the opposite direction, and its distance from the wall is now decreasing. The mass reaches its largest negative velocity as it again passes the equilibrium position before slowing down, stopping, and repeating the motion all over again.
A velocity graph for a mass attached to a spring.
Figure 13.1.3. A velocity graph for a mass attached to a spring.
Now consider the position function \(s(t) \text{.}\) For simplicity, let’s label the equilibrium position as \(s = 0 \text{,}\) so that positions closer to the wall than equilibrium and negative, and positions farther from the wall are positive. If the mass begins at position \(s(0) = -A \) (with \(A \) positive), it will reach the equilibrium position \(s(t) = 0 \) at the same time that the velocity is at its peak, and will by symmetry will the position \(s(t) = A \) will be the furthest from the wall it reaches, at the same time that velocity is a gain \(0 \text{.}\) Then its position will return back to \(s(t) = -A \) following the same pattern in reverse.
Position and velocity graphs for a mass attached to a spring.
Figure 13.1.4. Position and velocity graphs for a mass attached to a spring.
The repetitive motion in Example 13.1.1 is called periodic. The period is the time duration required to complete one cycle of the repetition. The smoothly oscillating functions in Figure 13.1.4 are called sinusoidal functions.

Section 13.2 Radian measure

A circle with radius \(R = 1 \) has circumference \(C = 2 \pi \text{.}\) This means that if we cut the circle and “unrolled” it into a straight line segment, its length would be \(2 \pi \text{.}\)
An unrolled unit circle.
Figure 13.2.1. An unrolled circle of radius \(1 \text{.}\)
Given two points on the circle, we may ask the question: “What is the distance along the circle between these two points?”
A straightened arc of a unit circle.
Figure 13.2.2. A straightened arc of a unit circle.
Such a distance along a circle is called an arc length.
If we draw line segments from the centre of the circle to each of two points on the circle, an angle is created.

Definition 13.2.3. Radian measure of an angle.

Given an angle formed by two line segments that meet at a vertex, extend the segments in the direction away from the vertex until each has length at least \(1 \) unit, if necessary. Then the circle of radius \(R = 1 \) centred at the vertex will cut the two segments. Define the radian measure of this angle to be the arc length between the points where the circle cuts the segments.
Radian measure of an angle equals arc length along a unit circle.
Figure 13.2.4. Radian measure of an angle equals arc length along a unit circle.
For example, a right angle creates an arc that is one quarter of a circle, and so has radian measure
\begin{equation*} \frac{2 \pi}{4} = \frac{\pi}{2} \text{.} \end{equation*}
A \(45 \degree \) angle will create an arc half the length of that for a right angle, and so has radian measure \(\pi / 4 \text{.}\)
Radian measure of a right angle.
(a) Radian measure of a right angle.
Radian measure of a 45-degree angle.
(b) Radian measure of a \(45 \degree \) angle.
Figure 13.2.5. Two example radian measures.
Here are some common radian measures, with the corresponding angle measure in degrees.
Degrees Radians
\(0 \degree \) \(0 \)
\(30 \degree \) \(\pi / 6 \)
\(45 \degree \) \(\pi / 4 \)
\(60 \degree \) \(\pi / 3 \)
\(90 \degree \) \(\pi / 2 \)
Degrees Radians
\(120 \degree \) \(2 \pi / 3 \)
\(135 \degree \) \(3 \pi / 4 \)
\(150 \degree \) \(5 \pi / 6 \)
\(180 \degree \) \(\pi \)
\(270 \degree \) \(3 \pi / 2 \)
\(360 \degree \) \(2 \pi \)
Figure 13.2.6. Some common radian measures.
In general, we can convert between degrees and radians by the relation
\begin{equation*} 1 \degree = \frac{2 \pi}{360} \text{ radians} \text{.} \end{equation*}
Finally, by allowing both positive- and negative-measure angles, we can take direction into account. To do this, we label one of the two points on the circle as “first” and the other as “second”. Then an angle that opens counter-clockwise from first point to second point is considered positive, while an angle that opens clockwise from first point to second point is considered negative.
When working with the unit circle centred at the origin in the Cartesian plane, we generally take the point \((1,0) \) as the “first” point to act as a reference point.

Section 13.3 The six trigonometric functions

The most basic form of periodic behaviour is to repeatedly traverse a circle, so that every period is one traversal of the circle.
Traversing the unit circle.
Figure 13.3.1. Traversing the unit circle.
Consider how the \(x \)-coordinate varies as we traverse the unit circle, starting at the point \((1,0) \) on the \(x \)-axis and moving counter-clockwise. In particular, let’s match \(x \)-coordinates of positions along the circle to angles, with variable \(t \) representing the angle between the radius to the reference point \((1,0) \) and the radius to the position point, as in Figure 13.3.1. Starting at the reference point \((1,0) \) on the positive \(x \)-axis, we observe the following.
  • The \(x \)-coordinate decreases from \(x = 1 \) at \(t = 0 \) to \(x = 0 \) at the point \((0,1) \) on the positive \(y \)-axis, where \(t = \pi/2 \text{.}\)
  • From there, the \(x \)-coordinate continues to decrease to \(x = -1 \) when it reaches the point \((-1,0) \) on the negative \(x \)-axis, where \(t = \pi \text{.}\)
  • From there, the \(x \)-coordinate increases through \(x = 0 \) at the point \((0,-1) \) on the negative \(y \)-axis (where \(t = 3\pi / 2 \)) back to \(x = 1 \) when it returns to the reference point \((1,0) \text{.}\) Even though this is at \(t = 0 \text{,}\) we consider it to be \(t = 2 \pi \text{,}\) since we have now made one full traversal of the circumference of the circle.
Traversing the circle a second (or third, or fourth) time just repeats this behaviour. And if we traverse the circle in reverse (so that now \(t \) is considered negative), we observe the above behaviour in reverse. Here is the graph of angle-versus-\(x \)-coordinate formed by this behaviour.
Graph of the cosine function.
Figure 13.3.2. Graph of the cosine function, which tracks the \(x \)-coordinate of positions on the unit circle.

Definition 13.3.3. The cosine function.

Given input value \(t \text{,}\) the output value \(\cos(t) \) is taken to be the \(x \)-coordinate of the point \((x,y) \) on the unit circle that forms an angle of \(t \) with the positive \(x \)-axis.
Also consider how the \(y \)-coordinate varies as we traverse the unit circle, and how that variation tracks the variation in the angle \(t \text{.}\) With an analysis similar to the one above for the variation in the \(x \)-coordinate of the position, we arrive at the following graph of angle-versus-\(y \)-coordinate.
Graph of the sine function.
Figure 13.3.4. Graph of the cosine function, which tracks the \(x \)-coordinate of positions on the unit circle.

Definition 13.3.5. The sine function.

Given input value \(t \text{,}\) the output value \(\sin(t) \) is taken to be the \(y \)-coordinate of the point \((x,y) \) on the unit circle that forms an angle of \(t \) with the positive \(x \)-axis.
Due to the abundance of symmetry in a circle, the graphs of the sine and cosine also display many instances of symmetry, which we can express as transformations of functions.
In Section 13.4 we will review the connection between trigonometry and the geometry of right triangles; specifically, ratios of sides in a right triangle. With that goal in mind, we make the following definitions of four more trigonometric functions as ratios.

Definition 13.3.7. The tangent function and reciprocal trigonometric functions.

Given input value \(t \text{,}\) let \((x,y) \) represent the point on the unit circle that forms an angle of \(t \) with the positive \(x \)-axis. Then we define the tangent, cotangent, secant, and cosecant functions by
\begin{align*} \tan t \amp = \frac{y}{x} \amp \sec t \amp = \frac{1}{x} \\ \cot t \amp = \frac{x}{y} \amp \csc t \amp = \frac{1}{y} \text{.} \end{align*}

Justification.

With angle \(t \) and point \((x,y) \) on the unit circle as in Definition 13.3.7, we have
\begin{align*} \cos t \amp = x \amp \tan t \amp = \frac{y}{x} \amp \sec t \amp = \frac{1}{x}\\ \sin t \amp = y \amp \cot t \amp = \frac{x}{y} \amp \csc t \amp = \frac{1}{y}\text{,} \end{align*}
and the relationships in the pattern statement follow immediately.
Finally, we will need the addition identities for sine and cosine.

Section 13.4 Trigonometry in triangles

Given a right triangle, we can draw a unit circle centred at the vertex opposite the hypotenuse. This circle will either cut the hypotenuse or we may extend the hypotenuse until it reaches the circle. Treating one of the triangle’s legs as representing the positive \(x \)-axis, we may use the angle formed by the hypotenuse and that leg as the input to the trigonometric functions.
Cutting a right triangle with a unit circle.
(a) Cutting a right triangle with a unit circle.
Extending a right triangle within a unit circle.
(b) Extending a right triangle within a unit circle.
Figure 13.4.1. Creating a similar right triangle in a unit circle.
In both cases demonstrated in Figure 13.4.1, the two triangles are similar triangles, which means that a ratio of side lengths in one of the triangles will equal the ratio of corresponding side lengths in the other triangle. Therefore,
\begin{align*} \cos \theta \amp = \frac{x}{1} = \frac{a}{c} \amp \sin \theta \amp = \frac{y}{1} = \frac{b}{c} \amp \tan \theta \amp = \frac{y}{x} = \frac{b}{a}\text{,} \end{align*}
leading to the familiar acronyms SOH CAH TOA:
\begin{align*} \cos \theta \amp = \frac{\mathrm{adj}}{\mathrm{hyp}} \amp \sin \theta \amp = \frac{\mathrm{opp}}{\mathrm{hyp}} \amp \tan \theta \amp = \frac{\mathrm{opp}}{\mathrm{adj}}\text{.} \end{align*}
SOH CAH TOA.
Figure 13.4.2. SOH CAH TOA.

Section 13.5 Derivatives of the sine and cosine functions

Velocity is the rate of variation in position. (Or, really, it’s the rate of accumulation of distance from an initial position, and to accumulate distance you must vary your position.) So
\begin{equation*} v(t) = \ddt{s} \text{.} \end{equation*}
Suppose we take the motion of the mass-on-spring in Example 13.1.1 to have an amplitude of \(1 \text{,}\) so that when the object is stopped at maximum compression of the spring and at maximum stretch of the spring, it is \(1 \) unit away from the central equilibrium position. And suppose we assume that the time units are normalized so that one full period of the motion, from compressed spring to stretched back to compressed, represents the time domain \(0 \le t \le 2 \pi \text{.}\) Then the velocity can be modelled by the sine function and the position can be modelled by the negative of the cosine function:
\begin{align*} v(t) \amp = \sin t \text{,} \amp s(t) = - \cos t \text{.} \end{align*}
Figure 13.1.4 certainly seems to support these assignments. The reason that we have the negative of the cosine function as the position function is because we took the central equilibrium position to be \(s = 0 \text{,}\) with \(s \lt 0 \) representing a position closer to the wall and \(s \gt 0 \) representing a position further from the wall compared to the centre position. So when the object is released from a stop at a compressed position, we are taking \(s(0) = -1 \text{.}\) And from the there the object moves forward, so that the position values increase and the velocity values becomes positive.
So from \(v(t) = ds/dt \text{,}\) we might guess
\begin{equation*} \ddt{\bbrac{- \cos(t)}} = \sin(t) \qquad \implies \qquad \ddt{\bbrac{\cos(t)}} = - \sin(t)\text{.} \end{equation*}
If we choose a different time in the periodic motion of the mass-on-spring to act as the “initial time”, so that the spring was already in motion when recording of the experiment began, but the mass was passing through the equilibrium position at \(t = 0 \text{,}\) then we obtain a shifted version of Figure 13.1.4, pictured in Figure 13.5.1.
Shifted position and velocity graphs for a mass attached to a spring.
Figure 13.5.1. Shifted position and velocity graphs for a mass attached to a spring.
In this diagram, it appears that \(s(t) = \sin(t) \) and \(v(t) = \cos(t) \text{,}\) so that
\begin{equation*} \ddt{\bbrac{\sin(t)}} = \cos(t) \text{.} \end{equation*}
Let’s attempt to verify the derivative formula for the sine function above. First we need to compute
\begin{equation*} \sin(t + \change{t}) \text{,} \end{equation*}
which we can do using Pattern 13.3.9:
\begin{equation*} \sin(t + \change{t}) = \sin(t) \cos(\change{t}) + \sin(\change{t}) \cos(t) \text{.} \end{equation*}
So for quantity function \(q(t) = \sin(t) \text{,}\) we have
\begin{align*} \change{q} \amp = \sin(t + \change{t}) - \sin(t) \\ \amp = \sin(t) \cos(\change{t}) + \sin(\change{t}) \cos(t) - \sin(t) \\ \amp = \bbrac{\sin(t) \cos(\change{t}) - \sin(t)} + \sin(\change{t}) \cos(t) \\ \amp = \sin(t) \bbrac{\cos(\change{t}) - 1} + \sin(\change{t}) \cos(t) \end{align*}
\begin{align*} \implies \quad \slope{q}{t} \amp = \frac{ \sin(t) \bbrac{\cos(\change{t}) - 1} + \sin(\change{t}) \cos(t) }{ \change{t} }\\ \amp = \frac{ \sin(t) \bbrac{\cos(\change{t}) - 1} }{ \change{t} } + \frac{ \sin(\change{t}) \cos(t) }{ \change{t} }\\ \amp = \sin(t) \cdot \frac{ \bbrac{\cos(\change{t}) - 1} }{ \change{t} } + \frac{ \sin(\change{t}) }{ \change{t} } \cdot \cos(t) \text{.} \end{align*}
We would now like to compute
\begin{equation*} \lim_{ \change{t} \to 0 } \slope{q}{t} = \lim_{ \change{t} \to 0 } \left( \sin(t) \cdot \frac{ \bbrac{\cos(\change{t}) - 1} }{ \change{t} } + \frac{ \sin(\change{t}) }{ \change{t} } \cdot \cos(t) \right)\text{.} \end{equation*}
In this limit, keep in mind that we regard \(t \) as constant. The best way to think of this is that we are attempting to compute a single derivative value at some specific input value \(t \text{.}\) And if \(t \) is regarded as constant, then so should \(\sin(t) \) and \(\cos(t) \) be. With this in mind, the Sum Law and the Constant Multiple Law from Pattern 3.3.1 imply that we should focus on determining
\begin{align*} \frac{ \bbrac{\cos(\change{t}) - 1} }{ \change{t} } \amp \to \text{?} \amp \frac{ \sin(\change{t}) }{ \change{t} } \amp \to \text{?} \end{align*}
as \(\change{t} \to 0 \text{.}\) In Figure 13.5.2, we graphically compare \(\cos(\change{t}) \) to the constant function \(1 \) (the two terms in the numerator of the first limit above) and compare \(\sin(\change{t}) \) to its input \(\change{t} \) (the numerator and denominator of the second limit above).
Comparing the graph of the cosine function to the horizontal line at 1.
(a) Comparing cosine to \(1 \text{.}\)
Comparing the graph of the sine function to the line with slope 1.
(b) Comparing sine to the input variable.
Figure 13.5.2. Comparisons related to the computation of the derivative of sine.
Examining the graphs of these trigonometric functions, we clearly see that for \(\change{t} \approx 0 \) we have \(\cos(\change{t}) \approx 1 \text{,}\) and it also appears that \(\sin(\change{t}) \) values become very close to values of \(\change{t} \text{.}\) But in each of these cases we can say something much stronger about how close these approximations are relative to the size of \(\change{t} \text{.}\)

Justification.

We will verify the statement for positive values of \(\theta \approx 0 \text{;}\) the justification for negative values of \(\theta \) is similar.
Recall that values of \(\sin(\theta) \) represent the \(y \)-coordinate of a position on the unit circle. That is, in Figure 13.5.4, the value of \(\sin(\theta) \) is the equal to the triangle side length marked \(y \text{.}\)
Diagram comparing the values of the sine and cosine functions with the angle measure.
Figure 13.5.4. Diagram comparing the values of \(\sin(\theta) \text{,}\) \(\cos(\theta) \text{,}\) and \(\theta \text{.}\)
Now, we have \(y \lt a \) because \(a \) is the length of the hypotenuse in a right triangle and \(y \) is the length of one of the legs of that triangle. We also have \(a \lt \theta \) because the arc that \(\theta \) measures has the same endpoints as the segment measured by \(a \text{,}\) but the segment takes a straight path between those points. Going out further, for a similar reason we can say \(\theta \lt b + d \text{.}\) But also \(d \lt c \) because \(c \) is a hypotenuse and \(d \) is a leg. And we have \(b + c = \tan(\theta) \) by using opposite-over-adjacent in the large right triangle. So we finally have
\begin{equation*} \sin(\theta) = y \lt a \lt \theta \lt b + d \lt b + c = \tan(\theta) \text{.} \end{equation*}
Splitting in two at \(\theta \) and doing a little re-arranging, we have
\begin{align*} \sin(\theta) \amp \lt \theta \amp \theta \amp \lt \tan(\theta) \\ \frac{\sin(\theta)}{\theta} \amp\lt 1 \text{,} \amp \theta \amp \lt \frac{\sin(\theta)}{\cos(\theta)} \\ \amp\amp \cos(\theta) \amp \lt \frac{\sin(\theta)}{\theta} \text{.} \end{align*}
(Note that for \(\theta \approx 0 \) but positive, the value of \(\cos(\theta) \) is also positive, so multiplying or dividing both sides of an inequality by either \(\theta \) or \(\cos(\theta) \) will not reverse the inequality.)
Combining these inequalities, we have
\begin{equation*} \cos(\theta) \lt \frac{\sin(\theta)}{\theta} \lt 1 \qquad \text{for} \qquad \theta \approx 0^+\text{,} \end{equation*}
where the superscript \(+ \) indicates that \(\theta \) is assumed to be positive. This inequality says that the graph of \(\sin(\theta)/\theta \text{,}\) whatever it might look like, will be confined to the shaded region in Figure 13.5.5 below. For \(\theta \approx 0^+ \text{,}\) this graph must be squeezed into the little wedge in the upper-left corner of the shaded region, very close to a height of \(1 \text{,}\) and so we conclude
\begin{equation*} \frac{\sin(\theta)}{\theta} \approx 1 \qquad \text{for} \qquad \theta \approx 0^+\text{.} \end{equation*}
Diagram illustrating a region to which the graph of sine divided by independent variable must be confined.
Figure 13.5.5. For \(0 \lt \theta \lt \pi/2 \text{,}\) the graph of \(\sin(\theta)/\theta \) is confined to the shaded region.
The following corresponding property of the cosine function can be justified in a similar manner.

Remark 13.5.7.

The statement that
\begin{equation*} \frac{\cos(\theta) - 1}{\theta} \approx 0 \end{equation*}
for \(\theta \approx 0 \) says something stronger than just \(\cos(\theta) \approx 1 \text{.}\) In the ratio
\begin{equation*} \frac{\cos(\theta) - 1}{\theta} \text{,} \end{equation*}
both the numerator and denominator are approximately \(0 \) for small values of \(\theta \text{.}\) But similarly to Section 4.2, it becomes a “race” to \(0 \text{.}\) The fact that
\begin{equation*} \frac{\cos(\theta) - 1}{\theta} \approx 0 \end{equation*}
says that the numerator “wins” the race, so that the approximation \(\cos(\theta) \approx 1 \) must be very tight compared to \(\theta \approx 0 \) since if it were the other way around then we would expect the expression
\begin{equation*} \frac{\cos(\theta) - 1}{\theta} \end{equation*}
to have a singularity at \(\theta = 0 \text{.}\)
Finally, let’s return to our analysis of the derivative of sine. Pattern 13.5.3 implies that
\begin{equation*} \frac{ \sin(\change{t}) }{ \change{t} } \to 1 \qquad \text{as} \qquad \change{t} \to 0\text{,} \end{equation*}
and Pattern 13.5.6 implies that
\begin{equation*} \frac{ \bbrac{\cos(\change{t}) - 1} }{ \change{t} } \to 0 \qquad \text{as} \qquad \change{t} \to 0\text{.} \end{equation*}
Using these limits, for \(q(t) = \sin(t) \) we have
\begin{align*} \lim_{ \change{t} \to 0 } \slope{q}{t} \amp = \lim_{ \change{t} \to 0 } \left( \sin(t) \cdot \frac{ \bbrac{\cos(\change{t}) - 1} }{ \change{t} } + \frac{ \sin(\change{t}) }{ \change{t} } \cdot \cos(t) \right)\\ \amp = \lim_{ \change{t} \to 0 } \left( \sin(t) \cdot \frac{ \bbrac{\cos(\change{t}) - 1} }{ \change{t} } \right) + \lim_{ \change{t} \to 0 } \left( \frac{ \sin(\change{t}) }{ \change{t} } \cdot \cos(t) \right)\\ \amp = \sin(t) \cdot \left( \lim_{ \change{t} \to 0 } \frac{ \bbrac{\cos(\change{t}) - 1} }{ \change{t} } \right) + \left( \lim_{ \change{t} \to 0 } \frac{ \sin(\change{t}) }{ \change{t} } \right) \cdot \cos(t)\\ \amp = \sin(t) \cdot 0 + 1 \cdot \cos(t) \\ \amp = \cos(t) \text{.} \end{align*}
A similar analysis for the cosine function yields the derivative formula predicted at the beginning of this section from the mass-on-spring model.

Checkpoint 13.5.9. Verifying the derivative of the cosine function.

Verify the formula for the derivative of cosine in Pattern 13.5.8 in two ways.

(a) Using the limit definition of the derivative.

Similar to the derivation of the derivative of the sine function in this section, combine Pattern 13.3.9 with Pattern 13.5.3 and Pattern 13.5.6 to verify that for \(q(t) = \cos(t) \text{,}\)
\begin{equation*} \lim_{ \change{t} \to 0 } \slope{q}{t} = - \sin(t) \text{.} \end{equation*}

(b) By realizing cosine as a shift of sine.

Starting with the identity
\begin{equation*} \cos(t) = \sin(t + \pi / 2) \end{equation*}
from Pattern 13.3.6, combine Pattern 6.3.15 with the formula for the derivative of sine from Pattern 13.5.8. Finally, use another identity from Pattern 13.3.6 to express your result in terms of sine.
Derivatives of the other four trigonometric functions will have to wait until we have developed some further differentiation rules.

Section 13.6 Integrals of the sine and cosine functions

Let’s return once more to the setup at the beginning of Section 13.5, where we considered
\begin{align*} v(t) \amp = \sin(t) \text{,} \amp s(t) = - \cos(t) \end{align*}
for the mass-on-spring system from Example 13.1.1.
As the mass begins to move, it accumulates displacement from the initial position \(s(0) = -1 \text{.}\) Applying Pattern 9.4.7 to the “quantity” function \(s(t) \) and its rate function \(v(t) \text{,}\) we have
\begin{align*} s(t) \amp = s(0) + \ccmint{0}{t}{v(u)}{u} \\ \amp = -1 + \ccmint{0}{t}{\sin(u)}{u} \text{.} \end{align*}
On the other hand, we have already modelled the position function as \(s(t) = - \cos(t) \text{.}\) So
\begin{equation*} - \cos(t) = -1 + \ccmint{0}{t}{\sin(u)}{u} \text{.} \end{equation*}
For a cosine rate function, we once again reset the “initial” time for the mass-on-spring system to when it is first moving through the equilibrium position, which yielded Figure 13.5.1 and shifted velocity and position functions
\begin{align*} v(t) \amp = \cos(t) \text{,} \amp s(t) \amp = \sin(t) \text{.} \end{align*}
And again we think of the mass as accumulating displacement from its initial position and apply Pattern 9.4.7:
\begin{align*} s(t) \amp = s(0) + \ccmint{0}{t}{v(u)}{u} \\ \amp = 0 + \ccmint{0}{t}{\cos(u)}{u} \text{.} \end{align*}
As we have decided that position in this shifted scenario should be modelled as \(s(t) = \sin(t) \text{,}\) we have
\begin{equation*} \sin(t) = 0 + \ccmint{0}{t}{\cos(u)}{u} \text{.} \end{equation*}

Example 13.6.3. Computing an accumulation for a rate function involving sine and cosine.

Suppose we would like to compute
\begin{equation*} \ccmint{\frac{\pi}{2}}{\frac{3 \pi}{2}}{ 3 \sin(t) + 5 \cos(t) }{t} \text{.} \end{equation*}
As usual, we use Pattern 9.3.11 to split into separate integrals and factor out the constant multiples:
\begin{equation*} \ccmint{\frac{\pi}{2}}{\frac{3 \pi}{2}}{ 3 \sin(t) + 5 \cos(t) }{t} = 3 \ccmint{\frac{\pi}{2}}{\frac{3 \pi}{2}}{\sin(t)}{t} + 5 \ccmint{\frac{\pi}{2}}{\frac{3 \pi}{2}}{\cos(t)}{t}\text{.} \end{equation*}
Let’s continue by computing these two integrals separately. As we’ve done before in other examples, we use Item 5 of Pattern 9.3.11 to manipulate the bounds of integration so that we can use our formulas from Pattern 13.6.1 and Pattern 13.6.2, which both involve a lower bound of \(0 \text{.}\)
\begin{align*} \amp \ccmint{\frac{\pi}{2}}{\frac{3 \pi}{2}}{\sin(t)}{t} \amp \amp \ccmint{\frac{\pi}{2}}{\frac{3 \pi}{2}}{\cos(t)}{t}\\ \amp \qquad = \ccmint{0}{\frac{3 \pi}{2}}{\sin(t)}{t} - \ccmint{0}{\frac{\pi}{2}}{\sin(t)}{t} \amp \amp \qquad = \ccmint{0}{\frac{3 \pi}{2}}{\cos(t)}{t} - \ccmint{0}{\frac{\pi}{2}}{\cos(t)}{t}\\ \amp \qquad = \bbrac{1 - \cos(3 \pi / 2)} - \bbrac{1 - \cos(\pi/2)} \amp \amp \qquad = \sin(3 \pi / 2) - \sin (\pi / 2)\\ \amp \qquad = (1 - 0) - (1 - 0) \amp \amp \qquad = -1 - 1\\ \amp \qquad = 0 \amp \amp \qquad = -2 \end{align*}
We should have expected that the integral on the left would evaluate to \(0 \text{,}\) by the symmetry of the rate function \(\sin(t) \) — the positively-oriented area over the domain \(\pi / 2 \le t \le \pi \) is the same magnitude as the negatively-oriented area over the domain \(\pi \le t \le 3 \pi / 2 \text{,}\) and so cancel out when combined over the domain \(\pi / 2 \le t \le 3 \pi / 2 \text{.}\)
Finally, we combine the two results above to compute the original integral.
\begin{align*} \ccmint{\frac{\pi}{2}}{\frac{3 \pi}{2}}{ 3 \sin(t) + 5 \cos(t) }{t} \amp = 3 \ccmint{\frac{\pi}{2}}{\frac{3 \pi}{2}}{\sin(t)}{t} + 5 \ccmint{\frac{\pi}{2}}{\frac{3 \pi}{2}}{\cos(t)}{t}\\ \amp = 3 \cdot 0 + 5 \cdot (-2) \\ \amp = -10 \end{align*}
We will learn how to determine accumulation for a rate function modelled by the tangent function in Chapter 15.