I have the following matrix equations (all entries are in general complex):
$\begin{pmatrix}v_{0}\\w_{0}\end{pmatrix}=A\begin{pmatrix}v_{2}\\w_{2}\end{pmatrix}$
$\begin{pmatrix}V_{2}\\W_{2}\end{pmatrix}=B\begin{pmatrix}V_{3}\\W_{3}\end{pmatrix}$
$\begin{pmatrix}v_{3}\\w_{3}\end{pmatrix}=C\begin{pmatrix}v_{4}\\w_{4}\end{pmatrix}$
where $V_{i}=|v_{i}|^2$, $W_{i}=|w_{i}|^2$, and the capital letters stand for 2x2 matrices. I want to get something like
$\begin{pmatrix}v_{0}\\w_{0}\end{pmatrix}=D\begin{pmatrix}v_{3}\\w_{3}\end{pmatrix}$
What is the best way to do this? Ideally I want the method to be easily implementable in Python or Matlab.
Thanks
Impossible. Your equations don't allow you to determine $v_0$ and $w_0$ from $v_3$ and $w_3$. You could multiply $v_0$, $w_0$, $v_2$ and $w_2$ by $-1$ and the equations would still remain true.