Example 1 Find all real parameters $a$ such that the equations
$$
x^{2}-(2 a+1) x+a=0
$$

and $x^{2}+(a-4) x+a-1=0$
have roots $x_{1}, x_{2}$ and $x_{3}, x_{4}$, respectively, and satisfy
$$
\frac{x_{1}}{x_{3}}+\frac{x_{4}}{x_{2}}=\frac{x_{1} x_{4}\left(x_{1}+x_{2}+x_{3}+x_{4}\right)}{a} .
$$
(2005, Bulgarian Winter Mathematical Competition)
Explanation: By Vieta's formulas, we have
$$
\begin{array}{l}
x_{1}+x_{2}=2 a+1, x_{1} x_{2}=a, \\
x_{3}+x_{4}=4-a, x_{3} x_{4}=a-1 .
\end{array}
$$

Transform the given equations into
$$
\begin{array}{l}
a\left(x_{1} x_{2}+x_{3} x_{4}\right) \\
=x_{1} x_{2} x_{3} x_{4}\left(x_{1}+x_{2}+x_{3}+x_{4}\right) .
\end{array}
$$

It is easy to get $a(2 a-1)=a(a-1)(a+5)$.
Since $a \neq 0$, we have
$$
a^{2}+2 a-4=0 \text {. }
$$

Solving this, we get $a=-1 \pm \sqrt{5}$.
When $a=-1 \pm \sqrt{5}$, the discriminants of both equations are greater than 0, so $a=-1 \pm \sqrt{5}$ are the solutions.