One of the exercise problems in my course on discrete mathematics is to prove that:
$$R \circ S_1 - R \circ S_2 \subseteq R \circ (S_1 - S_2)$$
My attempt: \begin{align*} R \circ S_1 - R \circ S_2 &= \{[s, r]:[s,r]\in R \circ S_1 \wedge [s, r] \notin R \circ S_2 \}\\ &= \{[s, r] \exists x :[s, x] \in S_1 \wedge [x, r] \in R \wedge \neg(\exists y: [s, y] \in S_2 \wedge [y, r] \in R) \}\\ &= \{[s, r] \exists x :[s, x] \in S_1 \wedge [x, r] \in R \wedge (\forall y: [s, y] \notin S_2 \vee [y, r] \notin R) \} \end{align*} \begin{align*} R \circ (S_1 - S_2) &= \{[s,r]\exists x: [s,x] \in S_1 \wedge [s, x] \notin S_2 \wedge [x, r] \in R\} \end{align*}
After that I'm a bit lost. Is my approach correct? How would one approach a problem like this.
Assume $a\in R\circ S_1-R\circ S_2$. Then $a\in R\circ S_1$, i.e., $a=[x,z]$ for some $x,z$ and there exists some $y$ with $[x,y]\in R$ and $[y,z]\in S_1$. If we also had $[y,z]\in S_2$, then $[x,z]\in R\circ S_2$ contradicting $a\notin R\circ S_2$. Therefore, $[y,z]\in S_1-S_2$ and so with $[x,y]\in R$, we end up with $[x,z]\in R\circ (S_1-S_2)$.
So $$\forall a\colon a\in R\circ S_1-R\circ S_2\to a\in R\circ (S_1-S_2),$$ which by definition means $$ R\circ S_1-R\circ S_2\subseteq R\circ (S_1-S_2).$$