CalcHub

Scientific Calculator

Most wrong answers from a scientific calculator come from the settings, not the arithmetic. If sin(30) gives −0.988031624093 instead of 0.5, the angle mode is set to RAD; if you pressed e to type 1.5e8, you multiplied by Euler's number (2.71828…) rather than entering exponent notation. This is an expression calculator: you type the whole expression, press =, and it is evaluated in one go with brackets and operator precedence respected. It supports trigonometric and inverse trigonometric functions, common and natural logarithms, powers, square roots, and the constants π and e. Below is a complete list of what it can do, along with the actual outputs at the points where results tend to look surprising.

Key points

  • It evaluates expressions with precedence, so 2+3×4 gives 14. Leaving out the multiplication sign, as in 2π or 2(3+4), still means multiply, and any brackets left open are closed automatically at the very end of the expression when you press =.
  • The angle mode starts in DEG (degrees). asin, acos, and atan also return results in the current mode's unit, and if you switch modes and press = again, the same expression is recalculated in the new mode.
  • Results are rounded to 12 significant digits. That makes 0.1+0.2 come out as 0.3, and the leftover error below 10⁻¹² that trig functions pick up from the approximation of π is cleaned to zero, so cos(90) shows 0. Undefined values such as tan(90) show 'Error'.
Enter an expression
0

Examples

What angle is a 1:12 ramp? — atan

A rise of 1 over a horizontal run of 12 is a slope often used in accessibility guidelines. To turn it into an angle, calculate atan(1÷12) in DEG mode: 4.76364169073, or about 4.8°. As a percentage the same slope is 1÷12×100 = 8.33333333333, about 8.3%. Going the other way, an 8° slope is tan(8)×100 = 14.0540834702, about 14.1% — a quick demonstration that an '8% slope' and an '8° slope' are very different things.

Estimating a building's height — tan and automatic bracket closing

You stand 20 m from a building, the angle up to the top is 32°, and your eyes are 1.6 m above the ground, so the height is 1.6 + 20 × tan(32°). In DEG mode, type only 1.6+20×tan(32 and press =: the closing bracket is added for you and the result is 14.0973870382, about 14.1 m. Typing 20tan(32 without the × works too. Bear in mind that automatic closing always happens at the very end, so sin(30+sin(60 is read as sin(30+sin(60)) and gives 0.513032356288. If more terms follow a function, close its bracket yourself.

A monitor's diagonal — √, ^, and continuing from a result

For a screen 59.8 cm wide and 33.6 cm high, Pythagoras gives the diagonal as √(59.8^2+33.6^2) = 68.5930025586 cm. Type ÷2.54 straight after that and press =, and the calculation continues from the previous result: 27.0051191176, confirming a 27-inch monitor. There is no separate x² key, so enter squares as ^2, and enter roots such as cube roots as fractional powers, for example 8^(1÷3) = 2; the cube root of a negative number works too, so (−8)^(1÷3) = −2.

How long until money doubles at 5% a year? — ln

Solving 1.05ⁿ = 2 for n gives n = ln(2)÷ln(1.05), which comes to 14.2066990829 years — very close to the familiar rule of 72 (72÷5 = 14.4 years). Going the other way, 1.05^10 = 1.62889462678 tells you that after 10 years the balance is about 1.63 times the original. Using log instead, log(2)÷log(1.05), gives the same 14.2066990829, because the ratio of two logarithms does not depend on their base.

sin(30) as 0.5 and as −0.988 — catching a mode mistake

In DEG mode sin(30) is 0.5, but in RAD mode the 30 is read as 30 radians (about 1,718.9°) and the result is −0.988031624093. To get the sine of 30° in RAD mode, enter sin(π÷6) or sin(30×π÷180); both return 0.5. The inverse functions behave the same way: asin(0.5) is 30 in DEG and 0.523598775598 (π/6) in RAD. If a result looks wrong, leave the expression alone, switch the mode, and press = again to compare the two answers.

Trig values for common angles, and what this calculator shows

AngleRadianssincostan
0°0010
30°π/61/2 → 0.5√3/2 → 0.866025403784√3/3 → 0.57735026919
45°π/4√2/2 → 0.707106781187√2/2 → 0.7071067811871
60°π/3√3/2 → 0.8660254037841/2 → 0.5√3 → 1.73205080757
90°π/210Undefined (shown: Error)
180°π0−10

Values after the arrow are what this calculator actually displays in DEG mode. Because floating-point arithmetic can only hold π to a finite number of digits, computing 90° and 180° directly leaves values around 10⁻¹⁶ where there should be zero; this calculator cleans such trig leftovers (below 10⁻¹²) to 0 and shows the undefined tan(90°) as 'Error'.

Supported keys and how to enter them

KeyWhat it doesExample → result
sin( cos( tan(Trigonometric functions (angle unit follows DEG/RAD)sin(30 → 0.5 (DEG)
asin( acos( atan(Inverse trig functions (result in the current mode's unit)acos(0.5 → 60 (DEG)
log(Common logarithm (base 10)log(1000 → 3
ln(Natural logarithm (base e)ln(e → 1
√(Square root√(2 → 1.41421356237
^Power (evaluated right to left)2^3^2 → 512
π, ePi and Euler's number2π → 6.28318530718
( )Brackets (closed automatically at the end if left open)2(3+4) → 14
%Divides the preceding number by 100200×10% → 20
⌫, CDelete last entry, clear allSame as Backspace and Escape

From the keyboard you can use digits, + - * / ^ ( ) . %, Enter (=), Backspace (⌫), and Escape (C); functions, π, and e are entered with the on-screen buttons only. There are no keys for x², 1/x, n!, combinations (nCr), hyperbolic functions, memory (M+), or exponent entry (EXP).

FAQ

Other calculators show cos(90) as 6.12e-17. Why does this one show 0?
I typed 1.5e8 to mean 1.5×10⁸ and got a strange answer
Why does −2^2 give −4 rather than 4?
How do I take a logarithm in a base other than 10 or e, such as base 2?
Can I carry on from a result, or edit the expression I just ran?

Angle modes and the usual trigonometry traps

A degree is 1/360 of a full turn, while a radian is the angle made by an arc as long as the radius, so a full turn is 2π radians. That gives radians = degrees × π ÷ 180, and one radian is 180÷π = 57.2957795131°. On this calculator, 30×π÷180 returns 0.523598775598, which is 30° expressed in radians.

Angles you could measure with a protractor — in surveying, construction, or technical drawings — are usually given in degrees, so use DEG mode. In calculus and physics, where angles appear mixed with time or length as in sin(ωt), or whenever a problem gives an angle with π in it, radians are the default and you should switch to RAD mode. If textbook answers keep failing to match, check the mode first.

Inverse trig functions have fixed output ranges. In DEG mode, asin and atan return values between −90° and 90°, and acos between 0° and 180°; giving asin or acos a value below −1 or above 1 shows 'Error'. atan also works only from the slope, so it cannot tell the point (1, 1) from (−1, −1): atan(−1÷−1) still returns 45, and when the real angle is 225° you need to look at the quadrant and add 180° yourself.

Values that should be zero coming out as tiny numbers around 10⁻¹⁶ are a feature of most software arithmetic. This calculator cleans them up for trig results only, which is why the 90° and 180° rows in the table above come out clean, but the same calculation in another program or in code may still show something like 6.12e-17. To check your input, try an identity whose exact answer you know. For example, sin(37)^2+cos(37)^2 returns 1, and checking against expressions like this is an easy way to catch typing mistakes.

Working with logarithms, powers, and exponent notation

log is the common logarithm (base 10) and ln the natural logarithm (base e). Because log(100) = 2 and log(1000) = 3, common logarithms map directly onto the number of digits and underpin scales such as decibels, pH, and earthquake magnitude; natural logarithms describe processes whose rate of change is proportional to their size, such as continuous compounding, population growth, and radioactive decay. The two are related by ln(x) = log(x) × 2.30258509299. Neither is defined for zero or negative numbers, so log(0) and ln(−1) show 'Error', and since complex numbers are not supported, √(−1) does too.

^ is evaluated from the right, so 2^3^2 is 2^(3^2) = 2^9 = 512; if you want (2^3)^2 = 64, add the brackets. A fractional exponent gives a root, so 2^0.5 = 1.41421356237, the same as √(2), and 3^(1÷2) = 1.73205080757. Fractional exponents must be bracketed, because 8^1÷3 is read as (8^1)÷3 = 2.66666666667.

Results are rounded to 12 significant digits and switch to exponent notation at 10²¹ and above or below 0.000001: 2^70 shows as 1.18059162072e+21, 2^−20 as 9.53674316406e-7, and 10^−7 as 1e-7. Large numbers between those limits are written out in full without separators, but from the 13th digit onward they are filled with zeros, so 2^60 appears as 1152921504610000000 instead of the exact 1152921504606846976. It is not the right tool when every last digit of a large integer matters.