How can I justify this set manipulation to show a result in probability? I am working on the following problem:

Proof: Let $a, b, c, d \in \mathbb{R}$ with $a < b$ and $c < d$. We have \begin{align*}P(a < x \leq b, c < Y \leq d) &= P[\{a < x \leq b\}\cap\{c < Y \leq d\}]\\ &= P[(\{X \leq b\} \sim \{X \leq a\})\cap(\{Y \leq d\} \sim \{Y \leq c\})].\end{align*}
Now if there was some sort of "DeMorgan's-esque" distributive law for intersections and set differences, we'd arrive at the desired result: $$P(\{X \leq b\}\cap\{Y \leq d\}) - P(\{X \leq b\}\cap\{Y \leq c\}) - P(\{X \leq a\}\cap\{Y \leq d\}) + P(\{X \leq a\}\cap\{Y \leq c\}).$$
I don't know the justification for this though.
 A: Integrate the pointwise identity $$\mathbf 1_{a < x \leq b,c < y \leq d}=(\mathbf 1_{x \leq b}-\mathbf 1_{x \leq a})\cdot(\mathbf 1_{y \leq d}-\mathbf 1_{y \leq c})=\mathbf 1_{x \leq b,y \leq d}-\mathbf 1_{x \leq b,y \leq c}-\mathbf 1_{x \leq a,y \leq d}+\mathbf 1_{x\leq a,y \leq c}$$ with respect to $P_{(X,Y)}(\mathrm dx\mathrm dy)$.
A: You have the four events
$$
A := [X\le a], \;B:=[X\le b], \; C:=[Y\le c], \; D:=[Y \le d].
$$
Since $A$ implies $B$, $$P(\neg A \wedge B \wedge X)=P(B\wedge X)-P(A\wedge B\wedge X)= P(B\wedge X) - P(A \wedge X)$$ for any $X$.  (For arbitrary $A$ and $B$, only the first equality would be sound.)  Similarly, since $C$ implies $D$, $$P(\neg C \wedge D \wedge Y)=P(D\wedge Y)-P(C\wedge D\wedge Y)=P(D\wedge Y)-P(C\wedge Y)$$
for any $Y$.  Putting these together gives
$$
\begin{eqnarray}
P(a<X\le b, c<Y\le d) &=&
P(\neg A \wedge B \wedge \neg C \wedge D)\\&=&P(B\wedge \neg C\wedge D)-P(A \wedge \neg C \wedge D) \\
&=&\left(P(B\wedge D) - P(B\wedge C)\right)-\left(P(A\wedge D) - P(A\wedge C)\right) \\
&=&(F(b,d)-F(b,c))-(F(a,d)-F(a,c)) \\
&=&F(b,d)-F(b,c)-F(a,d)+F(a,c),
\end{eqnarray}
$$
which is what you wanted to show.
