Excel - Order of Precedence

Can anyone please explain or help? I enter following formula in Excel:

=B5*B6+C3/D4^2

According to the order of precedence, it's supposed to calculate or evaluate the exponent D4^2 first but it's not doing that. It first calculates B5*B6 and then it calculates the exponent and then it divides C3 by the result of D4^2 and finally adds.

Actually it is handling the exponent first. It just isn't part of the B5*B6. The exponent is involved in the part C3/D4^2. It is done before the division as you mentioned. Once all of this is done then the addition is done.

AdamRobinson may have answered all of your question. My post has some different info but is pretty much a late duplicate. If you are watching Excel do this step by step then and question that then it is the rule of working left to right. If the exponent was with B5*B6 then it would have been done before the multiplication.

Thanks for all suggestions guys. when i evaluate this formula using the "Evaluate Formula" button on the Auditing tool bar, it clearly displays that the multiplication between B5 * B6 takes place first, then the exponent D4^2 gets evaluated then the division and finally the addition.

Try this out yourself. Enter some numbers in B5, B6, C3, and D4 and then type the following expression as it is:

=B5*B6+C3/D4^2

No parenthesis have to be applied in the above formula. I just can't understand why B5*B6 gets evaluated first.

An exclusive Black Friday offer just for Expert Exchange audience! Buy any of our top-rated backup solutions & get up to 2TB free cloud per system! Perform local & cloud backup in the same step, and restore instantly—anytime, anywhere. Grab this deal now before it disappears!

The parenthesis you mentioned are being "assumed" by Excel. It is working from left to right. As it looks then it see the formula as (B5*B6)+(C3/(D4^2)). It is a logical order that sees + as a lower precedence order and then allows it to process the previous higher order. Without any precedence order and just the rule to work from left to right then the formula would need to be written as I showed it. The second formula you showed (the one with 2 + signs) would also follow these steps. B5*B6 and then C3/B5 can be processed as Excel moves from left to right. Nothing is wrong with your Excel program or the way it works.

I hope this clarifies what is happening. Let me know if you still have questions. The key is probably to remember that working left to right is the first rule. Once a lower order of precedence is found then the "block" can be calculated. It doesn't matter what is on the other side.

I should have realized you were just asking theoretically. The reason the formula does this was addressed by b0l above. Excel does make assumptions about multiplication and parentheses. The simple reason is there is no substantive difference between:

a * b and (a * b)

The better reason for doing so (keeping it mind it operates left to right!) is because

(a * b) + (c * d ^ 4)

really does need parentheses around the first part in order to be clearer. In your case, it's not as big of a deal, but think of this.

(a * b) + (b + a + c / 4) - (d + e + f) + (g) + (h+a)

Without the parentheses, a human might begin to stare there. Excel, IIRC, can provide parentheses' suggestions. Given this is the case, it likely is just built in to assume parentheses exist for the human using the program.

@SeriousNick - I may not have been clear enough when I tried to answer the question and mentioned Excel was working from left to right. What I meant to describe still looks at the signs to calculate. In your example (2 + 3 * 5) it would see the multiplication sign, as it moved from left to right, and not calculate, since the precedence was higher. The calculation would be correct. The method my comment described would not yield 25. I'm sorry if that wasn't clear in what I typed and thanks for giving me a chance to clarify it.

Thats great.
I was simply mentioning the acronym BODMAS (which is taught at elementary levels of education) contrary to popular belief that one should calculate from the left first.
This "rule" has been adapted by electronic calculations too, and therefore is the basic principle used when a formula/equation has been poorly written (without parentheses for example).
Regardless of how Excel "appears" to be doing the calculations - it should always follow the above priniciple.
It works for kids of a very young age and can still work for us "older" folks...... Simple to remember (which becomes so much more helpful as time ticks by ...).

No offence intended whatsoever so hopefully none taken. :)

Although, in re-reading, I have to admit >>"The key is probably to remember that working left to right is the first rule."<< in your post was misleading so glad we had a chance to clarify the position on that.

The viewer will learn how to successfully create a multiboot device using the SARDU utility on Windows 7.
Start the SARDU utility:
Change the image directory to wherever you store your ISOs, this will prevent you from having 2 copies of an ISO wit…