matrices such that $A^2B+BA^2=2ABA$ Let be $A$, $B$ two matrices $3 \times 3$ with complex entries.
Prove that if $$A^2B+BA^2=2ABA$$
THEN
$$B^2A+AB^2=2BAB$$
I tried it and do not know how to continue.
If $A$ is invertible then
$$AB^2+A^{-1}BA^2B=2BAB$$
so I have to prove that
$$B^2A=A^{-1}BA^2B$$
How to continue and also have to discuss the case when $A$ is not invertible

The statement in question is equivalent to $[A,[A,B]]=0\rightarrow[[A,B],B]=0$ and it is false. Here is a counterexample taken from the last section of Irving Kaplansky, Jacobson's Lemma Revisited, Journal of Algebra, 62, 473-476 (1980):
\begin{aligned}
A&=\pmatrix{1&1&0\\ 0&1&0\\ 0&0&1},\quad B=\pmatrix{0&0&0\\ 0&0&1\\ 1&0&0},\\
[A,B]&=\pmatrix{1&1&0\\ 0&1&0\\ 0&0&1}\pmatrix{0&0&0\\ 0&0&1\\ 1&0&0}-\pmatrix{0&0&0\\ 0&0&1\\ 1&0&0}\pmatrix{1&1&0\\ 0&1&0\\ 0&0&1}\\
&=\pmatrix{0&0&1\\ 0&0&1\\ 1&0&0}-\pmatrix{0&0&0\\ 0&0&1\\ 1&1&0}
=\pmatrix{0&0&1\\ 0&0&0\\ 0&-1&0},\\
[A,[A,B]]&=A[A,B]-[A,B]A=[A,B]-[A,B]=0,\\
[[A,B],B]&=\pmatrix{0&0&1\\ 0&0&0\\ 0&-1&0}\pmatrix{0&0&0\\ 0&0&1\\ 1&0&0}-\pmatrix{0&0&0\\ 0&0&1\\ 1&0&0}\pmatrix{0&0&1\\ 0&0&0\\ 0&-1&0}\\
&=\pmatrix{1&0&0\\ 0&0&0\\ 0&0&-1}-\pmatrix{0&0&0\\ 0&-1&0\\ 0&0&1}
=\pmatrix{1&0&0\\ 0&1&0\\ 0&0&-2}\ne0.
\end{aligned}
