Order of operation and why this gives the wrong answer?

  • MHB
  • Thread starter find_the_fun
  • Start date
In summary: This is not true. In general, when you have a doubt about the order of operations, it is better to use parentheses. However, there are occasions when parentheses are not necessary, and this is one of them.
  • #1
find_the_fun
148
0
Consider the expression \(\displaystyle 4+2-7+1+(8-3).\) To solve it, use BEDMAS.
Brackets: \(\displaystyle (8-3)=5\)
Exponents: none
Divsion: none
Multiplication: none
Addition: \(\displaystyle 4+2-7+1+5 = 6 - 13\)
Subtraction: \(\displaystyle 6-13 = -7\)

According to a calculator (and a voice in my head) the answer should be \(\displaystyle 5\). This answer is arrived at if you evaluate the expression left to right, so what is going on here?
 
Mathematics news on Phys.org
  • #2
find_the_fun said:
Consider the expression \(\displaystyle 4+2-7+1+(8-3).\) To solve it, use BEDMAS.
Brackets: \(\displaystyle (8-3)=5\)
Exponents: none
Divsion: none
Multiplication: none
Addition: \(\displaystyle 4+2-7+1+5 = 6 - 13\)
Subtraction: \(\displaystyle 6-13 = -7\)

According to a calculator (and a voice in my head) the answer should be \(\displaystyle 5\). This answer is arrived at if you evaluate the expression left to right, so what is going on here?

You are treating what I highlighted in red as:

\(\displaystyle 4+2-(7+1+5) = 6 - 13\)

When you want to go from left to right as follows:

\(\displaystyle 4+2-7+1+5=\)

\(\displaystyle 6-7+1+5=\)

\(\displaystyle -1+1+5=\)

\(\displaystyle 0+5=\)

\(\displaystyle 5\)
 
  • #3
MarkFL said:
You are treating what I highlighted in red as:

\(\displaystyle 4+2-(7+1+5) = 6 - 13\)

When you want to go from left to right as follows:

\(\displaystyle 4+2-7+1+5=\)

\(\displaystyle 6-7+1+5=\)

\(\displaystyle -1+1+5=\)

\(\displaystyle 0+5=\)

\(\displaystyle 5\)

Isn't that a violation when you evaluate \(\displaystyle 6-7\) before \(\displaystyle 7+1+5\)? If no then what is meant by addition gets evaluated before subtraction? I supposed it's meant to resolve ambiguous situations but I can't imagine what could cause an ambiguous situation.
 
Last edited:
  • #4
BEDMAS is an abomination, as the mnemonic misleads you as to what you are actually supposed to DO.

The expression:

4 + 2 - 7 + 1 + 5

should be treated as:

4 + 2 + (-7) + 1 + 5,

which can now be evaluated unambiguously.

(the idea is that the "scope" of the minus sign is ONLY the following number: otherwise, the subtraction keeps "flip-flopping" the signs of subsequent terms:

$a - (b + c + d) = a - b - c - d$ <---see how THREE signs got changed instead of one?).

My advice: avoid BEDMAS like the plague, and INSIST on properly placed parentheses.
 
  • #5
find_the_fun said:
Isn't that a violation when you evaluate \(\displaystyle 6-7\) before \(\displaystyle 7+1+5\)? If no then what is meant by addition gets evaluated before subtraction? I supposed it's meant to resolve ambiguous situations but I can't imagine what could cause an ambiguous situation.

Addition and subtraction are done from left to right, with both having the same level of precedence, just as multiplication and division have the same level of precedence. Like Deveno, I don't care for mnemonics used for order of operations. I would actually choose to do the following:

\(\displaystyle 4+2-7+1+(8-3)=(4+2+1+8)-(7+3)=15-10=5\)
 
  • #6
The trouble with BEDMAS is it mixes apples and oranges, it's like saying words should be alphabetized by color first, and then by letter.

Parentheses "group quantities", addition, subtraction, etc. are operations, BEFORE one does an operation, one ought to be CLEAR what one is operating ON. There is a difference between EVALUATING and SYNTAX.

In ordinary language, faulty syntax can be "sorted out" from context; in math, expressions are often "stand-alone" (no context).

When one encounters:

1 - 1 + 1, it's not clear what is INTENDED: even using BEDMAS, one cannot be SURE that the writer of said expression was ALSO using BEDMAS.

The insistence of BEDMAS being taught in schools, is further evidence to me that the school system is deeply flawed. I pity the poor programmer, who, when trying to code such an expression in a program, has to decide if the syntax of the programming language s/he is using matches the syntax of the person instructing him/her to write the program (even if that person is himself/herself).

Subtraction is a "bad operation", it is not associative:

$a - (b - c) \neq (a - b) - c$.

Addition does not have this problem. The same problem occurs with division, often people on these forums want us to simplify expressions like:

x/x^2 + x

and we have NO IDEA if they mean:

(x/x^2) + x = (1/x) + x = (x^2 + 1)/x, or:

x/(x^2 + x) = 1/(x + 1).

The trouble with:

"x minus..."

or

"x divided by..."

is: are we supposed to subtract/divide by EVERYTHING that comes after, or just the very NEXT thing? The problem is further compounded by the fact that many people don't even realize there's a difference.

It's like saying:

I gave my father the hat with the bacon.

Did I give my father some bacon, and a hat; or did I give him a hat decorated with tasty cured pork?
 
  • #7
In short, addition and subtraction have EQUAL POWER. Just like multiplication and division have EQUAL POWER.

The reason for this is because division is really a type of multiplication, it just happens to be a multiplication of fractions. Also subtraction is really a type of addition, it just happens to be an addition of a negative number.

So when using the Order of Operations, it's

Anything in brackets.

Any exponents.

Any multiplications or divisions, when read left-to-right.

Any additions or subtractions, when read left-to-right.
 
  • #8
I'm happy to clear up a misconception that has been following me since learning order of operation...that makes so much sense that addition and subtraction have same level of precedence.

I had a teacher who taught "If you're in doubt whether or not to use brackets, use them. They will never make the answer wrong and you can only gain marks by using them."
 

Related to Order of operation and why this gives the wrong answer?

1. What is the order of operation in math and why is it important?

The order of operation in math is the set of rules that determines the sequence in which operations should be performed in a mathematical expression. The order is parentheses, exponents, multiplication and division (from left to right), and addition and subtraction (from left to right). It is important because it ensures that everyone gets the same answer when solving a mathematical expression.

2. Can you give an example of the wrong answer due to incorrect use of the order of operation?

One example would be the expression 2 + 3 * 4. If the order of operation is not followed, the answer could be 20 instead of the correct answer of 14. This is because without following the order of operation, some operations may be performed before others, leading to a different result.

3. How does the order of operation prevent confusion in math?

The order of operation prevents confusion by providing a standard set of rules for solving mathematical expressions. Without it, different people may solve the same expression in different ways, leading to confusion and different answers. The order of operation ensures that everyone follows the same sequence of operations and gets the same answer.

4. What happens when the order of operation is not followed?

When the order of operation is not followed, the answer to a mathematical expression may be incorrect. This is because different operations have different levels of priority and not following the correct order can result in performing operations in the wrong sequence. This can lead to a different answer than if the order of operation was followed.

5. How can one remember the order of operation in math?

One way to remember the order of operation is through the mnemonic PEMDAS (Parentheses, Exponents, Multiplication and Division, Addition and Subtraction). Another way is to remember the phrase "Please Excuse My Dear Aunt Sally" which stands for Parentheses, Exponents, Multiplication and Division, Addition and Subtraction. It is also important to practice solving mathematical expressions using the order of operation to become more familiar with it.

Similar threads

Replies
3
Views
938
  • General Math
Replies
24
Views
2K
  • General Math
Replies
3
Views
657
Replies
3
Views
672
Replies
4
Views
2K
  • General Math
Replies
1
Views
838
  • General Math
Replies
4
Views
2K
Replies
5
Views
965
  • General Math
Replies
4
Views
2K
Back
Top