IMLN Function

Returns the natural logarithm of a complex number.

Category

Engineering

Available in

All versions, Microsoft 365

Returns

Complex number text

Want to practice IMLN in a real spreadsheet? Open a blank sheet in our Practice Sandbox and try it with live data, with the AI Excel tutor beside you. No Excel needed — just a free account.Try it free in the Sandbox

Overview

IMLN returns ln|z| + i·θ, where θ is the angle from IMARGUMENT. It works for negative numbers too: ln(−1) is πi.

The result is text, shown to 15 significant digits. Wrap it in IMREAL or IMAGINARY to get a number you can format or round.

Syntax

=IMLN(inumber) Explain

Arguments

ArgumentRequired?What it does
inumberYesA complex number as text, like "3+4i" — or a plain number.

Examples

Example 1 — Worked examples

Each row applies the function to the value in column A.

B2fx=IMLN(A2)
AB
1Complexln(z)
23+4i1.6094379124341+0.927295218001612i
310
4-13.14159265358979i
5i1.5707963267949i
=IMLN(A2) Explain

Common mistakes

  • #NUM! The text isn't a valid complex number — for example a space ("3 + 4i"), a capital I, or a letter other than i or j.
  • #NUM! for zero. The logarithm of 0 is undefined.

Notes

  • Related functions: IMEXP, IMLOG10, IMLOG2, LN.
Kyle Stott

Author

Kyle Stott

Certified Microsoft Excel Expert

Kyle has worked professionally with Microsoft Excel for over a decade and has consulted on and taught Excel best practices to over 400 companies across 30+ countries.