I'm trying to draw an automata as follows:
\begin{tikzpicture}[>=stealth',shorten >=1pt,auto,node distance=2.8cm]
\node[initial,state] (q1) {$1$};
\node[state] (q2) [right of=q1] {$2$};
\node[state] (q4) [below right of=q2] {$4$};
\node[state, accepting] (q3) [above right of=q4] {$3$};
\path[->] (q1) edge node {a} (q2);
\path[->] (q2) edge [bend left] node {b} (q3);
\path[->] (q3) edge [bend left] node {a} (q2);
\path[->] (q2) edge node {b} (q4);
\path[->] (q4) edge node {a} (q3);
\end{tikzpicture}
However, the bending seems to be "too much", and it interferes with the two arrows to/from q4. In addition, I'd like the labels on those two arrows to be on the other side of the arrow. Sadly I couldn't find how to do it online so I turned to this page.
