# How to draw with tikz a topological continuity diagram?

I´d like to draw with package tikz something like this:

• Welcome to TeX.SX! Please help us help you and add a minimal working example (MWE) that illustrates your problem / what do you have so far. Reproducing the problem and finding out what the issue is will be much easier when we see compilable code, starting with \documentclass{...} and ending with \end{document}. Note this is Q&A site, not a please do this for me service. – albert Oct 30 '18 at 18:42

There are countless examples of this type on this site. However, it is quicker for me to write a quick code than searching for them. Nonetheless I'd like to encourage you to try on your own, you'll see it's more fun. Especially since, once you are not a newcomer any more, users will be more reluctant to answer such questions for you.

\documentclass[tikz,border=3.14mm]{standalone}
\usetikzlibrary{shapes.geometric,positioning}
\begin{document}
\begin{tikzpicture}[thick]
\node[ellipse,draw,minimum width=2cm,minimum height=4cm,label=below:$X$] (X) {};
\node[ellipse,draw,minimum width=2cm,minimum height=4cm,right=3cm of X,label=below:$Y$]
(Y){};
\node[dashed,draw] (f) at (X.center) {$f^{-1}(U)$};
\node[circle,dashed,draw,minimum size=1cm] (U) at (Y.center) {$U$};
\draw[-latex] (X) -- (Y) node[midway,above]{$f$};
\draw[-latex] (U) to[bend left] (f);
\end{tikzpicture}
\end{document}