What is ln in excel

Last updated: April 1, 2026

Quick Answer: The LN function in Excel calculates the natural logarithm of a number using base e, with the syntax =LN(number). It's essential for financial modeling, statistical analysis, and scientific calculations within spreadsheets.

Key Facts

Understanding the LN Function in Excel

The LN function in Microsoft Excel is a built-in mathematical function that calculates the natural logarithm of a given number. The natural logarithm uses e (approximately 2.71828) as its base. This function is essential for professionals working in finance, statistics, science, and engineering who need to perform logarithmic calculations within spreadsheets. The syntax is straightforward: =LN(number), where number is the value for which you want to calculate the natural logarithm.

Syntax and Basic Usage

To use the LN function in Excel, you enter it into a cell with the syntax =LN(number). The number argument can be a numeric value, a cell reference, or a formula that returns a numeric value. For example, =LN(10) returns approximately 2.3026, =LN(A1) calculates the natural logarithm of the value in cell A1, and =LN(2+3) would calculate the natural logarithm of 5. The function accepts only positive numbers; zero and negative values will generate an error message.

Valid Inputs and Error Handling

The LN function in Excel has specific requirements for its input. The number argument must be greater than 0. If you attempt to use zero or negative numbers, Excel will return a #VALUE! error. Additionally, if the input is text or a non-numeric value, the function will also generate an error. Understanding these limitations helps prevent errors in complex spreadsheets. You can use the IFERROR function to handle potential errors gracefully, such as =IFERROR(LN(A1),"Invalid input").

Common Applications in Excel

The LN function has numerous practical applications in business and scientific spreadsheets:

Related Excel Functions

The LN function works in conjunction with other mathematical functions in Excel. The EXP function is the inverse of LN, calculating e^x. If you use =LN(EXP(5)), you get 5 back. The LOG function calculates logarithms with base 10, while LOG10 also calculates base-10 logarithms and LOG(number, base) allows you to specify any base. The POWER function can also be used for exponential calculations. Understanding these related functions expands your capability to perform complex mathematical calculations in Excel.

Related Questions

What is the EXP function in Excel?

The EXP function in Excel calculates e raised to a power (e^x) and is the inverse function of LN. Using =EXP(LN(x)) returns x, making them complementary mathematical operations.

How do you use LOG functions in Excel?

Excel offers LOG (base-10 logarithm), LOG10 (also base-10), and LOG(number, base) for calculating logarithms with any base. LN calculates the natural logarithm using base e.

How do you calculate growth rates in Excel?

Growth rates can be calculated using =(New Value - Old Value)/Old Value for simple growth, or =LN(New Value/Old Value) for logarithmic growth rates used in financial analysis.

Sources

  1. LN Function - Microsoft Office Support CC-BY-SA-4.0
  2. Natural Logarithm - Wikipedia CC-BY-SA-4.0