Viewing a single comment thread. View all comments

SurprisedPotato t1_jacqvpl wrote

PEMDAS is a convention, not a fact of mathematics. And it's not the only convention we use, it's just the most common one.

Because PEMDAS is the main convention used, people understand that 5 + 4 x 3 ^ 2 - 1 means "raise 3 to the power of 2, to get 9, then multiply 4 by that, to get 36, then add 5 and 36 to get 41, then subtract 1.

If we used "PEASMD" instead (nobody does), we'd have to write 5 + (4 x 3 ^ 2) - 1 to get the same result.

There are systems that don't need brackets, such as Polish (or Reverse Polish) notation, where you put the operator first (or last) and the things it operates on after that (or before that, for Reverse Polish).

So 4 + 9 would be + 4 9, and the expression I gave above would be

- + 5 x 4 ^ 3 2 1

Which means "subtract the result of + 5 x 4 ^ 3 2 and 1"

+ 5 x 4 ^ 3 2 

would mean "add 5 and the result of x 4 ^ 3 2"

And x 4 ^ 3 2 would mean "multiply 4 and the result of ^ 3 2"

and so on

4