Trigonometry Calculator
Trig functions in degrees.
Formula
sin, cos, tan
Example
sin(30°)=0.5, cos(60°)=0.5.
Embed this calculator on your site
Add this free calculator to your own website with one line of code. The embedded version is responsive, ad-free, and includes a small attribution link back to CalcNest AI.
<iframe src="https://calcnestai.com/embed/trigonometry-calculator.html" width="100%" height="700" frameborder="0" style="border: 1px solid #e5e5e5; border-radius: 12px; max-width: 720px;" loading="lazy" title="Trigonometry Calculator — Free Tool by CalcNest AI"></iframe>
Understanding the Trigonometry Calculator
A trigonometry calculator returns sine, cosine, and tangent for an angle in degrees, along with the radian equivalent. The functions began as ratios in right triangles and became something considerably more general: descriptions of circular motion and the building blocks of every periodic phenomenon.
How it actually works
Enter an angle in degrees. The calculator converts to radians, evaluates the three functions, and flags tangent as undefined where cosine approaches zero. Thirty degrees gives a sine of exactly 0.5, cosine 0.866, and tangent 0.577.
| Angle | sin | cos | tan |
|---|---|---|---|
| 0° | 0 | 1 | 0 |
| 30° | 1/2 | √3/2 | 1/√3 |
| 45° | √2/2 | √2/2 | 1 |
| 60° | √3/2 | 1/2 | √3 |
The deeper context most people miss
These come from two triangles: an equilateral triangle bisected gives the 30-60-90 ratios, and a square bisected gives 45-45-90. That derivation is why they are exact rather than approximations, and knowing the two source triangles makes the whole table reconstructible rather than memorised.
Why the unit circle generalises the triangle definitions
Defined through right triangles, sine and cosine only make sense for angles between 0 and 90 degrees, since a right triangle cannot contain a larger angle. The unit circle removes that limit: place a point on a circle of radius one at angle θ from the positive x-axis, and its coordinates are exactly cosine θ and sine θ. This definition works for any angle, including negative ones and angles beyond a full turn, and it makes several properties immediately visible. The functions are periodic with period 2π because going round the circle returns to the same point. Sine is odd and cosine even, visible from reflecting across the x-axis. The Pythagorean identity, sine squared plus cosine squared equals one, is just the equation of the unit circle. The signs in each quadrant follow from the coordinate signs rather than needing a mnemonic. Tangent is the ratio of the two coordinates, which explains why it is undefined where cosine is zero, at 90 and 270 degrees, since that is division by zero, and why it runs to infinity approaching those points rather than merely being large. The unit circle also connects to rotation directly, since rotating a point is a matter of adding to the angle, which is why rotation matrices are built from sines and cosines and why computer graphics rests on them.
A worked example: why sine of 30 is exactly one half
Take an equilateral triangle with sides of 2 and drop a perpendicular from one vertex. It bisects both the opposite side and the angle, producing two right triangles with hypotenuse 2, short side 1, and angle 30 degrees at the top. Sine of 30 is therefore the opposite over the hypotenuse, which is exactly one half, and the remaining side follows from Pythagoras as root 3, giving cosine of 30 as root 3 over 2. The 45-degree values come the same way from bisecting a square. This is worth doing once because it converts a memorised table into something derivable, and because it demonstrates that these are exact algebraic values rather than decimal approximations, which matters in symbolic work where carrying 0.5 and carrying root 3 over 2 behave very differently through subsequent algebra. The practical trigonometry that follows is mostly the law of sines and law of cosines for solving triangles, and the two inverse problems: finding an angle from a ratio, which the inverse functions handle with the caveat that they return only a principal value and the actual angle may lie in another quadrant, and the two-argument arctangent function which takes both coordinates and resolves the quadrant correctly. That function is what should be used whenever converting coordinates to an angle, and using single-argument arctangent instead is a recurring bug in graphics and navigation code.
Deciding how to apply trigonometry practically
Beyond triangles, the functions describe anything oscillating. Alternating current is sinusoidal, and the phase relationships between voltage and current in reactive circuits are trigonometric, which is why power factor exists. Sound is pressure oscillation, and any waveform decomposes into sinusoids by Fourier analysis, which is the mathematical basis of audio compression, equalisation, and spectral display. Light and radio propagate as waves with the same description. Mechanical vibration, pendulums, and springs follow simple harmonic motion, whose solution is sinusoidal. Tides, seasons, and circadian rhythms are approximately sinusoidal. In each case the same small set of functions describes the phenomenon because they are the solutions to the differential equation describing anything with a restoring force proportional to displacement. Practically, this means that phase, amplitude, and frequency are the parameters that matter, and that adding two sinusoids of the same frequency gives another sinusoid of that frequency with different amplitude and phase, which is the phasor result underpinning circuit analysis. For surveying, navigation, and construction, the applications are the classical ones: determining inaccessible distances and heights by measuring angles, setting out right angles and slopes, and computing rafter lengths and cuts, where the roof pitch angle determines every cut on the job.
Radians, and why they are not an arbitrary alternative
Degrees are a historical convention, with 360 chosen by the Babylonians probably for its divisibility and its rough correspondence to days in a year. Radians are defined by the geometry itself: one radian is the angle subtending an arc equal to the radius, so a full circle is 2π radians because the circumference is 2πr. That definition makes arc length simply radius times angle and sector area simply half r squared times angle, with no conversion constant. More importantly, the calculus only works cleanly in radians: the derivative of sine is cosine only when the angle is in radians, and in degrees an awkward factor of π over 180 appears in every derivative. The Taylor series for sine and cosine similarly require radians. The small angle approximation, that sine θ is approximately θ for small θ, holds in radians and is the basis of the pendulum solution and of countless engineering simplifications. So radians are not a preference but the natural unit in any analytical context, and degrees persist for human-facing measurement where the numbers are more convenient. Nearly every programming language's trigonometric functions take radians, and passing degrees to them is among the most common numerical bugs, producing results that are wrong without being obviously so.
Variations: reciprocal functions, inverses, and hyperbolic analogues
Secant, cosecant, and cotangent are the reciprocals of cosine, sine, and tangent, and they appear in integration tables and some engineering formulas while being largely redundant for computation. The inverse functions arcsine, arccosine, and arctangent return principal values within restricted ranges, since the originals are not one-to-one, and recovering the correct quadrant requires either the two-argument arctangent or explicit reasoning. Hyperbolic functions use the unit hyperbola in place of the unit circle and satisfy analogous identities with sign changes, appearing in catenary curves, special relativity, and the solutions to certain differential equations, and the catenary specifically is the shape a hanging chain takes and is why arches designed as inverted catenaries carry load in pure compression. Euler's formula links the circular and exponential functions through complex numbers, giving e to the iθ as cosine θ plus i sine θ, which unifies the two families and makes many trigonometric identities fall out of exponent rules. The gradian, dividing a right angle into 100 parts, exists and is rarely used outside some surveying contexts. Turns and revolutions are used in rotational contexts.
Using trigonometric functions correctly
Check whether your function expects radians or degrees, since nearly every programming language uses radians and passing degrees produces wrong answers that look plausible. Use radians for anything analytical, since derivatives, Taylor series, and the small angle approximation all require them and degrees introduce a conversion factor throughout. Reconstruct the exact values from the bisected equilateral triangle and bisected square rather than memorising the table, which makes them derivable and shows they are exact algebraic values. Use the two-argument arctangent when converting coordinates to an angle, since single-argument arctangent loses the quadrant and is a recurring source of bugs. Remember that tangent is undefined at 90 and 270 degrees because cosine is zero there, and guard against it rather than relying on a large value. Use the law of cosines in preference to the law of sines where either applies, since the sine case with two sides and a non-included angle is ambiguous. And note that sine squared plus cosine squared equals one is simply the unit circle equation, which makes it memorable rather than another identity to learn.
What people get wrong
- Passing degrees to a function expecting radians, which is the most common trigonometric bug in code and produces plausible-looking wrong answers.
- Using single-argument arctangent to convert coordinates to an angle, which loses the quadrant, where the two-argument version resolves it correctly.
- Treating tangent at 90 degrees as a very large number, when cosine is exactly zero there and the function is genuinely undefined rather than merely large.
- Using degrees in analytical work, where the derivative of sine is cosine only in radians and degrees introduce a factor of π over 180 throughout.
Where the math comes from
For an angle θ, sine and cosine are the y and x coordinates of the corresponding point on the unit circle, and tangent is their ratio, which is why tangent is undefined where cosine is zero. Degrees convert to radians by multiplying by π/180. The identity sin²θ + cos²θ = 1 is the equation of the unit circle.
Questions and answers
What is the difference between percent and percentage point?
Percent change is relative (going from 5% to 10% is a 100% increase). Percentage point change is absolute (the same shift is a 5 percentage point increase). News stories often confuse these.
How do I calculate a discount?
Discount amount = original x discount %. Final price = original x (1 - discount %). For 20% off $100: discount $20, final $80.
What is the formula for compound percentage?
Final = original x (1 + r1) x (1 + r2) x ... where each r is a percentage as decimal. A 10% raise then 10% cut: 1.10 x 0.90 = 0.99 = 99% of original.
How do I reverse a percentage?
If $80 is 80% of original: original = $80 / 0.80 = $100. To reverse 'X% off' to find original: original = final / (1 - X/100).
How do percentages work in tax?
Marginal tax rate applies to income within a bracket. Effective rate is total tax / total income. They diverge because of progressive brackets.
Why is sin 30° exactly one half?
Because bisecting an equilateral triangle of side 2 produces a right triangle with hypotenuse 2 and the side opposite the 30 degree angle equal to 1. The exact values for 30, 45, and 60 degrees all come from bisecting an equilateral triangle or a square.
Why is tan 90° undefined?
Because tangent is sine divided by cosine, and cosine is exactly zero at 90 degrees. It's division by zero rather than a very large number, which is why the function runs to infinity approaching that angle from either side with opposite signs.
What's the point of radians?
They're defined by the geometry rather than by convention, so arc length is simply radius times angle. More importantly, calculus only works cleanly in radians: the derivative of sine is cosine only in radians, and degrees introduce a constant factor throughout.
Why does my code give the wrong trigonometric answer?
Most often because you passed degrees to a function expecting radians. Nearly every programming language's trigonometric functions take radians, and the resulting values look plausible rather than obviously wrong, which is why the bug survives.
How do I convert coordinates to an angle?
Use the two-argument arctangent, which takes both x and y and resolves the quadrant correctly. Single-argument arctangent takes only the ratio and cannot distinguish opposite quadrants, which is a recurring bug in graphics and navigation code.
Why do sine waves describe so many things?
Because they solve the differential equation for any system with a restoring force proportional to displacement, which covers pendulums, springs, circuits, sound, and light. Fourier analysis then shows any periodic signal decomposes into sinusoids.
What is the small angle approximation?
That sine θ is approximately θ for small angles measured in radians, with cosine approximately 1. It underpins the pendulum solution and countless engineering simplifications, and it holds only in radians, which is another reason radians are the analytical unit.
Related calculators
Volume · Polar to Cartesian · Inverse Function · Roman Numeral Converter · Area