[Tex/LaTex] Writing on top of a long arrow

arrows

I want to make the arrow in the numerator longer, like the one in the denominator and write $x$ on top of it. I'm using the package mathtools.

\[
    H_{1}(K_1)=\frac{\textrm{ker}(R \xrightarrow{x} R)}{\textrm{im}(0 \longrightarrow R)} \cong \textrm{ker}(R \longrightarrow R)= \frac{R}{xR}.
\]

Best Answer

(memoir is unrelated, just my goto class)

\documentclass[a4paper]{memoir}
\usepackage{amsmath,amssymb}
\DeclareMathOperator\im{im}
\begin{document}
\[
H_1(K_1) = \frac{\ker(R\xrightarrow{x} R)}{\im(0\to R)}
\]
\end{document}
Related Question