3

A simple question: Is $x - (\pm y) = x \pm y$?

I can't really find an answer anywhere else. But it seems to obviously be true, since they both give the expressions $x - y$ and $x + y$?

Antony Theo.
  • 4,716

3 Answers3

9

When it comes to pieces of an expression that have an arbitrary choice of sign, like your example, or like the quadratic formula, there's sort of three levels of complexity, which tell us how careful you have to be with writing $x - (\pm y)$ as $x \pm y$. (The situation we're in depends on context!)


On the first level of complexity, maybe this single instance of $\pm$ is the only instance of an arbitrary sign in the entire expression, and we're not going to be comparing it to any other expressions with $\pm$. In this case, $x-(\pm y)$ and $x \pm y$ are exactly equivalent because (as noted in the question) they can both yield either $x+y$ and $x-y$ as values.


On the second level of complexity, maybe there is a single choice of arbitrary sign throughout what we're doing, but it can appear in several places, and they need coordinating. At this point, we introduce the symbol $\mp$ in addition to $\pm$; the idea is that we choose either the top or the bottom option everywhere throughout, so that $x \pm y \mp z$ can either mean $x+y-z$ or $x-y+z$. A good example of this is two versions of the quadratic formula: $$x = \frac{-b \pm \sqrt{b^2-4ac}}{2a} = \frac{2c}{-b \mp \sqrt{b^2-4ac}}.$$ Here, the root we get from the first quadratic formula by changing $\pm$ to $+$ is the same root as the one we get from the second formula by changing $\mp$ to $-$.

If we're working on this level of complexity, then $x - (\pm y)$ should be changed to $x \mp y$: in both cases, if we take the top option, we get $x-y$, and if we take the bottom option, we get $x+y$. Changing it to $x\pm y$ would swap the two options.


Finally, we might have several sources of arbitrary signs. At this point, the expression "$x \pm y \pm z$" can mean one of four things: $x+y+z$, $x+y-z$, $x-y+z$, and $x-y-z$.

Here, it is fine to replace $x - (\pm y)$ by $x \pm y$, and we're not going to use $x \mp y$ at all, because we're not attempting to coordinate.

However, at this point, using $\pm$ in the first place is a bit risky. We might be able to get away with it, but if we're trying to be very careful, we should write $x \pm y \pm z$ as something like "$x + \epsilon_1 y + \epsilon_2 z$, where each $\epsilon_i$ can be either $1$ or $-1$", and then we make sure to use the correct $\epsilon_i$ every time it comes up.

Misha Lavrov
  • 159,700
  • Yes that is true. If I say $z=x+\pm y$ and $z'= x -\pm y$, then I am saying something about the joint distribution of $z$ and $z'$. If $y$ is nonzero then $z \not = z'$. Even though $z$ and $z'$ are both in the set ${x+y,x-y}$,. – Mike Jan 10 '25 at 17:44
5

Note that $x\pm y$ can be thought of as a set with precisely these $2$ elements $x+(+y)=x+y$ and $x + (-y)=x-y$. [Indeed, when we say $z=x\pm y$ we mean either $z=x+y$ or $z=x-y$. Equivalently, when we say $z=x\pm y$ we mean $z$ is in the set $\{x+y, x-y\}$.] So in particular, $x \pm y$ is the set $\{x+y, x-y\}$.

By similar reasoning, $x-(\pm y)$ can also be thought of as a set with precisely the two elements $x-(+y)=x-y$ and $x-(-y) = x+y$. So in particular $x - (\pm y)$ is the set $\{x-y, x+y\}$.

Note then that $x\pm y$ $=\{x+y, x-y\}$ $=\{x-y, x+y\}$ $=x -(\pm y)$. So yes they are the same.

Mike
  • 23,484
  • 2
    This is similar to the abuse of notation which is common for big and small O notation. We write $f=O(g)$, but actually we mean $f \in O(g)$, because $O(g)$ is a set of functions (those which grow at most as fast as $g$). In this case, the abuse is arguably even worse since $O(g)$ is a huge set, not just a $2$-element as in $\pm x$ (which, to be precise, is a $1$-element set when $x=0$). You also break transitivity of $=$ since "$1 = O(2)$" and "$2 = O(2)$", but $1 \neq 2$. Likewise, $1 = \pm 1$ and $-1 = \pm 1$ (with your explanation!), but $1 \neq -1$. So one has to be extra careful here. – Martin Brandenburg Jan 10 '25 at 21:18
2

There isn't a real, formal meaning for the $\pm$ symbol. The problem is that while $x=\pm1$ means intuitively "$x$ is $1$ or $-1,$" all our formal language form math doesn't understand what "$1$ or $-1$" means - the "or" word only applies to propositions, not numbers.

So we can instead rewrite it as "$x=1$ or $x=-1.$" That is, the "or" gets applied to all the complete statements.

Now, if you see an expression or equation with two or more $\pm$ symbols. Sometimes you want them to be the same, and sometimes allowed to be different. And mathematicians will use both of these, which seems inconsistent, but usually is clear in context.

If a mathematician writes $a\pm b\pm c,$ most others would treat this as independent signs, because the mathematician could write $a\pm(b+c)$ if they wanted to imply the signs were the same. But often mathematicians treat multiple $\pm$ as equal, because, with $n$ such symbols, we have $2^n$ meanings, if they are independent, which can explode,the cases, this can be a mess.

Your statement is more problematic, because it doesn't mean what you might think it means, using a simple substitution like above. That would mean one of these expressions is true:$$x-(+y)=x+(+y)\\ x-(+y)=x+(-y)\\ x-(-y)=x+(+y)\\ x-(-y)=x+(+y)$$ One of those is, of course, always true, but I'm guessing the writer would want you to know that, for either sign on the left, there is a solution on the right.

Formally, for any $x,y,$ if $s\in\{1,-1\}$ then there exists another sign $t\in\{1,-1\}$ such that $x-sy=x+ty.$

The additional difficulty with your expression is that it seems to imply that the value of $t$ depends on the values of $x,y,$ and $s$ while it would be really nice to be able to say that there is a $t$ which depends only on $s,$ "such that for any $x,y,$ $x-sy=x+(ty).$"

Most mathematicians would instead use the $\mp$ symbol, to indicate the opposite sign, in your statement:

$$x-(\pm y)=x+(\mp y).$$

But even then, if we took the same approach we used for $x=\pm1,$ we would interpret this as "$x-(+y)=x+(-y)$ or $x-(-y)=x+(+y).$" But that is probably not what you mean. - you probably want to say both of these are true.

So, $\pm$ is an ambiguous notation used by humans to simplify things, but the meaning is highly context-dependent and can't be defined for a formal system without breaking some or all the ways we use it. Its meaning is highly context-dependent.

As a general rule, don't use multiple independent $\pm$ in an equation or formula unless context or logic makes it obvious that you could not mean anything else.

The main reason to use $\pm$ is to communicate patterns quickly. If you write $\pm\sqrt{b^2-4ac},$ we see the relation between the two options, but if we wrote out the two options, a reader would have to scan the inside of the square roots to make sure they are the same - the pattern becomes obtuse. This is a human consideration, not a formal consideration.

There is a lot of math language that is context-dependent. The two expression: $$\lim_{n\to\infty}f(n)\\\lim_{x\to\infty} f(x)$$ are technically identical, except for the variable names, but, without context, most mathematicians would treat the first as a sequence limit and most would take the second to mean a limit in the real numbers.

Thomas Andrews
  • 186,215