Trigonometry calculator
Evaluate all six trigonometric functions for an angle and solve a right triangle from any sufficient pair of known measurements.
Inputs
Live results
A right triangle with legs 7 cm and 12 cm has hypotenuse 13.892444 cm.
0.70710678
0.70710678
1
1.41421356
1.41421356
1
13.892444 cm
30.256437°
59.743563°
42 cm²
Trigonometric function table
| Function | Definition | Value |
|---|---|---|
| Sine | sin θ | 0.70710678 |
| Cosine | cos θ | 0.70710678 |
| Tangent | tan θ | 1 |
| Cosecant | 1 ÷ sin θ | 1.41421356 |
| Secant | 1 ÷ cos θ | 1.41421356 |
| Cotangent | 1 ÷ tan θ | 1 |
Solved right-triangle measurements
| Measurement | Role | Value |
|---|---|---|
| Side a | Leg opposite α | 7 cm |
| Side b | Leg adjacent to α | 12 cm |
| Side c | Hypotenuse | 13.892444 cm |
| Angle α | Acute angle opposite a | 30.256437° |
| Angle β | Complement of α | 59.743563° |
| Area | a × b ÷ 2 | 42 cm² |
How to use this trigonometry calculator
What this calculator does
This calculator combines two closely related tasks. First, it evaluates the six standard trigonometric functions for one real angle: Sine, Cosine, Tangent, Cosecant, Secant, and Cotangent. Second, it solves a right triangle by finding its missing sides, acute angles, and area from a sufficient set of known measurements. It is useful for checking homework, estimating a rise or run, converting an angle into ratios, and verifying dimensions in geometry, construction, surveying, or engineering sketches. It does not solve oblique triangles, prove identities, or account for measurement uncertainty.
When to use it
Use the function section when you need a numerical value such as sin(45°), when you are converting between degrees and radians, or when you want all reciprocal functions at once. Use the triangle section when you know two sides, one side and one acute angle, area and one side, or area and one acute angle. The underlying right-triangle definitions are explained in the OpenStax right-triangle trigonometry chapter.
How to calculate
- The calculator opens with a complete demonstration: Angle is 45 Degrees, Side a is 7 cm, and Side b is 12 cm. Results and a validated example XLSX workbook are available immediately.
- Replace Angle with any finite real number. Use Angle unit to choose Degrees or Radians; changing the unit converts the current value rather than merely relabeling it.
- For the right triangle, enter any sufficient pair. Leave unknown fields empty. Choose Length unit before or after entry; changing it converts Side a, Side b, Side c, and Area consistently.
- Read the primary result, result cards, and both tables. Additional triangle values are treated as consistency checks, so contradictory entries produce a visible error instead of a silently altered answer.
- Select Download Excel to export current typed inputs and canonical calculated values. Reset clears the demonstration and all calculated content; Download Excel then remains disabled until a complete valid state is entered again.
Input guide
Angle is required and accepts dot-decimal numbers, with correctly grouped commas allowed; for example, 45 or 1,080.5. Scientific notation and decimal commas are rejected to avoid ambiguous interpretation. Angle unit is required and selects Degrees or Radians. A larger angle does not make every function larger because trigonometric functions are periodic.
Side a, Side b, and Side c are optional positive lengths. Side c is the hypotenuse and must be longer than either leg. Angle α and Angle β are optional acute angles entered in degrees, strictly between 0 and 90; they must sum to 90 when both are present. Area is an optional positive square-unit value. Length unit is required and may be unitless, millimetres, centimetres, metres, inches, or feet. Do not mix physical units across fields; use the selector to convert them together. A common mistake is entering two angles without any side or area: that determines shape but not scale, so the triangle cannot be solved.
Output guide
Sine and Cosine are bounded dimensionless ratios from – 1 to 1. Tangent is sine divided by cosine and can be negative, zero, or undefined. Cosecant, Secant, and Cotangent are reciprocals and become undefined when the corresponding denominator is zero. The angle, sin, hypotenuse, and area pills repeat the most useful live values.
Hypotenuse c, Angle α, Angle β, and Triangle area summarize the solved geometry. In the triangle table, Side a is opposite α, Side b is adjacent to α, Side c is the hypotenuse, and Area is one-half of the leg product. These are exact mathematical identities applied to decimal inputs; displayed values are rounded, while the workbook keeps the full finite model precision.
Worked example
At 45°, the calculator converts the angle to π/4 radians. It then computes sin(π/4) = 0.70710678, cos(π/4) = 0.70710678, and tan(π/4) = 1 at the displayed precision. For the demonstration triangle, a = 7 cm and b = 12 cm. The Pythagorean theorem gives c = √(7² + 12²) = √193 = 13.89244399 cm. The area is 7 × 12 ÷ 2 = 42 cm². Finally, α = arctan(7 ÷ 12) = 30.256437° and β = 90° – α = 59.743563°. Those values match the first-open cards, tables, and Excel checkpoints.
How the formulas work
For an angle θ in standard position, sine and cosine can be defined using the unit circle, while tangent is their quotient. The NIST Digital Library of Mathematical Functions definitions and periodicity section gives the formal function definitions. Reciprocal functions use csc θ = 1/sin θ, sec θ = 1/cos θ, and cot θ = 1/tan θ. Undefined values are mathematical singularities, not software errors.
When two legs are known, the calculator uses the Pythagorean theorem and an inverse tangent. When a leg and hypotenuse are known, it uses a square-root difference and inverse sine or cosine. With one acute angle and one side, it rearranges the sine, cosine, or tangent ratio. With area and a leg, the other leg is 2 × area ÷ known leg. The OpenStax inverse trigonometric functions section explains why inverse functions recover an acute angle from a ratio.
Interpreting precision and edge cases
Inputs are treated as exact decimal values for calculation purposes, but real measurements usually have uncertainty. Avoid reporting more physical precision than the least precise measurement supports. Very large angles are reduced naturally by the JavaScript trigonometric functions, but the calculator limits input magnitude to protect meaningful floating-point precision. Near 90° plus an integer multiple of 180°, tangent and secant are undefined because cosine is zero. Near integer multiples of 180°, cosecant and cotangent are undefined because sine is zero. Special-angle values and limiting behavior can be checked against the NIST table of trigonometric special values.