I'm trying to build a curved edge from s to a named x and a curved edge from s to b named y.
Beside the problem to >>curve<< them properly i want to give them a background like in this question or in this picture
.
\documentclass[a4paper,10pt]{article}
\usepackage{tikz}
\usetikzlibrary{automata,positioning,arrows,matrix,backgrounds}
\begin{document}
\begin{tikzpicture} [->,>=stealth',shorten >=1pt,auto,node distance=2.5cm,thick,main node/.style={circle,fill=gray!25,draw,font=\sffamily\Large\bfseries}]
\node[main node] (1) {$s$};
\node[main node] (2) [below of=1] {a};
\node[main node] (3) [ right of=2] {b};
\node[main node] (4) [below of=2] {$t$};
\path[every node/.style={font=\sffamily\small}]
(2) edge [bend left=50] node {$r^{-1}$} (3)
(3) edge [bend left=50,dashed] node {$r$} (2);
\draw (1) .. controls +(1, -1) and +(-1, 1) .. (2) node[midway,above left] {$x$};
\draw (1) [dashed] .. controls (1, 2) and (2,0) .. (3) node[midway,right] {$y$};
% \draw background here ???!
\end{tikzpicture}
\end{document}
i tried many things like in the linked question but can't get a good solution. any advice?
in the end it should like like in this picture:
![][3]
