Relationship between decompositions of matrices with overlapping kernels Suppose $A$ and $B$ are two positive semidefinite matrices of size $N\times N$, satisfying
$$
\ker(A) \subseteq \ker(B) \quad\Rightarrow \ \ \textrm{Im}(B) \subseteq \textrm{Im}(A)
$$
Further assume $A$ has rank $P\leq N$, hence admitting the decomposition $A=VV^T$, where $V$ is a matrix of size $N\times P$. Then does $B$ always admit the decomposition
$$
B = VXV^T
$$
where $X$ is a positive semidefinite matrix of size $P\times P$?
 A: $\DeclareMathOperator{\im}{im}$Permit me to work things out in the language of linear transformations. Let $W$ be an $N$-dimensional real or complex inner product space, and let $A$, $B \in L(W)$ be positive operators such that $\ker(A) \subseteq \ker(B)$, and hence $\im(B) = \ker(B)^\perp \subseteq \ker(A)^\perp = \im(A)$.
First, observe that $\ker(\sqrt{A})^\perp = \im(\sqrt{A}) = \im(A)$, and let $P$ denote the orthogonal projection onto $\im(A)$ as a map $W \to \im(A)$, with adjoint $P^\ast : \im(A) \to W$ given by the inclusion of $\im(A)$ in $W$. Let $T$ denote the restriction of $\sqrt{A}$ to a map $\im(A) \to \im(A)$. Then $T \in L(\im(A))$ is positive and invertible, and $\sqrt{A} = P^\ast T P$, so that $A = VV^\ast$ for $V := P^\ast T : \im(A) \to W$.
Now, since $\ker(A) \subseteq \ker(B)$ and $\im(B) = \ker(B)^\perp \subseteq \ker(A)^\perp = \im(A)$, let $X_0$ denote the restriction of $B$ to a map $\im(A) \to \im(A)$. Then $X_0 \in L(\im(A))$ is positive semidefinite, and $B = P^\ast X_0 P$, so that $X := T^{-1}X_0 T^{-1} \in L(\im(A))$ satisfies $$V X V^\ast = P^\ast T T^{-1} X_0 T^{-1} T P = P^\ast X_0 P = B.$$ Setting $W = \mathbb{C}^N$ with the standard orthonormal basis and choosing an orthonormal basis for $\im(A) \cong \mathbb{C}^P$ then yields the result for matrices you were looking for.
