Math glossary

Log vs. Ln: What Is the Difference and How Do You Convert?

Compare base-10 log with natural logarithm, check calculator conventions, convert both ways, and follow six examples.

TL;DR

In common calculator notation, log uses base 10 and ln uses base ee. Both return exponents. An unmarked log can use a different base by convention, so check the source or software.

Key Points

  • log10x\log_{10}x answers “10 to what power gives xx?”
  • lnx=logex\ln x=\log_e x answers the same question with base e≈2.71828e\approx2.71828.
  • Real logarithms need positive inputs.
  • Convert using lnx=(ln10)log10x\ln x=(\ln 10)\log_{10}x.
  • Match the base to the original expression, axis label, or software function.

What is the difference between log and ln?

The common logarithm uses base 10. It is written log10x\log_{10}x or, in many classrooms and on many scientific calculators, logx\log x. The natural logarithm uses base ee and is written lnx\ln x.

log10x=y⟺10y=x,lnx=y⟺ey=x.\log_{10}x=y \iff 10^y=x, \qquad \ln x=y \iff e^y=x.

The base changes the exponent required to reach the same positive input. For example, log10100=2\log_{10}100=2 because 102=10010^2=100. The natural logarithm of 100 is about 4.605 because e4.605e^{4.605} is about 100. OpenStax, Logarithmic Functions

Input or feature Common logarithm Natural logarithm
Base 10 ee
Result at x=1x=1 0 0
Input that gives 1 10 ee
Output at 100 2 About 4.605
Inverse function 10x10^x exe^x
The common logarithm reaches output one at ten and the natural logarithm reaches one at Euler's number
Both graphs pass through (1,0)(1,0). Each reaches output 1 when its input equals its base.

Does log always mean base 10?

Calculator keys labelled log and ln typically distinguish base 10 and base ee. In mathematics and computer software, an author or library can define an unmarked log differently. Python’s math.log(x) uses the natural logarithm by default, while math.log10(x) explicitly uses base 10. In algorithms, some texts use log for base 2 or ignore the base when discussing growth up to constant factors.

Use the base written as a subscript when it appears. When reading code, check the documentation for that function. The introduction to logarithms explains how each base produces a different logarithmic scale. Python, Mathematical Functions

How do you convert between log and ln?

For any real x>0x>0, the change-of-base rule gives

log10x=lnxln10,lnx=(ln10)log10x.\log_{10}x=\frac{\ln x}{\ln 10}, \qquad \ln x=(\ln 10)\log_{10}x.

To see why, set y=log10xy=\log_{10}x. Then 10y=x10^y=x. Taking the natural log gives yln10=lnxy\ln 10=\ln x, so divide by ln10\ln 10 to recover yy. This operation is valid because ln10\ln 10 is positive.

Numerically, ln10≈2.302585\ln 10\approx2.302585. Multiplying a common logarithm by this factor gives its natural logarithm. Dividing goes in the opposite direction. Keep the exact constant until the final rounding step. Apply the same base-change reasoning to other bases using the log rules. OpenStax, Logarithmic Properties

When is one logarithm easier to use?

Base 10 makes decimal powers and order of magnitude easy to read. An increase of one unit in log10x\log_{10}x means the original quantity is ten times larger. A common logarithm table uses this pattern when separating digits from place value.

Base ee is convenient when a model already contains ekte^{kt} or when calculus uses the derivative of lnx\ln x, which is 1/x1/x for x>0x>0. Multiplying xx by ee raises its natural logarithm by one. You can solve an exponential equation with either base if you use the same base throughout. OpenStax, Calculus Volume 1: Exponential and Logarithmic Functions

Worked Examples Comparing Log and Ln

Example 1

Find log10(0.001)\log_{10}(0.001) and ln(0.001)\ln(0.001).

  1. Since 0.001=10−30.001=10^{-3}, the common logarithm is −3-3.
  2. The natural logarithm is −3ln10-3\ln 10.
  3. To three decimal places, this is −6.908-6.908.

Example 2

Evaluate ln(e2.5)\ln(e^{2.5}). What would log10(e2.5)\log_{10}(e^{2.5}) be?

  1. The natural log and a power of ee undo each other, giving 2.5.
  2. The common log divides this exponent by ln10\ln 10.
  3. This gives 2.5/ln10≈1.0862.5/\ln 10\approx1.086.

Example 3

Solve e0.3t=7e^{0.3t}=7.

  1. Take the natural log of both sides to get 0.3t=ln70.3t=\ln7.
  2. Divide by 0.30.3.
  3. The result is t≈6.486t\approx6.486. Using common logs also works if the left side becomes 0.3tlog10e0.3t\log_{10}e.

Example 4

Solve 102x=4510^{2x}=45.

  1. Take the common log of both sides to get 2x=log10452x=\log_{10}45.
  2. Divide by 2.
  3. The result is x≈0.827x\approx0.827. Check by calculating 102x10^{2x} with the unrounded value of xx.

Example 5

A positive measurement rises from 25 to 2500. How much do its two logarithmic readings change?

  1. The ratio of the new value to the old is 2500/25=1002500/25=100.
  2. The difference in common logarithms is log10100=2\log_{10}100=2.
  3. The difference in natural logarithms is ln100=2ln10≈4.605\ln100=2\ln10\approx4.605.

Example 6

Which is greater, ln(0.2)\ln(0.2) or log10(0.2)\log_{10}(0.2)?

  1. Both are negative because the input is between 0 and 1 and both bases exceed 1.
  2. Since ln10>1\ln10>1, multiplying the negative common logarithm by ln10\ln10 makes it more negative.
  3. Therefore log10(0.2)\log_{10}(0.2) is greater. Its value is about −0.699-0.699 versus about −1.609-1.609 for the natural log.

Mistakes That Change the Result

Mistake 1: Using the wrong calculator key

For input 100, use the expected base. The outputs 2 and about 4.605 can both be correct for the same input, depending on which log you need.

Mistake 2: Switching bases halfway through an equation

If you take common logs on one side of an equality, apply the same operation to the other side. Rewriting between bases requires the conversion factor.

Mistake 3: Applying either real logarithm to zero or a negative number

In the real-number setting, both require positive inputs. A negative output is allowed, as Example 1 shows.

Try It Yourself

  1. Find log10(104)\log_{10}(10^4) and ln(e−4)\ln(e^{-4}).
  2. Express ln1000\ln1000 as a multiple of ln10\ln10.
  3. Solve 2t=52^t=5 using natural logarithms.

Answers and Reasoning

  1. The values are 4 and −4-4 respectively.
  2. ln1000=3ln10\ln1000=3\ln10 because 1000=1031000=10^3.
  3. t=ln5/ln2≈2.322t=\ln5/\ln2\approx2.322.

Frequently Asked Questions

When are ln and the common log equal?

For positive real inputs, only at x=1x=1. Both are zero there. At any other input, multiplying the common log by ln10\ln10 changes it.

Why does ln use ee?

The exponential exe^x has derivative exe^x. Its inverse lnx\ln x has derivative 1/x1/x. This makes base ee convenient for calculus and continuous growth models.

Can I type a natural logarithm using only a log key?

Yes, if the key uses base 10. Divide log10x\log_{10}x by log10e\log_{10}e, or multiply it by ln10\ln10 if that constant is available.

Conclusion

  • Read ln\ln as a base-ee logarithm.
  • Check what log\log means in the specific textbook, calculator, or program.
  • Use change of base when the required key or function is unavailable.

Read More

Research Behind This Article

  1. OpenStax, Algebra and Trigonometry 2e: Logarithmic Functions. OpenStax
  2. OpenStax, Algebra and Trigonometry 2e: Logarithmic Properties. OpenStax
  3. OpenStax, Calculus Volume 1: Exponential and Logarithmic Functions. OpenStax
  4. Python Software Foundation, math: Power, Exponential and Logarithmic Functions. Python Documentation