I want to solve for matrix $X$ in this linear system:
$$(AX + B)^T(AX + B) = 0$$
where $A$ and $B$ are known.
Is there a function for this in Python?
I want to solve for matrix $X$ in this linear system:
$$(AX + B)^T(AX + B) = 0$$
where $A$ and $B$ are known.
Is there a function for this in Python?
Copyright © 2021 JogjaFile Inc.
As underlined by @Peter Franek, your equation is equivalent to:
$$\tag{1}\|AX+B\|^2=0$$
But a vector has norm $0$ if and only if it is the zero vector.
Thus (1) is equivalent to $AX+B=0$. Therefore, you have to find solution(s) to linear system:
$$AX=-B$$
Now, it's classical. It depends on matrices' dimensions (you don't provide information about it).
If $A$ is square, take a look at (https://docs.scipy.org/doc/numpy/reference/generated/numpy.linalg.solve.html).