# Multiple Integration order doesn't agree.

Let $0<x,y,t,z<1$ with the additional condition:

\begin{align*} x &< t\\ \wedge & \ \\ y &<z \end{align*}

Call the set of all $x,y,t,z$ satisfying the above conditions $S$. I want to evaluate $\int_S dxdydtdz$. One way of doing it is first integrating out $z$ and then integrating along columns down up. This ordering gives:

$$\int_0^1\int_0^t\int_x^1\int_y^1 dzdydxdt=\int_0^1\int_0^t\int_x^1(1-y) dydxdt=\frac{1}{8}.$$

Another way is to just integrate up along columns without first integrating $z$:

$$\int_0^1\int_0^1\int_0^t\int_x^zdydxdzdt=\frac{1}{12}.$$

Why do these not agree? It seems like the second way is wrong. I think maybe in the second way one needs to integrate $x$ from $0$ to $\min(x,z)$, but then again I thought the $y$ variable ensures this.

It is just what you said (except there is what appears to be a typo in the question where you introduced a variable $x_0$ that should be $t$) -- in the second integral [from the inside], the upper bound for $x$ must be $\text{min}(z, t)$.