• About
  • Contact
  • Privacy Policy
  • Submit For Review
  • Template Gallery
  • Excel 2016 Udemy Course
  • Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

TheAppTimes

App Reviews, Tutorials, & Gadget News Hub

  • Gadgets
  • How To
  • Mobile Apps
  • Software and Web Apps
  • Buying Guides
  • Shop
  • Show Search
Hide Search
Home » How To » How to Write Complex Excel Formulas

How to Write Complex Excel Formulas

April 18, 2016

In a previous article, we learned how to create and input simple formulas in Excel. If you are already familiar with that, let’s move on to working with complex Excel formulas. By complex formulas, I mean one that has more than one mathematical operator, such as 2+3*56. The thing that you need to watch out for with complex formulas is the order of operations, which is the way in which Excel does its computations. If you construct the formula in the wrong order, you will get an incorrect result. Let’s see a few examples to understand how to use complex Excel formulas to do mathematical computations.

Importance of Order of Operators

Let’s take a simple example and find the result for the following in Excel:

=10 + 5 * 20 + 25 / 5              – The result in this case is 112
=(10 + 5) * 20 + 25 / 5          – The result in this case is 305
=10 + 5 *( 20 + 25) / 5          – The result in this case is 55
=(10 + 5 * 20 + 25) / 5 26.4   – The result in this case is 27

All these are formulas are valid but the placement of parentheses results in a different outcome in each case. Therefore it is essential that you take into account the order of operators when writing formulas.

Order of Operators for Complex Excel Formulas

order of operators

Excel calculates formulas based on the following order of operations:

  1. Parentheses
  2. Exponents (5^2, for example)
  3. Multiplication and division (whichever comes first in the formula)
  4. Addition and subtraction (whichever comes first in the formula)

A easier way to remember them is using their first characters PEMDAS.

Let’s learn how to do the math using the order of operators.

Example 1

To find the resultant of : 20+(6-4)/2^3*4-2

Step 1: Compute P or Parentheses, which leads to: 20+(6-4)/2^3*4-2 or 20+(2)/2^*4-2

PEMDAS1

 

Step 2: Compute E or Exponents, which leads to: 20+2/2^3*4-2 or 20+2/8*4-2

PEMDAS2

 

Step 3: Compute M or D whichever comes first. In this case the division comes before multiplication, so we’ll do the Division computation first.

20+2/8*4-2 or 20+.25*4-2

PEMDAS3

 

Step 4: Compute M for Multiplication. 20+.25*4-2 or 20+1-2

ALSO READ:  Extract URLs From Hyperlinked Text Using Macros in Excel 2010

PEMDAS4

 

Step 5: Compute A or S whichever comes first. In this case the addition comes before subtraction, so we’ll do the Addition computation first.

20+1-2 or 21-2

PEMDAS5

 

Step 6: Finally, lets do the subtraction to get the final result, which is 21-2 = 19

PEMDAS6

 

Creating Complex Formulas

If you input the formula =20+(6-4)/2^3*4-2 in the Formula Bar in Excel, you will instantly get the resultant as 19. Let’s look at another example. Let us calculate the sales tax on an invoice. The formula for this will be: =(D2+D3)*0.075

In cell D4, I will input this formula to compute my tax value, which equals 29.14875. What Excel has done in this case is added the values within the Parentheses ($139.90+$248.75)=388.65, then multiplied it by the tax rate which is 7.5% or (o.075), which is 388.65*0.075 = 29.14875

Instead of manually writing this value, you can of course use cell references to do all the computations. First, we’ll compute the total sales value of the pipes and screws, then we’ll compute the tax value.

1. Select the cell where you want to input the formula. In this case it is cell D2.

2. Enter the formula. Type =

3. Click cell B2

4. Enter the multiplication symbol *

5. Click cell C2.

Sales value of pipes

6. Press Enter to find the total sales value of the pipes.

7. Now compute the value of the screws. Click inside cell D2 and drag the fill handle down to cell D3.

Use the fill handle to extend the formula

8. Now place the cursor in cell D4 to compute the tax value.

9. Type =

10. Click cell D2, enter the + sign and then click cell D3.

computing tax

11. Next add a parenthesis around the current formula.

adding parenthesis

12. Next, add the multiplication symbol after the parenthesis and input the tax value, which is 0.075.

Creating complex excel formulas

13. Press Enter.

You now have your tax computed and displayed in cell D4 as 29.14875

In the next post, we’ll learn more about Relative and Absolute Cell References.

Tweet44
Share5
WhatsApp
Pin2K
Buffer
2K Shares
Tweet44
Share5
WhatsApp
Pin2K
Buffer
2K Shares

Filed Under: How To Tagged With: excel how to, learn excel

You May Also Like

How to Get Rid of the Paste Options Menu in Word, Excel and PPT
How to Get Rid of the Paste Options Menu in Word, Excel and PPT
How to Calculate Number of Days Between Two Dates in Excel
How to Calculate Number of Days Between Two Dates in Excel
How to Combine Text with a Date or Time in Excel
How to Combine Text with a Date or Time in Excel

About Adeline Gear

Adeline is a tech enthusiast who loves exploring the latest tools and applications in the marketplace. She also loves her Android and spends time reviewing apps and playing games when she has the time.

Reader Interactions

Comments

  1. Joyce says

    April 20, 2016 at 7:50 pm

    Loved the breakdown on doing formulas. Thanks!

    Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Primary Sidebar

Hottest New Gadgets!

Fast External SSD Gadgets for your Mac - TATFI

4 Fast External SSD Gadgets for your Mac (2021)

Anker Powerhouse 100 - TATFI

Charge Your iPhone, Galaxy, iPad, or MacBook with the Portable Power Bank Anker Powerhouse 100

Logitech Circle View - TATFI

Logitech Circle View – A Great Wired Outdoor Camera for HomeKit Users

Spigen Galaxy S21 Cases - TATFI

Spigen Galaxy S21 Cases is Perfect for New Samsung Smartphone

Samsung Galaxy SmartTag Bluetooth Tracker - TATFI

Find Lost Items with the Samsung Galaxy SmartTag Bluetooth Tracker

Popular Tags

android android apps android games android how to apple chrome extensions excel excel how to facebook gadgets gaming gmail google instagram ios apps ios games ios how to ios tips ipad iphone kids apps learn excel management microsoft music apps new releases outlook how to photo apps powerpoint powerpoint how to productivity Samsung security smartphone smartphones software tablet tablets technology twitter web browsers windows 10 word how to xbox youtube

Disclosure

TheAppTimes is a participant in the Amazon Services LLC Associates Program, an affiliate advertising program designed to provide a means for us to earn fees by linking to Amazon.com and affiliated sites.

TheAppTimes © 2021 // Runs on StudioPress