I have attached a PDF with some equations. (a) is essentially describing a pure state quantum system, with (b) and (c) statistical mixtures. I've managed to substitute (d) and (e) into (b) and (c) respectively, however I was wondering how to substitue (d) and (e) into (a). Apparently the answer is similiar to 1/square2=[|45,X>+|135,Y>], but was wondering if I could be walked through the steps to get to that. I know there are inverses of (b) and (c), but if we apply those inverses to (b) and (c), do we end up with the same result as those in the PDF (d) into (b) and (e) into (c)?