1001Ferramentas
📐 Calculators

Tangent Calculator

Calculate the tangent of an angle in degrees, radians or gradians. Shows "Undefined" when the tangent does not exist.

What is Tangent?

The tangent of an angle θ is the ratio of the opposite side to the adjacent one: tan(θ) = sin(θ) / cos(θ). Unlike sine and cosine, it has no bound and can take any real value.

Among the notable values are tan(0°) = 0, tan(30°) ≈ 0.5774, tan(45°) = 1 and tan(60°) ≈ 1.7321. At 90°, 270° and the other odd multiples of 90°, tangent becomes undefined.

Unit conversions: 1° equals π/180 rad ≈ 0.01745 rad, while 1 rad equals 180°/π ≈ 57.296°. And 400 gradians correspond to 360°.

The tangent function

The tangent is defined as tan(θ) = sin(θ)/cos(θ), which in a right triangle equals the ratio opposite side / adjacent side. It has period π (half that of sine and cosine) and vertical asymptotes wherever the cosine vanishes, i.e. at θ = π/2 + kπ. It is an odd function: tan(−θ) = −tan(θ). Reference values: tan(0) = 0, tan(30°) = √3/3, tan(45°) = 1, tan(60°) = √3, and tan(90°) undefined. Its derivative is (tan x)' = sec²x.

Applications: slopes, roofs and accessibility

The tangent is the natural way to express slope: a ramp with angle α has tan(α) = rise / run. The Brazilian accessibility standard NBR 9050 caps ramps at 8.33% (about 4.76°). Roofers use it to convert pitch to angle, surveyors measure building heights by reading the angle of elevation to the top and applying height = distance · tan(α), optics uses it in Snell's law and Brewster's angle, and GPS triangulation relies on tangent ratios between known points.

FAQ

Why is tan(90°) undefined? Because cos(90°) = 0, the ratio sin/cos blows up. The function has a vertical asymptote there.

Why is the period π and not 2π? Both sine and cosine flip sign together every π, so the ratio repeats twice as fast as either one.

How do I get a roof angle from pitch? If the roof rises 30 cm per metre, the pitch is 30%; the angle is arctan(0.30) ≈ 16.7°.

How do I measure a building from its shadow? Measure the shadow length and the sun's angle of elevation α; the height is shadow · tan(α).

Related Tools

Calculate the tangent of an angle

The tangent is the ratio between sine and cosine, and it has a curious quirk: it "blows up" at certain angles, right where the cosine is zero. This calculator finds the tangent of any angle and, at those points, displays "Undefined" to warn you.

You enter the angle in degrees, radians or gradians, and the tool handles the calculation and the special cases. That treatment of the undefined matters. At 90°, for example, the tangent doesn't exist, and a calculator that returns a giant number instead of warning ends up leading you astray.

The calculation is done in the browser. It works for trigonometry, calculating slopes and ramps, physics and engineering.