1. ## Drawing in latex

I am trying to construct a map.

X - - - -> Y where there is a f above the dotted line. Then a solid line down from the X to a Z with a h to the left center of the solid line, and then a diagonal solid line from Y to Z with a g in the center to the right of the solid line.

How can I set that up in LaTex?

2. ## Re: Drawing in latex

See these two pages for surveys of diagram-drawing facilities in LaTeX. The second TeX FAQ is generally awesome.

I personally like PGF/TikZ because of its impeccable quality and power (the author also wrote the Beamer package). It is able to draw almost any technical diagram (see examples). In TikZ, the following code

Code:
\begin{tikzpicture}[auto]
\node (X) at (0,0) {$X$};
\node (Y) at (3,0) {$Y$};
\node (Z) at (0,-2) {$Z$};
\draw[dashed,->] (X) -- node{$f$} (Y);
\draw[->] (Y) -- node{$g$} (Z);
\draw[->] (X) -- node[swap]{$h$} (Z);
\end{tikzpicture}
produces

Speaking of drawbacks, TikZ manual, though very clear, has over 700 pages. Also, the semantics of the language (e.g., options) is sometimes pretty involved.