Skip to main content

Tangent Calculator

Calculate tangent instantly with our math tool. Shows detailed work, formulas used, and multiple solution methods. Get results you can export or share.

Skip to calculator
Mathematics

Tangent Calculator

Calculate tangent values for any angle in degrees or radians. Find tan, arctan, and all related trigonometric ratios with step-by-step solutions.

Last updated: December 2025Reviewed by NovaCalculator Mathematics Team

Calculator

Adjust values & calculate
45°
Tangent Value
1.00000000
tan(45°) | Quadrant 1 | Positive
sin(45°)
0.70710678
cos(45°)
0.70710678
cot(45°)
1.00000000
Angle in Degrees
45.0000\u00B0
Angle in Radians
0.785398 rad
sec(45°)
1.41421356
csc(45°)
1.41421356
Your Result
tan(45°) = 1.00000000 | Quadrant 1
Share Your Result
Understand the Math

Formula

tan(theta) = opposite / adjacent = sin(theta) / cos(theta)

Where theta is the angle in question, opposite is the side across from the angle, adjacent is the side next to the angle (not the hypotenuse). Tangent can also be computed as the ratio of sine to cosine of the same angle.

Last reviewed: December 2025

Worked Examples

Example 1: Finding the Height of a Building

You stand 50 meters from a building and measure the angle of elevation to the top as 32 degrees. What is the height of the building?
Solution:
Using tan(angle) = opposite / adjacent: tan(32) = height / 50 height = 50 x tan(32) tan(32) = 0.6249 height = 50 x 0.6249 = 31.24 meters
Result: The building is approximately 31.24 meters tall

Example 2: Calculating a Roof Slope Angle

A roof rises 4 feet over a horizontal run of 12 feet. What is the angle of the roof slope?
Solution:
Using arctan(opposite / adjacent): tan(angle) = 4 / 12 = 0.3333 angle = arctan(0.3333) angle = 18.43 degrees
Result: The roof slope angle is approximately 18.43 degrees (a 4:12 pitch)
Expert Insights

Background & Theory

The Tangent Calculator applies the following established principles and formulas. Mathematics rests on a hierarchy of number systems, each extending the previous. The natural numbers (1, 2, 3, ...) support counting and ordering. The integers add negative values and zero, enabling subtraction without restriction. The rational numbers, expressible as p/q where p and q are integers and q is nonzero, close the system under division. The real numbers fill the gaps left by irrationals such as the square root of 2 or pi, forming a complete ordered field. The complex numbers, written as a + bi where i is the square root of negative one, complete the algebraic closure of the reals and allow every polynomial to have a root. Prime factorization states that every integer greater than one is uniquely expressible as a product of primes, a result known as the Fundamental Theorem of Arithmetic. Computing the greatest common divisor (GCD) of two integers relies most efficiently on the Euclidean algorithm: repeatedly replace the larger number with the remainder when it is divided by the smaller, until the remainder is zero. The last nonzero remainder is the GCD. The least common multiple (LCM) follows from the identity LCM(a, b) = |a * b| / GCD(a, b). Modular arithmetic defines equivalence classes of integers that share the same remainder under division by a modulus n. Fermat's Little Theorem and Euler's Theorem arise from this structure and underpin modern cryptography. Logarithms are the inverses of exponential functions. If b raised to the power x equals y, then the logarithm base b of y equals x. The natural logarithm uses base e, approximately 2.71828. Combinatorics counts arrangements and selections. The number of ordered arrangements (permutations) of r objects from n distinct objects is nPr = n! / (n - r)!. The number of unordered selections (combinations) is nCr = n! / (r! * (n - r)!). Pascal's triangle arranges these binomial coefficients so that each entry equals the sum of the two entries directly above it. The Fibonacci sequence, defined by F(1) = 1, F(2) = 1, and F(n) = F(n-1) + F(n-2), appears throughout nature and connects deeply to the golden ratio via Binet's formula.

History

The history behind the Tangent Calculator traces back through the following developments. Mathematics as a systematic discipline traces to ancient Mesopotamia. Babylonian clay tablets dating to around 1800 BCE demonstrate knowledge of quadratic equations, Pythagorean triples, and base-60 arithmetic, suggesting a practical mathematical tradition far preceding Greek formalism. Euclid of Alexandria compiled the Elements around 300 BCE, establishing the axiomatic method that would define rigorous mathematics for over two thousand years. His work organized plane geometry, number theory, and proportion into logically chained propositions derived from a small set of postulates. The algorithm bearing his name for computing GCDs appears in Book VII and remains in use today. In the 9th century, the Persian scholar Muhammad ibn Musa Al-Khwarizmi wrote Al-Kitab al-mukhtasar fi hisab al-jabr wal-muqabala, the treatise whose title gave algebra its name. He systematized the solution of linear and quadratic equations and described procedures that operated on unknowns as objects, a conceptual leap away from purely numerical calculation. Rene Descartes introduced coordinate geometry in 1637 by uniting algebra and Euclidean geometry, allowing curves to be studied through equations. This synthesis set the stage for calculus. Isaac Newton and Gottfried Wilhelm Leibniz independently developed calculus during the 1660s and 1670s, triggering a priority dispute that lasted decades and divided British and Continental mathematicians. Carl Friedrich Gauss proved the Fundamental Theorem of Algebra in 1799, showing that every nonconstant polynomial has at least one complex root. His Disquisitiones Arithmeticae of 1801 established modern number theory. David Hilbert's formalist program at the turn of the 20th century sought to place all of mathematics on an explicit axiomatic foundation, a project that Kurt Godel's incompleteness theorems of 1931 showed to be fundamentally limited. Alan Turing's work in the 1930s on computability introduced the theoretical model of the stored-program computer and linked mathematical logic directly to the limits of algorithmic calculation. His proof that no algorithm can decide in general whether an arbitrary program will halt or run forever placed fundamental boundaries on what mathematics can mechanically determine, and it opened the discipline now known as theoretical computer science.

Share this calculator

Explore More

Frequently Asked Questions

The tangent function is one of the six fundamental trigonometric functions. In a right triangle, tangent of an angle equals the ratio of the length of the opposite side to the length of the adjacent side. Mathematically it is expressed as tan(theta) = opposite / adjacent. The tangent function can also be defined as the ratio of sine to cosine: tan(theta) = sin(theta) / cos(theta). Unlike sine and cosine which are bounded between -1 and 1, the tangent function has no bounds and ranges from negative infinity to positive infinity. It is periodic with a period of 180 degrees or pi radians.
The tangent function is undefined at angles where the cosine equals zero, because tangent is calculated as sine divided by cosine. This occurs at 90 degrees (pi/2 radians), 270 degrees (3pi/2 radians), and all odd multiples of 90 degrees. At these points, the tangent function approaches positive or negative infinity, creating vertical asymptotes on the graph. In practical terms, a 90-degree angle in a right triangle would mean the adjacent side has zero length, making the ratio opposite/adjacent undefined. Understanding these discontinuities is crucial for graphing tangent and solving trigonometric equations correctly.
To convert degrees to radians, multiply the degree value by pi/180. To convert radians to degrees, multiply the radian value by 180/pi. For example, 45 degrees equals pi/4 radians (45 times pi/180 = pi/4), and pi/3 radians equals 60 degrees (pi/3 times 180/pi = 60). Common reference angles include 30 degrees (pi/6), 45 degrees (pi/4), 60 degrees (pi/3), and 90 degrees (pi/2). Most scientific calculators and programming languages require the angle in radians, so this conversion is essential when computing tangent values programmatically.
Several tangent values appear frequently in mathematics and should be memorized. Tan(0) = 0, tan(30) = 1/sqrt(3) which is approximately 0.5774, tan(45) = 1, tan(60) = sqrt(3) which is approximately 1.7321, and tan(90) is undefined. For angles in the second quadrant, tan(120) = -sqrt(3), tan(135) = -1, and tan(150) = -1/sqrt(3). In the third quadrant tangent values become positive again: tan(180) = 0, tan(210) = 1/sqrt(3), tan(225) = 1, tan(240) = sqrt(3). These reference values help you quickly verify calculator results and solve problems mentally.
Tangent has numerous practical applications across engineering, physics, and everyday life. Surveyors use tangent to calculate the height of buildings and mountains by measuring the angle of elevation and the horizontal distance. In navigation, tangent helps determine slopes and gradients of roads and railways. Civil engineers use it to design ramps, roofs, and inclined surfaces. In physics, tangent appears in projectile motion calculations and in determining the angle of friction on inclined planes. Architects use tangent relationships when designing staircases, calculating rise over run. Even smartphone apps use tangent-based calculations for augmented reality features and altitude measurements.
The inverse tangent function, written as arctan or tan^(-1), reverses the tangent operation. Given a tangent value, arctangent returns the angle that produces that value. For example, arctan(1) = 45 degrees because tan(45) = 1. The arctangent function has a restricted range of -90 to 90 degrees (-pi/2 to pi/2 radians) to ensure it returns a single unique value. This is important in programming and engineering when you need to find an angle from a known ratio of sides. The two-argument form atan2(y, x) is preferred in many applications because it correctly handles all four quadrants and avoids division by zero issues.
Educational Note: This calculator is provided for educational and informational purposes. Results are based on the formulas and inputs provided. Always verify important calculations independently. NovaCalculator processes calculator inputs client-side; optional analytics follow visitor consent settings.Reviewed by: NovaCalculator Mathematics TeamVerified against standard mathematical and scientific references. Last reviewed: December 2025. © 2024–2026 NovaCalculator.

Share this calculator

Formula

tan(theta) = opposite / adjacent = sin(theta) / cos(theta)

Where theta is the angle in question, opposite is the side across from the angle, adjacent is the side next to the angle (not the hypotenuse). Tangent can also be computed as the ratio of sine to cosine of the same angle.

Worked Examples

Example 1: Finding the Height of a Building

Problem: You stand 50 meters from a building and measure the angle of elevation to the top as 32 degrees. What is the height of the building?

Solution: Using tan(angle) = opposite / adjacent:\ntan(32) = height / 50\nheight = 50 x tan(32)\ntan(32) = 0.6249\nheight = 50 x 0.6249 = 31.24 meters

Result: The building is approximately 31.24 meters tall

Example 2: Calculating a Roof Slope Angle

Problem: A roof rises 4 feet over a horizontal run of 12 feet. What is the angle of the roof slope?

Solution: Using arctan(opposite / adjacent):\ntan(angle) = 4 / 12 = 0.3333\nangle = arctan(0.3333)\nangle = 18.43 degrees

Result: The roof slope angle is approximately 18.43 degrees (a 4:12 pitch)

Frequently Asked Questions

What is the tangent function in trigonometry?

The tangent function is one of the six fundamental trigonometric functions. In a right triangle, tangent of an angle equals the ratio of the length of the opposite side to the length of the adjacent side. Mathematically it is expressed as tan(theta) = opposite / adjacent. The tangent function can also be defined as the ratio of sine to cosine: tan(theta) = sin(theta) / cos(theta). Unlike sine and cosine which are bounded between -1 and 1, the tangent function has no bounds and ranges from negative infinity to positive infinity. It is periodic with a period of 180 degrees or pi radians.

When is the tangent function undefined?

The tangent function is undefined at angles where the cosine equals zero, because tangent is calculated as sine divided by cosine. This occurs at 90 degrees (pi/2 radians), 270 degrees (3pi/2 radians), and all odd multiples of 90 degrees. At these points, the tangent function approaches positive or negative infinity, creating vertical asymptotes on the graph. In practical terms, a 90-degree angle in a right triangle would mean the adjacent side has zero length, making the ratio opposite/adjacent undefined. Understanding these discontinuities is crucial for graphing tangent and solving trigonometric equations correctly.

How do I convert between degrees and radians for tangent calculations?

To convert degrees to radians, multiply the degree value by pi/180. To convert radians to degrees, multiply the radian value by 180/pi. For example, 45 degrees equals pi/4 radians (45 times pi/180 = pi/4), and pi/3 radians equals 60 degrees (pi/3 times 180/pi = 60). Common reference angles include 30 degrees (pi/6), 45 degrees (pi/4), 60 degrees (pi/3), and 90 degrees (pi/2). Most scientific calculators and programming languages require the angle in radians, so this conversion is essential when computing tangent values programmatically.

What are the common tangent values I should memorize?

Several tangent values appear frequently in mathematics and should be memorized. Tan(0) = 0, tan(30) = 1/sqrt(3) which is approximately 0.5774, tan(45) = 1, tan(60) = sqrt(3) which is approximately 1.7321, and tan(90) is undefined. For angles in the second quadrant, tan(120) = -sqrt(3), tan(135) = -1, and tan(150) = -1/sqrt(3). In the third quadrant tangent values become positive again: tan(180) = 0, tan(210) = 1/sqrt(3), tan(225) = 1, tan(240) = sqrt(3). These reference values help you quickly verify calculator results and solve problems mentally.

How is tangent used in real-world applications?

Tangent has numerous practical applications across engineering, physics, and everyday life. Surveyors use tangent to calculate the height of buildings and mountains by measuring the angle of elevation and the horizontal distance. In navigation, tangent helps determine slopes and gradients of roads and railways. Civil engineers use it to design ramps, roofs, and inclined surfaces. In physics, tangent appears in projectile motion calculations and in determining the angle of friction on inclined planes. Architects use tangent relationships when designing staircases, calculating rise over run. Even smartphone apps use tangent-based calculations for augmented reality features and altitude measurements.

What is the inverse tangent or arctangent function?

The inverse tangent function, written as arctan or tan^(-1), reverses the tangent operation. Given a tangent value, arctangent returns the angle that produces that value. For example, arctan(1) = 45 degrees because tan(45) = 1. The arctangent function has a restricted range of -90 to 90 degrees (-pi/2 to pi/2 radians) to ensure it returns a single unique value. This is important in programming and engineering when you need to find an angle from a known ratio of sides. The two-argument form atan2(y, x) is preferred in many applications because it correctly handles all four quadrants and avoids division by zero issues.

References

Reviewed by Manoj Kumar, Mathematics Educator · Editorial policy