standarddeviationcalculator.net

Updated Free · runs in your browser

Math

Tangent calculator

Enter an angle for tan θ, exact for standard angles and flagged as undefined where cosine is zero. The other modes turn a tangent value, the two legs of a right triangle, or a slope written as a gradient or percentage grade back into an angle.

Type 30, 30°, pi/6, π/3, 1.2 rad or 36°52′. Anything with π is read as radians.

tan 60° √3 ≈ 1.73205
Exact value√3
Decimal1.732050808
Degrees60°
Radiansπ/3 = 1.0472
Gradians66.6667
PositionQuadrant I
Reference angle60°
Sign of tan+ (tan is positive in quadrants I and III, negative in II and IV)
As a slopegradient 1.73205 = 173.205% grade
1−11−1xyθ(0.5, 0.866)

The point at θ on the unit circle is (cos θ, sin θ) = (0.5, 0.866025). The yellow segment on the line x = 1 has length tan θ.

Show the working, step by step
  1. 60° is in quadrant I, where all six functions are positive, so it is its own reference angle.

    reference angle = 60°

  2. Evaluate tan directly (a standard angle, so the exact value is known).

    tan 60° = √3 ≈ 1.73205

What tangent means

tan θ = opposite ÷ adjacent = sin θ ÷ cos θ

In a right triangle, tangent is the side opposite the angle divided by the side next to it: rise over run. That makes it the natural function for slopes. A line making angle θ with the horizontal has gradient m = tan θ. On the unit circle, tan θ is the length of the segment cut off on the vertical line x = 1, the yellow segment in the drawing, which is where the name (Latin tangens, touching) comes from.

A worked example

The calculator opens with θ = 60°.

  1. 60° is in quadrant I, where tangent is positive.
  2. sin 60° = √3/2 and cos 60° = 1/2, so tan 60° = (√3/2) ÷ (1/2) = √3 ≈ 1.73205.
  3. As a slope, a 60° line rises 1.73205 for every 1 across, a 173.2% grade.

Where tangent is undefined

Tangent divides by cos θ, which is zero at 90°, 270° and every 90° + k·180° (π/2 + kπ in radians). At those angles the calculator reports “undefined” rather than a huge number. Between them the tangent takes every real value once, which is why its period is 180° and why arctan accepts any input.

Tangent values to know

θRadianstan θ exactDecimal
0°000
15°π/122 − √30.267949
30°π/6√3/30.57735
45°π/411
60°π/3√31.73205
75°5π/122 + √33.73205
90°π/2undefined—

Slopes, grades and pitches

Every slope measure is a tangent in disguise. Choose “Slope or grade → angle” and type a gradient (0.5, 3/4) or a grade with a percent sign. The default, an 8% road, is arctan 0.08 = 4.57392°. Some reference points:

SlopeGradientAngle
1:12 wheelchair ramp0.08334.76°
25% grade0.2514.04°
6 in 12 roof pitch0.526.57°
100% grade145°
1000% grade1084.29°

Tangent also measures heights you cannot reach. Standing 50 m from a building and sighting its top at 32° above the horizontal, the height above eye level is 50 × tan 32° = 31.2 m.

Common mistakes

  • Reading a grade as an angle. A 10% slope is 5.71°, not 10°; a 100% slope is 45°.
  • Missing the second solution. tan θ = k also holds 180° after the principal value.
  • Radian mode. tan 1 is 1.55741 in radians and 0.0174551 in degrees.

Common questions

Why is tan 90° undefined?

tan θ = sin θ ÷ cos θ, and cos 90° = 0, so the division has no answer. Close to 90° the tangent grows without limit: tan 89° = 57.29 and tan 89.9° = 572.96. The same happens at 270° and at every 90° + k·180°, which is where the graph of tan x has its vertical asymptotes.

How do I convert a slope or grade to an angle?

Take the inverse tangent of the gradient. A slope of 0.5 (rise 1 over run 2) is arctan 0.5 = 26.57°. For a percentage grade, divide by 100 first: an 8% road is arctan 0.08 = 4.57°. A 100% grade is 45°, not 90°.

What is the difference between tan⁻¹ and cot?

tan⁻¹ x means the inverse tangent, arctan x: the angle whose tangent is x. cot x is the reciprocal, 1 ÷ tan x. They are not the same: tan⁻¹(1) = 45°, while cot(1 rad) = 0.642.

How many solutions does tan θ = k have?

Two in every full turn, 180° apart, for any real k. tan θ = 1 gives θ = 45° and 225°, and the general solution is θ = 45° + 180°n. Tangent repeats every 180° (π radians), not every 360°.

What is a 4 in 12 roof pitch in degrees?

A rise of 4 over a run of 12 is a gradient of 4/12 = 0.3333, so the angle is arctan(0.3333) = 18.43°. A 6 in 12 pitch is 26.57°, and a 12 in 12 pitch is 45°.