Probability that $\displaystyle \vert x\vert +\vert y\vert +\vert z\vert +\vert x+y+z\vert=\vert x+y\vert +\vert x+z\vert +\vert y+z\vert$
Real numbers $x, y$, and $z$ are chosen from the interval $[−1, 1]$ independently and uniformly at random. What is the probability that $$\vert x\vert +\vert y\vert +\vert z\vert +\vert x+y+z\vert=\vert x+y\vert +\vert x+z\vert +\vert y+z\vert$$
Now if all of $x, y, z$ are positive or all negative then the equation is of course satisfied. Hence if we consider a 3D space , it denotes two unit cubes, one in the first octant centred at $\left( \frac 12,\frac 12,\frac 12\right)$ and the other in seventh octant centred at $\left( -\frac 12,-\frac 12,-\frac 12\right)$.
The total measure of universal set is the cube with edge length $2$ centred at origin.
But now I have a problem about what if any two of $x, y, z$ are positive while the other remaining be negative or the other way around. Even if I try to make cases it seems to be quite a cumbersome task to approach since we will also need to check signs of $\vert x+y\vert$ and similarly others as well as that of $\vert x+y+z\vert $
I also thought to give a shot using vectors but didn't reach any specific result.
Any help would be quite beneficial.
Edit:
I would also be happy to see a geometrical intuitive way to attack the problem.
Solution 1:
Suppose $x$ and $y$ are positive and consider the possible values of $z$. Because $|x|+|y|=|x+y|$ here, we want the equation $$ |z| + |x+y+z| = |x+z| + |y+z| $$ to hold.
Assume $x \le y$; in this case, we have $z \le x+z \le y+z \le x+y+z$, and so we can consider five possibilities based on which of these are positive.
- $0 \le z \le x+z \le y+z \le x+y+z$. Then the equation holds. You already know this case.
- $z \le 0 \le x+z \le y+z \le x+y+z$. Then the equation simplifies to $x+y=x+y+2z$, which has probability $0$.
- $z \le x+z \le 0 \le y+z \le x+y+z$. Then the equation simplifies to $x+y=y-x$, which has probability $0$.
- $z \le x+z \le y+z \le 0 \le x+y+z$. Then the equation simplifies to $x+y = -x-y-2z$, which has probability $0$.
- $z \le x+z \le y+z \le x+y+z \le 0$. Then the equation holds. This case is new.
The same thing happens when $x \ge y$, so that doesn't need to be considered separately.
So we see that when $x$ and $y$ are positive, we want either $z$ to be positive as well, or we want $x+y+z$ to be negative.
By symmetry, this covers all the possibilities. The equation holds when:
- All three of $x,y,z$ are positive;
- Two of $x,y,z$ are positive, but $x+y+z$ is negative;
- Two of $x,y,z$ are negative, but $x+y+z$ is positive;
- All three of $x,y,z$ are negative.
The regions inside $[-1,1]^3$ where these hold have volume respectively:
- $1$ (it's a cube of side length $1$);
- $\frac12$ (it's three pyramids that form a corner of a cube with $\frac16$ the volume);
- $\frac12$;
- $1$.
So total volume $3$ (out of $8$), so the equation holds with probability $\frac38$.
Solution 2:
A simulation using R statistical software, for those interested, agrees with the theoretical answer.
> x<-runif(10^7,-1,1)
> y<-runif(10^7,-1,1)
> z<-runif(10^7,-1,1)
> mean(abs(x)+abs(y)+abs(z)+abs(x+y+z)==abs(x+y)+abs(x+z)+abs(y+z))
[1] 0.3749906