Identities
x^a · x^b = x^(a+b)
(x^a)^b = x^(a·b)
x^(1/n) = ⁿ√x
log_b(x) = ln(x) / ln(b)
The change-of-base identity is what lets the calculator handle any positive base — internally we just use the natural log.
Worked examples
- Power: 2¹⁰ = 1024
- Root: ¹⁰√1024 = 2
- Log: log₁₀(100) = 2, log₂(8) = 3, ln(e) = 1
- Fractional power: 8^(2/3) = ∛(8²) = ∛64 = 4
FAQ
Why does (−8)^(1/3) sometimes give NaN?
JavaScript's Math.pow returns NaN for negative bases with non-integer exponents. The calculator detects the cube-root case (odd integer denominator) and applies the sign manually: −8 → −2.
What's the difference between log and ln?
"log" usually means base-10 outside of pure math, where it often means base-e. "ln" is unambiguous: natural log, base e ≈ 2.71828. The calculator labels both modes explicitly.