Logarithm Calculator
Evaluate logarithms for any base (10, e, 2, fractional, or custom), solve for an unknown argument x or base b, inspect exact rational exponents, and visualize logarithmic curves dynamically.
Logarithm Inputs
b > 0, b != 1Logarithm & Reference Curve Plot
Plots y = log_b(x) alongside natural log ln(x) and highlights your evaluated coordinate
Step-by-Step Algebraic Derivation
Universal Logarithm Definition and Base Conversion
A logarithm log_b(x) returns the exponent y such that base b raised to y equals x (b^y = x). For any valid positive base b != 1 and positive argument x, the Change-of-Base formula log_b(x) = ln(x) / ln(b) converts every arbitrary base into standard natural or common logarithms.
Logarithmic and Exponential Equivalence
Understanding logarithms starts with one bidirectional translation rule linking exponential growth to logarithmic scaling. For any real base () and positive argument :
From this single equivalence follow the two cancellation identities: and . Whenever you need to isolate an exponent trapped inside an algebraic equation, taking on both sides brings the variable down into a linear coefficient—explore multi-step symbolic cases inside our exponential equation solver and logarithmic equation solver.
Change-of-Base Theorem and Exact Rational Powers
Starting from and applying to both sides gives by the power rule, yielding the universal change-of-base formula:
A neat corollary is the reciprocal base-swap identity . Moreover, whenever and share a common root , the logarithm simplifies cleanly to the exact fraction , which our calculator displays automatically alongside the decimal expansion.
Comparing Common (Base 10), Natural (Base e), and Binary (Base 2) Logs
| Logarithm Name | Notation & Base | Derivative | Primary Domains |
|---|---|---|---|
| Common Logarithm | log₁₀(x), b = 10 | 1 / (x ln 10) | pH chemistry, dB acoustics, scientific scales |
| Natural Logarithm | ln(x), b = e ≈ 2.71828 | 1 / x | Calculus, continuous growth, statistical regression |
| Binary Logarithm | log₂(x), b = 2 | 1 / (x ln 2) | Information bits, tree depth, O(n log n) sorting |
Fundamental Algebraic Identities and Solving Equations
Product & Quotient Rules
and for all positive .
Power & Root Rule
and .
Base Scaling Identity
Raising the base to power divides the logarithm by : .
Monotonicity & One-to-One Rule
Because is strictly monotonic on , .
Step-by-Step Worked Examples for Any Base
Example 1: Binary Logarithm log₂(32)
Express . Therefore . By change of base, . In computer science and information theory, a binary logarithm of 5 directly tells us that 32 distinct states require 5 bits to encode uniquely, and binary search over 32 sorted items completes in at most 5 comparisons.
Example 2: Solving for an Unknown Base b
Solve . Rewriting exponentially gives , so raising both sides to the reciprocal exponent gives . Checking in reverse confirms exactly.
Example 3: Fractional Base Decay & Non-Integer Arguments
Evaluate . Because , the value equals . Notice that whenever the base satisfies and the argument satisfies , the logarithm produces a positive result; conversely, when with a fractional base such as , the logarithm is negative (), reflecting inverse decreasing monotonicity.
Example 4: Computing Doubling Time with Natural & Arbitrary Logs
Suppose an investment or bacterial culture grows by 15% each period (). Solving for time means computing periods. Arbitrary-base logarithms turn compound growth questions across finance, epidemiology, and physics directly into single-step arithmetic ratios.
Common Mistakes and Domain Restrictions
- Forgetting extraneous solutions: Combining can introduce algebraic roots where ; always substitute final answers back into every original logarithmic term before accepting them.
- Misreading fractional arguments: When and , the logarithm is strictly negative (for example, ), approaching negative infinity as approaches zero.
- Conflating log(x)/log(y) with log(x/y): A quotient of two separate logarithms is a change of base (), never the logarithm of a quotient ().
- Assuming base-1 logarithms exist: Entering produces division by , because raising 1 to any finite power can only ever produce 1 and cannot span positive real numbers.
Computational Engine and Interactive Graphing
This solver evaluates arbitrary bases via natural-log ratios with rational denominator search up to to detect exact fractional exponents alongside 8-digit decimals, computes characteristic/mantissa splits, and plots over a responsive high-DPI canvas compared against .
Lead Developer & Founder of Basic Math Tools. Specializes in browser-native computational algorithms and applied mathematics.
Mathematics & curriculum specialists. Audited against standard algebraic and arithmetic principles.