ID EN
#Engineering

IMSQRT

Excel Functions

Get square root of a complex number

Syntax

EXCEL
=IMSQRT(inumber)

Arguments

Parameter Description
inumber A string representing a complex number.

Return Value

The square root of the complex number.

Details

The Excel IMSQRT function returns the square root of a complex number. For example: The IMSQRT function returns the complex number's principal square root (the one with a non-negative real part). For example: The two possible square roots of "2i" are "1+i" and "-1-i", so "1+i" is returned because it has a non-negative real part. A fundamental property of complex numbers is that the square root of "-1" is "i". However, when you take the square root of "-1", the result contains a tiny error due to how Excel handles floating-point arithmetic. The real part of the return value is a very small number close to zero. For practical purposes, it can be interpreted as just "i".

Examples

Example 1

The Excel IMSQRT function returns the square root of a complex number. For example:

EXCEL
=IMSQRT("3+4i") // returns "2+i"
Basic Example

The IMSQRT function returns the complex number's principal square root (the one with a non-negative real part). For example:

EXCEL
=IMSQRT("2i") // returns "1+i"
Square Root of Negative One Example

A fundamental property of complex numbers is that the square root of "-1" is "i". However, when you take the square root of "-1", the result contains

EXCEL
=IMSQRT("-1") // returns "6.12323399573677E-17+i"
Explanation

In Excel, we can write the formula equivalent to the complex square root function like this, where B6 contains a string representing a complex number:

EXCEL
=LET(
r, IMABS(B6),
t, IMARGUMENT(B6),
COMPLEX(SQRT(r)*COS(t/2),SQRT(r)*SIN(t/2))
)

See Also

IMPOWER IMABS IMARGUMENT COMPLEX