Tangent Lines to Trigonometric Functions
Find tangent lines to sin x, cos x and tan x at points like π/4 and π/3, with exact answers, chain rule cases like sin(2x), and where tan x has no tangent.
Tangent Line Trig Function: What You Need First
You need the slope at a specific x, and the slope comes from the derivative of a tangent line trig function. For sine, cosine, and tangent, those derivatives follow a pattern you can learn in ten minutes. OpenStax Calculus Vol. 1 section 3.5 gives the full list, but the three you will use most are: derivative of sin(x) is cos(x), derivative of cos(x) is -sin(x), and derivative of tan(x) is sec²(x). If the argument is not just x, say 2x or π/4, then the chain rule applies: derivative of sin(kx) is k cos(kx). The same goes for cosine and tangent.
The most common mistake is forgetting the chain rule when the trig function has an inside argument. For y = 3 sin(2x), the derivative is 3·2·cos(2x) = 6 cos(2x), not 3 cos(2x). That mistake costs you the entire answer on an exam.
Derivatives You Need: Sin, Cos, Tan, And The Chain Rule
Before you attempt any tangent line to sin x, cos x, or tan x, confirm you can differentiate the three basic forms and their chain-rule variations.
The Three Basic Derivatives
d/dx sin(x) = cos(x). d/dx cos(x) = -sin(x).These come straight from the limit definition and are the foundation for every worked case below.
Chain Rule For Scaled Arguments
When the input is kx, multiply by k. So d/dx sin(2x) = 2 cos(2x). d/dx cos(3x) = -3 sin(3x).If the argument is a function f(x), you use the full chain rule: d/dx sin(f(x)) = cos(f(x))·f'(x). That form appears in the demonstration with y = 3 sin(2x) later.
The failure case: students compute d/dx tan(π/4) as sec²(π/4) but forget that the derivative is evaluated at that point, the slope is 2, not 1.
Unit Circle Exact Values Table: Quick Reference For Tangent Lines At Pi/4 And Other Key Points
Every worked case uses exact values from the unit circle. You will need sin, cos, tan, and sec at π/4, π/3, π/6, 0, π/2, π, 3π/2, and 2π. Memorise these or bookmark this table:
| Angle x | sin(x) | cos(x) | tan(x) | sec(x) |
|---|---|---|---|---|
| 0 | 0 | 1 | 0 | 1 |
| π/6 | 1/2 | √3/2 | √3/3 | 2√3/3 |
| π/4 | √2/2 | √2/2 | 1 | √2 |
| π/3 | √3/2 | 1/2 | √3 | 2 |
| π/2 | 1 | 0 | undefined | undefined |
| π | 0 | –1 | 0 | –1 |
| 3π/2 | –1 | 0 | undefined | undefined |
| 2π | 0 | 1 | 0 | 1 |
Example: Tangent Line To Sin X At X = Pi/4
Problem: Find the equation of the tangent line to y = sin(x) at x = π/4.
Step 1, the point of tangency. f(π/4) = sin(π/4) = √2/2. So the point is (π/4, √2/2).
Step 2, the slope. f'(x) = cos(x). At x = π/4, cos(π/4) = √2/2. So the tangent line slope is √2/2.
Step 3, the equation. Use point-slope form: y, √2/2 = (√2/2)(x, π/4). If you prefer slope-intercept, distribute and simplify: y = (√2/2)x, (√2/2)(π/4) + √2/2 = (√2/2)x + (√2/2)(1, π/4).
Numerical approximation: slope ≈ 0.707, intercept ≈ 0.152. But on an exam, leave the answer in exact form.
Example: Tangent Line To Cos X At X = Pi/3
Problem: Find the tangent line to y = cos(x) at x = π/3.
Step 1, point of tangency. f(π/3) = cos(π/3) = 1/2. Point: (π/3, 1/2).
Step 2, slope. f'(x) =, sin(x). At x = π/3,, sin(π/3) =, √3/2. So the slope is, √3/2.
Step 3, equation. y, 1/2 = (, √3/2)(x, π/3). In slope-intercept: y =, (√3/2)x + (√3/2)(π/3) + 1/2.
Notice the slope is negative because cos(x) is decreasing at π/3. A common check: the slope should be negative on the downward part of the cosine wave between 0 and π.
Example: Tangent Line To Tan X At X = Pi/4
Problem: Find the tangent line to y = tan(x) at x = π/4.
Step 1, point of tangency. tan(π/4) = 1. Point: (π/4, 1).
Step 2, slope. f'(x) = sec²(x). At x = π/4, sec(π/4) = √2, so sec²(π/4) = 2. The slope is 2.
Step 3, equation. y, 1 = 2(x, π/4). Slope-intercept: y = 2x, π/2 + 1.
The slope is steep, 2, because tan(x) rises quickly near π/4. Compare this to the sin(x) case where the slope was about 0.707 at the same angle.
Example: Tangent Line To 3 Sin(2X): Chain Rule Required
Problem: Find the tangent line to y = 3 sin(2x) at x = π/4.
Step 1, point of tangency. f(π/4) = 3 sin(2·π/4) = 3 sin(π/2) = 3·1 = 3. Point: (π/4, 3).
Step 2, slope. This is where the chain rule matters. f'(x) = 3·2·cos(2x) = 6 cos(2x). At x = π/4, cos(2·π/4) = cos(π/2) = 0. So the slope is 6·0 = 0.
Step 3, equation. With slope 0, the tangent line is horizontal: y = 3.
This is a horizontal tangent line at the peak of the sine wave. The chain rule gave a non-zero derivative factor (6) but the cosine term zeroed out because 2x hit π/2.
Where Tan X Has No Tangent Line: Asymptotes At Pi/2, 3Pi/2, Etc
At those x-values, tan(x) is undefined, so there is no point on the curve and therefore no tangent line.
Some textbooks say the slope approaches +∞ from the left and, ∞ from the right. But in practical terms, if you plug x = π/2 into the derivative sec²(x), you get division by zero, undefined. Do not attempt to write a tangent line equation at an asymptote. The correct answer is 'no tangent line exists'.
For the same reason, any function that involves tan(kx) inherits those vertical asymptotes. For y = tan(2x), asymptotes occur at x = π/4 + nπ/2.
Horizontal Tangents Of Sin And Cos: Where The Derivative Equals Zero
Horizontal tangent lines occur where the slope, the derivative, equals zero. For sin(x), the derivative is cos(x), so horizontal tangents happen where cos(x) = 0: at x = π/2 + nπ. At those points, sin(x) is either 1 or, 1, so the tangent lines are y = 1 and y =, 1.
For cos(x), the derivative is, sin(x), so horizontal tangents happen where sin(x) = 0: at x = nπ. At those points, cos(x) is 1 or, 1, giving tangent lines y = 1 and y =, 1.
In the chain-rule case above, y = 3 sin(2x) produced a horizontal tangent at its peak because the derivative evaluated to zero. That pattern persists for any amplitude-scaled sine or cosine.
Who Should Practise Tangent Lines To Trig Functions
These worked cases suit AP Calculus AB/BC students and college Calculus 1 students who need to produce exact-value tangent line equations by hand. If you are a self-studying calculus learner, the step-by-step method lets you check against the limit definition of the derivative.
Skip this if you have not yet learned the limit definition of the derivative or the power rule. Start with OpenStax Calculus Vol. 1 sections 2.1 and 3.1, then come back.
Common Questions
What is the tangent line to sin x at x = 0?
f(0) = 0, f'(0) = cos(0) = 1. The line is y = x.
What is the tangent line to cos x at x = π/2?
f(π/2) = 0, f'(π/2) =, -sin(π/2) =, -1. The line is y =, -x + π/2.
Why does tan x have no tangent line at x = π/2?
Tan(π/2) is undefined because cos(π/2) = 0. Without a point on the curve, no tangent line exists. The derivative sec²(π/2) is also undefined.
Can a tangent line to a trig function be horizontal?
Yes. For sin(x), horizontal tangents occur where cos(x) = 0 (x = π/2 + nπ). For cos(x), they occur where sin(x) = 0 (x = nπ).
What if the trig function has a coefficient like y = 4 cos(3x)?
Apply the chain rule: f'(x) = 4·(, 3 sin(3x)) =, 12 sin(3x). Then evaluate at the given x.