Tangent Calculator
Find tan(α) from an angle in degrees or radians, inspect the sine-over-cosine calculation, and export the current result to a validated Excel workbook.
Angle input
Use a decimal number with a period as the decimal separator. Scientific notation is accepted.
Live result
At 45°, the opposite-to-adjacent ratio is 1.
Tangent function and your angle
The curve shows two periods of y = tan(x). Values beyond ±5 are clipped so the asymptotes remain readable.
Calculation details
| Quantity | Exact relationship | Current value |
|---|---|---|
| Angle in degrees | α | 45° |
| Angle in radians | α × π ÷ 180 | 0.785398163397 rad |
| Sine | sin(α) | 0.707106781187 |
| Cosine | cos(α) | 0.707106781187 |
| Tangent | sin(α) ÷ cos(α) | 1 |
How to use the tangent calculator
What this calculator does
This calculator evaluates the trigonometric tangent of a real angle. It converts the entered angle to radians for the numerical calculation, finds sin(α) and cos(α), and then applies tan(α) = sin(α) ÷ cos(α). The result is an exact trigonometric identity evaluated to finite machine precision; it is not a triangle solver and it does not determine missing side lengths by itself. For the underlying definition, OpenStax explains tangent as the ratio of the opposite side to the adjacent side in right-triangle trigonometry.
When to use it
Use the calculator when checking homework or engineering calculations, converting a degree-based angle before using software that expects radians, confirming the slope ratio associated with an angle, or examining how tangent changes near its vertical asymptotes. It is also useful for verifying special-angle values such as tan(30°), tan(45°), and tan(60°).
How to calculate
- The calculator opens with the complete demonstration Angle α = 45 and Degrees (°), so the first result and Excel workbook are available immediately.
- Replace 45 in Angle α with your number. Use a period for decimals; values such as – 30, 0.5, and 1e3 are accepted. Commas, degree symbols, and mixed-unit text are rejected to avoid ambiguous interpretation.
- Choose Degrees (°) or Radians (rad) in the angle-unit control. Switching the unit converts the current valid angle rather than merely relabeling it.
- Read Tangent of α as the main result. Review Angle in degrees, Angle in radians, sin(α), and cos(α) to audit the conversion and formula.
- Use the graph to locate the equivalent angle within the displayed – 180° to 180° window. The curve is clipped at ±5 for legibility, so very large finite tangent values may be reported as off-scale.
- Select Download Excel to create a validated .xlsx workbook from the current controls and canonical result. Select Reset to clear the demonstration input and results; Excel download remains disabled until a complete valid angle is entered again.
Input guide
Angle α is required and accepts a finite real number in decimal or scientific notation. Its unit is determined by the adjacent selector. A realistic example is 30 degrees or 0.5235987756 radians. Increasing the angle does not make tangent increase globally because tangent repeats every 180° or π radians; within each interval between asymptotes, however, the function increases. Avoid entering commas, a degree sign, “pi,” or a fraction such as π/4 – the field is deliberately numeric so pasted notation cannot be silently misread. The supported magnitude is limited to an absolute value of 1 billion radians after conversion, protecting the calculation from severe floating-point argument-reduction error.
Angle unit is required and offers Degrees (°) and Radians (rad). Degrees are common in geometry; radians are the coherent SI unit for plane angle, described by NIST's definition of the radian. Changing the selector converts a valid current input so the represented angle and tangent remain the same. A common mistake is entering 45 while Radians is selected, which means 45 radians – not 45 degrees.
Output guide
Tangent of α is the dimensionless ratio sin(α)/cos(α). Positive and negative values indicate the sign of the opposite-to-adjacent ratio; zero occurs at integer multiples of 180°; large magnitude values occur close to odd multiples of 90°. At those odd multiples, cosine is zero and tangent is shown as undefined rather than as an enormous misleading number. Angle in degrees and Angle in radians are exact unit conversions displayed to practical precision. sin(α) and cos(α) are intermediate dimensionless values used to audit the formula. The Unit, Period, and Status pills summarize the active unit, tangent's repeat interval, and whether the current tangent is defined.
The Calculation details table repeats the current conversion and formula path. The graph's blue Tangent curve represents y = tan(x), while the teal Your angle marker represents the current angle reduced by whole 360° turns into the displayed window. The curve's vertical breaks are asymptotes, not missing data. OpenStax's discussion of graphs of tangent and related functions explains the period and asymptotic shape.
Worked example
The startup example uses 45°. Converting gives 45 × π ÷ 180 = 0.785398163397 radians. At that angle, sin(45°) ≈ 0.707106781187 and cos(45°) ≈ 0.707106781187. Dividing the two equal values gives tan(45°) = 1. The result means the opposite and adjacent legs of a corresponding right triangle have equal length. The graph places the current marker at (45°, 1), and the workbook records the same typed input, conversions, intermediate values, status, and primary result.
How the tangent formula behaves
Tangent is periodic: tan(α + 180°) = tan(α), or in radians tan(α + π) = tan(α). This is why 45°, 225°, and – 135° all have tangent 1. The function is also odd, so tan( – α) = – tan(α). These identities are useful checks when comparing results.
The expression becomes undefined wherever cos(α) = 0. Near those angles, a tiny input change can cause a very large change in the result and may flip its sign. That behavior is mathematically correct, but it also means measurement uncertainty near an asymptote can dominate a practical calculation. Wolfram MathWorld gives the same core identity in its definition of the tangent function.