Generalizing central automorphism group condition to endomorphisms Given a group $G$, we can define its central automorphism group by $$\operatorname{Aut}_c(G)= C_{\operatorname{Aut}(G)}(\operatorname{Inn}(G)) = \{ \phi\in\operatorname{Aut}(G) : \phi(g)g^{-1} \in Z(G) \text{ for all } g\in G \}.$$
Suppose we have two finite groups $G, H$ with equal orders, and group homs $v\colon G\to H$ and $w\colon H\to G$. Suppose we also have subgroups $A\leq Z(G), B\leq Z(H)$ with $A\cong B$ satisfying $A w(H)=G$, $B v(G) = H$. I want to know if the following two conditions are equivalent:
(1) $w(v(g))g^{-1}\in C_G(w(H))$ for all $g\in G$
(2) $v(w(h))h^{-1}\in C_H(v(G))$ for all $h\in H$.
When $G=H$ and $v,w$ are auts, these are equivalent to saying the compositions $v\circ w, w\circ v$ are in the central automorphism group. And we can prove equivalence in this case. But the more general setting has eluded me. Loosely speaking, the assumptions with A, B can be thought of as saying v, w are almost invertible, and 1, 2 mean they are almost inverses. Note that in the automorphism case that a trivial central automorphism group forces v and w to be inverses.
The problem, in proving the second from the first,  seems to be showing, for $$f(h) = v(w(h))h^{-1},$$ that $f(H) \subseteq C_H(v(G))$. From this it follows that $f$ is a group hom, and thus the second condition. I'm having trouble seeing how to prove this by assuming the first condition. At best I have that $f(h)v(x)f(h)^{-1} = v(x) k$, for some $k\in \operatorname{ker}(w)$ depending on $x, h$. This follows by applying $w$.
EDIT: Had to add extra assumptions to cover the case $w=1$. In this case the new assumptions force both groups abelian, and so 1 and 2 are trivially satisfied.
 A: The idea of the proof turns out to be to show that $[f(h),v(y)]=1$ for all $h\in H$, $y\in G$ by repeatedly rewriting terms using (1), $G= A w(H)$, and $H=B v(G)$.  Here we define the commutator by $[a,b]=ab a^{-1}b^{-1}$.
So, let notation be as in the problem statement, and assume that (1) holds.  Then we may write $w(v(g)) = c(g)g$, where $c\colon G\to C_G(w(H))$ is a group homomorphism.  Specifically, $c(g) = w(v(g))g^{-1}$; it is just simpler to write $c(g)$ in the subsequent.
The goal, as indicated, is to show $[f(h),v(y)]=1$ for all $h\in H$ and $y\in G$.  By assumptions, we may write $h=v(x) b$, for some $b\in B$ and $x\in G$.  We may also write $x=a w(x')$ for some $a\in A$ and $x'\in H$.  It follows that
$$\begin{align}
f(h)v(y)f(h)^{-1} =& v(w(h))v(x)^{-1} b^{-1} v(y) b v(x) v(w(h))^{-1}\\
 =& v(w(h))\cdot v(x)^{-1} v(y)  v(x)\cdot v(w(h))^{-1}\\
 =& v(w(h))\cdot v(a w(x'))^{-1} v(y) v(a w(x'))\cdot  v(w(h))^{-1}\\
 =& v(w(h))\cdot v(w(x')^{-1} y w(x'))\cdot v(w(h))^{-1}\\
 =& v\left( w(h x'^{-1})\, y\, w(hx'^{-1})^{-1} \right).
\end{align}$$
We want this last expression to equal $v(y)$.  Thus it suffices to prove that $[w(hx'^{-1}),y]\in\operatorname{ker}(v)$.  Indeed, we will show that $[w(hx'^{-1}),y]=1$.
We may write $y=c(y)^{-1}w(v(y))$, from which it follows that $[w(hx'^{-1}),y] = [w(hx'^{-1}),w(v(y))]$.  By definition, we have $w(x')^{-1} = x^{-1} a$ and $w(h) = w(v(x))w(b) = c(b)c(x)xb$.  Therefore
$$\begin{align}
 [w(hx'^{-1}),w(v(y))] &= [w(h)w(x')^{-1},w(v(y))]\\
 &= [w(h)x^{-1} a, w(v(y))]\\
 &= [w(h)x^{-1},w(v(y))]\\
 &= [c(b)c(x) xbx^{-1},w(v(y))]\\
 &= [c(b)c(x)b,w(v(y))]\\
 &= 1,
\end{align}$$
thus establishing the desired claims and the result.
As a corollary, one gets that $\ker(w)\leq C_H(v(G))$; similarly for $\ker(v)$ by symmetry.  I did not need that $A,B$ were isomorphic, just that they were central (and so do no affect commutators). I also did not use that $G,H$ were finite (or had the same order), only that $A w(H) = G$ and $B v(G) = H$.
A: Please allow me to write homomorphisms as exponents.


*

*Note that since $B \le Z(H)$ and $H = B G^{v}$, we have $C_{H}(G^{v}) = Z(H)$, and similarly $C_{G}(H^{w}) = Z(G)$.

*We have $Z(G)^{v} \le Z(H)$, and similarly $Z(H)^{w} \le Z(G)$. This is because if $g \in Z(G)$, then $g^{v} \in Z(G^{v}) \le Z(H)$, since $H = B G^{v}$, and $B \le Z(H)$.

*Assume (1). Let $h = b g^{v} \in H$, for some $b \in B$ and $g \in G$. Then 
\begin{equation}
  h^{wv} h^{-1} = (b g^{v})^{wv} (b g^{v})^{-1}
  =
  b^{wv} b^{-1} (g^{vw} g^{-1})^{v} \in Z(H).
\end{equation}
Here we have used (1), the fact that $b \in Z(H)$, and the previous point twice.


As in the answer by OP, I am only using the fact that $G, H$ are groups, not necessarily finite, that $v, w$ are homomorphisms, and that $H = B G^{v}$ and $G = A H^{w}$, with $A \le Z(G)$ and $B \le Z(H)$.
