This is my code :
\begin{document}
Formally, a streaming string transducer is a 8-tuple $(Q,\Sigma_1,\Sigma_2,X,F,\delta,\gamma,q_0)$ machine, where
$Q$ is a finite set of states, $\Sigma_1$ is a finite set of input symbols, $\Sigma_2$ is a finite set of output symbols,
$X$ is a finite set of string variables, $F$ is a partial output function from $Q$ to $(\Sigma_2 \cup X)^*$ with constraint of copyless assignment,
$\delta$ is a state transition function from $(Q \times \Sigma_1)$ to $Q$,
$\gamma$ is a variable update function from $(Q \times \Sigma_1 \times X)$ to $(\Sigma_2 \cup X)^*$ using copyless assignments and $q_0 \in Q$ is an initial state.
\begin{figure}
\begin{tikzpicture}[>=stealth',shorten >=1pt,auto,node distance=5 cm, scale = 0.5, transform shape]
% \tikzstyle{every state}=[fill=white,draw=none,text=black]
\node[initial,state] (A) {$s_0$};
\node[state] (B) [right of=A] {$s_1$};
\path[->] (A) edge [bend left] node [align=center] {$a \rightarrow$ $[x = x.a, y = a.y]$\\$b \rightarrow$ $[x = x.b, y = b.y]$} (B)
(B) edge [bend left] node [align=center] {$a \rightarrow$ $[x = x.a, y = a.y]$\\$b \rightarrow$ $[x = x.b, y = b.y]$} (A);
\end{tikzpicture}
\caption{An example of SST}
\end{figure}
\begin{tikzpicture}[>=stealth',shorten >=1pt,auto,node distance=5 cm, scale = 0.5, transform shape]
% \tikzstyle{every state}=[fill=white,draw=none,text=black]
\node[initial,state] (A) {$s_0$};
\node[state] (B) [right of=A] {$s_1$};
\path[->] (A) edge [bend left] node [align=center] {$a \rightarrow$ $[x = x.a, y = a.y]$\\$b \rightarrow$ $[x = x.b, y = b.y]$} (B)
(B) edge [bend left] node [align=center] {$a \rightarrow$ $[x = x.a, y = a.y]$\\$b \rightarrow$ $[x = x.b, y = b.y]$} (A);
\end{tikzpicture}
The semantics of a DSST is defined in terms of the summary of a computation of a DSST. Summaries are of the form
$(q, s)$ where $q$ is a state and $s$ is valuation from $X$ to $\Sigma_2^*$ that can be extended to a valuation from $(\Sigma_2 \cup X)^*$ to
$\Sigma_2^*$. Initially each variable maps to the empty string. The transition function is defined by
$\psi((q,s),a) = (\delta(q,a), s')$ and for each variable $x$, $s'(x)$ = $s(\gamma(q,a,x))$. For an input
string $w \in \Sigma_1^*$, if $\psi^*((q_0,s_0),w) = (q, s)$, then if $F(q)$ is defined then output string will
be $s(F(q))$ otherwise it will be undefined.
\end{document}

So how do I put the content next to tikzpicture?




wrapfigpackage. – Spike Jun 16 '12 at 13:38