# Order of operation and 0 being a real number

Recently, this problem has been posted around social sites.

$6-1\times 0+2\div 2=x$

Order of operations: Go through and do mult/division and then add/sub

$6-(1\times 0)+(2\div 2)=x$

$6-(0)+(1)=x$

$6+1=x$

$7=x$

I have friends vehemently arguing that after you multiply $1$ by $0$, you can just get rid of the zero which would leave $6 - +1 = x$ and when you minus the positive you get $5$. I am extremely sure this is wrong, but having a hard time explaining this (well enough that they will accept it). Thanks!

-
You're using "x" to mean two different things. Please consider using $\mathrm{\LaTeX}$ for math. Note that a multiplication dot is made with \cdot. While MathJax (essentially $\mathrm\LaTeX$ math mode for Javascript) that we use here doesn't support everything regular $\mathrm\LaTeX$ can do, reading the excellent piece of $\mathrm\LaTeX$ documentation known as lshort.pdf is never a bad idea. – kahen Oct 27 '12 at 5:37

You did it right. You can "get rid of the $0$" in the sense that $6-0=6$, but you can't necessarily drop it from the equation without ending up with a goof of the sort you see.

To avoid these problems, change subtractions to additions of the opposite. Then $$6-0+1=x$$ becomes $$6+(-0)+1=x,$$ which in turn becomes $$6+0+1=x.$$ At this point, we can drop the zero without problems.

-

Your friend is wrong, and you can easily prove them wrong:

When they claim "you can get rid of the zero in such-and-such way", the meaning of that claim is not, "the math police, following the ineffable rules laid down by the Math Emperor, will permit this rewriting". If that were so, the only way to find out whether the claim is true would be to approach a math cop and ask them. But the real meaning of the claim is:

If you do such-and-such, you will get a new expression that has the same value as the one you started with.

And the truth of that is easily checkable by anyone. We simply take the original and the rewritten expressions: $$6 - 0 + 1 \qquad\text{versus}\qquad 6 - (+1)$$ and do the calculations each of them says to do. The one on the left gives the result $7$; the rewritten one gives the result $5$. Since $5$ is different from $7$, your friend's claim is false, and this is all the proof of its falsehood you need.

Okay, wiseguy, you say now, but you need rules in order to calculate an expression, and how do you know these rules work if checking them involves the calculation that needs the rules in the first place? For example, how do you know it's allowed to rewrite $6-1\times 0 + 2\div 2$ into $6-0+2\div 2$? We need that rule in order to find out what the correct value of $6-1\times 0+2\div 2$ is.

Actually, we don't. The meaning of an expression such as $6-1\times 0+2\div 2$ is an instruction to carry out certain computations indicated in this diagram:

You don't need to construct any new expressions along the way -- just fill in the results:

(Note, by the way, that the term "order of operations" is actually quite misleading here. What the order of operations do is to tell us which diagram the expression asks us to calculate -- but the actual order we do the operations in that diagram in is not important. For this calculation we can choose to do multiplication first, then division, subtraction and addition -- but it would be just as valid to do multiplication, subtraction, division, addition, or division, multiplication, subtraction, addition. As long as we don't try to do an operation until its inputs are known, we can choose any sequence we like).

So why can we replace $6-1\times 0+2\div 2$ by $6-0+2\div 2$? That is because the latter expression encodes the diagram we get by forgetting where the blue $0$ came from:

and obviously that is not going to change anything in the rest of the completed diagram -- in particular it will not change the result and therefore the rewriting is valid.

But wait! If that is all that matters, then it would also be legal to rewrite $6-0+1$ to $42\div 6$ because both make $7$, but how do you justify that?

Yes, that is legal, and it does not need any justification beyond the fact that both make $7$. Whenever you meet the expression $6-0+1$ in mathematics it is totally valid to rewrite it to $42\div 6$. It is most often a completely useless thing to do, but it is allowed nevertheless. Most of the rules we encounter in everyday arithmetic/algebra are more useful than that, because they are instances of general rules where we can prove once and for all that it will always be valid (such as the rule of rewriting $a+b$ into $b+a$) -- but that just makes them easier to remember than ad-hoc rewritings such as $6-0+1=42\div 6$. They are not "more valid".

-