# How to Use IMAGINARY Function in Excel (3 Examples)

Get FREE Advanced Excel Exercises with Solutions!

Imaginary numbers are often used for mathematical and scientific analysis. In this article, we will show you how you can use the Excel IMAGINARY Function. With the help of this function, you can find the coefficient of the imaginary portion. You will also get a complete idea about inserting complex numbers, extracting real coefficients, and some common and most-used complex number calculations. ## IMAGINARY Function Overview

• Summary

The IMAGINARY function extracts the imaginary coefficient from the corresponding complex number in Excel.

• Syntax

The syntax for the formula is:

`=IMAGINARY(inumber)` • Argument
Argument Required/Optional Value
inumber Required The complex number from which you want to get the imaginary coefficient
• Output

Returns the imaginary coefficient of a complex number.

• Available Versions

The IMAGINARY function is available in all versions of Excel.

## Insert Complex Numbers with Real and Imaginary Parts in Excel

Let’s say, we have a dataset of some real and imaginary coefficients from which we want to form complex numbers. Let’s check the procedure of inserting complex numbers first.

We can Insert Imaginary numbers in Excel using the COMPLEX function.

➤ Write the Following equation in the desired cell and

`=COMPLEX(1,2)`

Here,

• 1:- Real Coefficient
• 2:- Imaginary Coefficient

thus, we get the Imaginary form. ➤  Then press ENTER and the cell will show you the complex number by combining the real and imaginary portions with a suffix “i”. But there is a drawback to this method. Each time you want to insert a complex number, you need to input the real and the imaginary portion each and every time. However, you can apply this procedure when you have to get the complex number directly.

There is another way also available if you have a list of real and imaginary portions. You can use the cell reference. Here, we have lists of real and imaginary portions.

You just have to use the cell reference of the real and imaginary part.

➤ So, write the following Formula in the selected cell.

`=COMPLEX(B5,C5)`

Here,

• B5:- Real Coefficient
• C5:- Imaginary Coefficient ➤ Now, press ENTER to let the cell show the result.

➤ Next, use the Fill Handle tool to Autofill the formula for the cells situated down to that cell. ➤ Hence, you will get the complex numbers formed of your inserted real and imaginary part. This IMAGINARY function takes a Complex number and returns its Imaginary Coefficient. In this section, we will see how the imaginary function can be used in Excel. I will discuss 3 examples of using the IMAGINARY function with proper illustrations here.

## 1. Extracting the Imaginary Coefficient Directly with the Imaginary Function

We have taken some Imaginary Numbers in Column B.

And, we want to extract the Imaginary coefficient in Column C. ➤ Now, write the following formula in C5 and press ENTER.

`=IMAGINARY("1+2i")`

Here, “1+2i” is the Complex Number Note: When you wrap a text with an inverted comma assigned in the IMAGINARY function, it recognizes the text as a complex number.

➤ Then, press ENTER and the cell will return you the imaginary coefficient of the assigned complex number. ➤ Each time you assign an individual complex number as the argument of the IMAGINARY function, you will get the corresponding imaginary coefficient from it. Thus, we get all the imaginary coefficients for the corresponding imaginary numbers.

## 2. Using Cell Reference in IMAGINARY Function

If you don’t want to use the Inverted Comma in the IMAGINARY function, you can use the cell reference. There is an extra advantage of using cell references. You don’t need to apply the formula every time like Method 1 here.

➤ First, just select a cell and type the following formula in that cell.

`=IMAGINARY(B5)`

Here,

• B5:- Complex Number ➤ Now, press ENTER to show the result.

➤ Next, drag the formula down to copy it to the other cells. It will Autofill the formula for other cells. ➤ As a result, you will get the imaginary coefficient for all the complex numbers. ## 3. Utilizing COMPLEX Function Nested in IMAGINARY Function in Excel

We have a list of some real numbers and some imaginary numbers (with the suffix “i”). We have learned how to insert complex number with real and imaginary part in Excel. Now, we will see how we can use the IMAGINARY function nested with the COMPLEX function to get the imaginary coefficient from it.

➤ Here, type the following formula in cell D5.

`=IMAGINARY(COMPLEX(1,2))`

Here,

• 1:- Real Part
• 2:- Imaginary Part ➤ Then, press ENTER, The COMPLEX function will return the complex number and so, the IMAGINARY function will extract the imaginary coefficient from it. ➤ Apply individual formulas each time to get the acquainted result. ## Extracting Real Coefficient from Imaginary Number with IMREAL Function

We have seen the use of the IMAGINARY function to extract the imaginary coefficient. But for the real part, you have to use the IMREAL function.

This IMREAL function returns the real coefficient of an imaginary number.

We have taken the same imaginary numbers as previously used. ➤ Write the following formula in C5 and press ENTER.

`=IMREAL(B5)`

Here,

B5:- Complex Number So, we get the real coefficient for the first imaginary number.

➤ Now, Hold and Drag the C5 cell downward. And, we have all the real coefficients for all imaginary numbers. ## Practice Section

Here, we are providing you with a practice section where you can practice yourself. ## Things to Remember

• While applying the complex number directly into the IMAGINARY function, don’t forget to use the Inverted Comma. Otherwise, the function tries to correct the formula and returns 0 always.
• If the complex number is used as a cell reference, then there is no need to put an Inverted Comma.

## Conclusion

So, we learned how to use the IMAGINARY function in Excel. We hope you find the content of this article useful. If there are any queries or suggestions regarding any of these procedures, feel free to leave them in the comment section.

## Related Articles Sourav Kundu

Hi, I am Sourav Kundu. I live in Adabor, Dhaka. I graduated in Naval Architecture and Marine Engineering from BUET. I am really excited to be a part of SOFTEKO family. I want to develop my research skill and find innovative solutions for the given problems.

We will be happy to hear your thoughts Advanced Excel Exercises with Solutions PDF  