[Tex/LaTex] Double arrow for inline diagram

arrowsdiagramstikz-pgf

I want to make a diagram like A--->B, but there are two arrows, one written f_1 and another with f_2.

I tried \stackrel, but this gives arrows with different sizes.

If using \mathop{}_{under}^{over}, then the vertical separation is too large.

I also tried tikz, but the height position does not match the inline text.

Edit:

My tikz example code

\textbf{cokernel} of
  \begin{tikzpicture}
  \node (a) at (0,0){$A$};
  \node (b) at (1.5,0){$X$};
  \path[->]
  ([yshift=2pt]a.east)edge node[above]{$f_1$}([yshift=2pt]b.west)
  ([yshift=-2pt]a.east)edge node[below]{$f_2$}([yshift=-2pt]b.west);
  \end{tikzpicture}

Effect:

Effect:

And no matter how I adjust the y-position of node (a),(b), it just does not move to the right place.

Best Answer

Here is a solution using xy. If you don't need tikz...

\documentclass{report}
\usepackage[all]{xy}

\begin{document}
\textbf{cokernel} of $\xymatrix{A\ar@<3pt>[r]^{f_1} \ar@<-3pt>[r]_{f_2} & X}$
\end{document}

enter image description here

If you don't like that arrow tips you can change it using \xyoption{tips} on preamble (or \usepackage[all,cmtips]{xy} as suggested by @egreg) and then change the arrow tip with

\SelectTips{cm}{10}$\xymatrix{A\ar@<3pt>[r]^{f_1} \ar@<-3pt>[r]_{f_2} & X}$

where cm means Computer Modern. You also can use lu or eu. See the results

enter image description here enter image description here enter image description here