[Contents]

Order of Operations aka Precedence
John Denker

A perverse meme has been floating around on Faceborg since 2019 if not before. The meme is 100% industrial-strength trolling. Anybody who gives a numerical answer is missing the point. The more certain they are of “the” numerical answer, the more wrong they are.

The key point is that the question is ill-posed.

1  Discussion

Some mathematical notations are well defined, whereas others are not. Note the contrast:

1) It is generally agreed that explicit multiplication operators — including (×), (*), and (·) — have the same precedence as division, and therefore a string of divisions and explicit multiplications should be carried out left-to-right.
2) The story is different for implicit multiplication, aka multiplication by apposition, with no explicit operator, as in the expression 2z. There are two different conventions, i.e. two different schools of thought, and always have been.
2a) According to one school of thought, multiplication by apposition has the same precedence as the explicit multiplication operators.
2b) According to the other school of thought, multiplication by apposition binds more tightly than division. This notation works fine. It is used in physics; for example, it routine to express the kinetic energy as p2/2m ... which most assuredly means p2/(2m). Let’s be clear:
          p2/2m = p2/(2m)
whereas
          p2/2×m = (p2/2)×m

The mnemonics you learned in primary or secondary school apply to neither convention (2a) nor convention (2b). Multiplication by apposition was not discussed at all. Explicit multiplication operators were required. Similarly, many (albeit not all) computer languages simply forbid multiplication by apposition, so they don’t have to deal with the ambiguity. Nothing you say will change the fact that both schools of thought exist.

This situation is not new. Both schools of thought have existed for a very long time. This is not a serious problem, because you can usually figure out which meaning was intended. Except when you are being intentionally trolled.

Key point: The meme in figure 1 is ill-posed. It is ill-posed several times over, including the fact that the statement of the problem starts out with a lie, and centering on the fact that the question has no unique numerical answer.

2  Additional Trolling

precedence-meme
Figure 1: Ill-Posed Question

3  Ill-Posed Questions in the Real World

People encounter ill-posed questions All The Time. The question of what to have for dinner is ill-posed, insofar as there is usually more than one good answer. Even within mathematics, it is routine to encounter questions that are mildly ill-posed, such as:

Find “the” value of z such that z*z = 9

Other questions are grossly ill-posed, such as

Find y and z such that y+z=9.

Others are ill-posed in the other direction; that is, they have no solutions at all, such as:

Find a rational number z such that z*z=2.

or

Find a point on the earth’s surface that is 10 miles north of the north pole.

If you were expecting mathematical notation to be unambiguous, you are in for a long series of rude surprises.

Recommendation: Whenever you encounter a new problem, the first step should be to ask, How badly ill-posed is this?

For more on this, see reference 1.

4  References

1.
“How to Deal with Ill-Posed Questions”
../physics/ill-posed.htm
[Contents]