Logarithm Calculator
Calculate log₁₀, ln (natural log), log₂, or any custom base logarithm.
What is a Logarithm?
A logarithm is the inverse of exponentiation. If you know that 10³ = 1000, then log₁₀(1000) = 3 - the logarithm tells you what exponent (3) you need to raise the base (10) to in order to get the result (1000). In general: if b^y = x, then log_b(x) = y.
Logarithms were invented in the early 17th century by John Napier as a way to transform multiplication into addition - which was far easier to do by hand for large numbers. Before electronic calculators, log tables were essential tools for astronomers, engineers, and navigators. Today, logarithms remain central to mathematics, science, and engineering.
The common logarithm (log₁₀) is used in chemistry for the pH scale (pH = −log₁₀[H⁺]), in seismology for the Richter scale (each unit represents a 10× increase in wave amplitude), in acoustics for decibels (dB = 10 × log₁₀(power ratio)), and in astronomy for the stellar magnitude scale. Because we count in base 10, log₁₀ is natural for expressing ratios involving powers of 10.
The natural logarithm (ln, base e where e ≈ 2.71828) arises naturally in calculus and differential equations. The derivative of ln(x) is 1/x - a remarkably simple result. It appears in compound interest (continuous compounding), radioactive decay, population growth, and information entropy. The number e itself emerges from the limit of (1 + 1/n)^n as n approaches infinity.
Log base 2 is the workhorse of computer science and information theory. Claude Shannon’s entropy formula uses log₂ to measure information in bits. Binary trees have height proportional to log₂(n). The number of digits needed to represent n in binary is ⌊log₂(n)⌋ + 1.