7

I want to draw the following diagram:

enter image description here

I have limited idea about TikZ but I want to draw this picture with TikZ. I have tried to draw the figure but ultimately faied. My written code given here:

\documentclass{article}
\usepackage{tikz}
\begin{document}

\begin{tikzpicture}

\draw (0,0) ellipse  (49pt and 39pt);
\draw (0,1) to [out=90,in=190](0,-1);
\draw (0,1) to [out=180,in=195](0,-1);
\end{tikzpicture}

\end{document}  

Anyone can give an idea so that I can draw the picture?

1 Answers1

5

After adjusting the in and out values a little bit and adding appropriate styles and nodes, one can get something like the following.

If the two paths inside the ellipse should have more kinks like in your picture you will need to give more coordinates and more in and out options (or similar solutions) or for nicer outputs the hobby library or the smooth options …

Code

\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{decorations.markings}
\tikzset{
    Arrow/.style={
        decoration={
            name=markings,
            mark=at position .5 with \arrow{#1}
        },
        postaction=decorate
    },
    Arrow/.default=>
}
\begin{document}
\begin{tikzpicture}[
    auto,
    nodes={font=\scriptsize},
    every label/.append style={inner ysep=+1pt}
]
\draw (0,0) ellipse  (49pt and 39pt);
\path (60:49pt and 39pt) coordinate[label=above right:$x$];
\draw[Arrow]   (0,1) coordinate[label=above:$x_0$]
               to [out=-30,  in=45]  node {$f$} (0,-1)
               coordinate[label=below:$x_1$];
\draw[Arrow=<] (0,1) to [out=-150, in=135] node[swap] {$g$} (0,-1);
\end{tikzpicture}
\end{document}  

Output

enter image description here

Qrrbrbirlbel
  • 119,821