In a triangle $ABC$, right at $B$, $AB=a$. Through its barycenter $G$ draw $MN$ perpendicular to $AC$, such that $M$ and $N$ are on $BC$ and $AC$. If $GN=b$, calculate $GM$.
(Answer: $ \frac{a^2}{9b}$)
I tried to use the similarity of triangles but I didn't finish.
$\triangle CNM \sim \triangle CAB$
$\dfrac{CM}{AC}=\dfrac{b+c}{a}=\dfrac{CN}{BC}$
$GB = 2GO$
$BO=CO=AO$

EDIT – much simpler answer, original answer below.
Draw point $D$ on $AB$ such that $BD={1\over3}BA$. Line $GD$ is then parallel to $BC$: let $L$ be the point where it intersects the perpendicular from $B$ to $AC$, we have $BL=GM=c$.
If $K$ is the projection of $D$ onto $BL$, then $BK={1\over3}BH=GN=b$. In triangle $BDL$ we have then: $$ BD:BK=BL:BD,\quad \text{whence:}\quad c={a^2\over 9b}. $$
ORIGINAL ANSWER.
Drop perpendicular $BH$ onto $AC$. Note that $BH=3b$. Compute $AH=\sqrt{a^2-9b^2}$, $CH=9b^2/\sqrt{a^2-9b^2}$ and $$ OH={CH-AH\over2}={18b^2-a^2\over2\sqrt{a^2-9b^2}}. $$ We have then $HN={2\over3}OH$. Produce $$ to meet at $S$ the parallel to $$ passing through $B$. Triangle $$ is then similar to $$: from $=−=2−$, and $=$ we obtain $$ (2b-c):HN=BH:CH, $$ which gives: $$ c={a^2\over9b}. $$