Contact

TAN in Excel: Convert Angles into Slopes Without Hiding Singularities

Math and trigonometry Intermediate Microsoft Excel

Use Excel TAN for radians and degree-based slopes, height models, period checks and near-vertical boundaries.

Verification status: See the evidence and test scope described in this guide. How formula examples are checked

Quick answer: TAN returns the tangent of a radian angle. =TAN(45*PI()/180) is expected to return approximately 1, representing a rise-to-run ratio of one for a 45-degree slope.

Availability and version history

  • Introduced: original introduction release and first numeric build are not established by the official history reviewed.
  • Availability: the official TAN reference lists Excel for Microsoft 365, Excel for Microsoft 365 for Mac, Excel 2024, Excel 2024 for Mac, Excel 2021, Excel 2021 for Mac, Excel 2019, Excel 2016.
  • Checked: October 14, 2026. Documentation and independently calculated finite-value examples; no native Excel execution or broader platform certification.

Syntax and units

=TAN(number)

Microsoft requires the angle in radians. Convert a degree input with PI()/180 or RADIANS before passing it to TAN. The output is a ratio, not a degree measure and not a length until multiplied by a compatible length.

The examples use English function names, decimal points and comma argument separators. Keep raw inputs separately from calculated outputs so the angle-unit choice stays visible.

Example 1: build a slope control table

Enter degrees 0, 30, 45, −45 in A2:A5. In B2 enter and fill down:

=TAN(A2*PI()/180)

Expected results, approximately: 0, 0.577350269, 1, −1. The negative sign reverses the signed slope. Unlike sine or cosine, tangent is not restricted to values between −1 and 1.

At 60 degrees, the expected ratio is approximately 1.732050808. A large slope can be valid; it should not be rejected solely because its magnitude exceeds one.

Example 2: recover a vertical change

For a specified horizontal run of 15 units and a 30-degree angle from the horizontal:

=15*TAN(30*PI()/180)

Expected rise: approximately 8.660254038 units. The run is the adjacent horizontal distance, not the sloping length. Using the sloping length in the same formula would represent a different geometry.

For the same angle and runs 5, 10, 15, expected rises are approximately 2.886751346, 5.773502692, 8.660254038. The angle stays fixed while the rise scales in proportion to the run. This is a constructed geometry example, not a measurement or engineering safety assessment.

Advanced example: turn a percentage slope into an angle

A stated slope of 25 percent means rise/run is 0.25, not 25 degrees. The inverse calculation is:

=ATAN(0.25)*180/PI()

Expected angle: approximately 14.036243468 degrees. Passing the corresponding radian angle through TAN reconstructs approximately 0.25. ATAN explains the principal inverse range.

A percentage cell should store 0.25 if its display is 25%. Check the stored value before using it in either direction; a display format does not decide which physical quantity a column represents.

Periodicity and a vertical boundary

=TAN(45*PI()/180)
=TAN(225*PI()/180)

Both results are approximately 1. Tangent repeats every 180 degrees, so a ratio alone cannot identify every full-circle direction. ATAN2 uses signed coordinates when quadrant information matters.

Mathematically, tangent is undefined at 90 degrees plus any integer multiple of 180 degrees. A formula using an approximate pi may produce a very large finite number near those angles; this guide does not claim a specific native error code or treat that large number as a valid exact vertical slope.

To see the sensitivity without evaluating the singular point, 89 degrees gives approximately 57.289961631 and 91 degrees approximately −57.289961631. The sign reverses across the vertical boundary. A small angle change near it can have a large effect on the ratio.

Troubleshooting

Check angle units first, then whether the angle is near a mathematical singularity. Do not conceal a problematic geometry by capping a large output without an explicit model rule. Use a consistent definition of run and rise, and retain original measurements when reviewing a result. Extreme-input precision and every coercion case remain untested in the native application.

References and verification

Numerical outputs are independent mathematical expectations, rounded where stated. Product-specific syntax and scope come from the cited reference. Native error/coercion matrices and extreme-value precision remain untested.