\begin{center}
\begin{figure}[h]
\begin{tikzpicture} [holdot/.style={circle,draw,fill=white,inner sep=1pt}]
\draw[thick,-latex] (-2,0) -- (6,0);
\draw[thick,-latex] (0,-1) -- (0,6);
\draw[very thick,gray!50!black] (-0.8,0.2) -- (3,2) to[out=45,in=50]
node[pos=0.5,above,font=\large]{$f(x)$} (5,4.5);
\end{tikzpicture}
\end{figure}
结果 :
我真正想要生产的东西:
答案1
给你!
\documentclass{article}
\usepackage{tikz,lipsum}
\begin{document}
\lipsum[1]
\begin{center}
\begin{tikzpicture} [holdot/.style={circle,draw,fill=white,inner sep=1.5pt}]
\draw[-latex] (-1,0) -- (5,0);
\draw[-latex] (0,-.5) -- (0,5);
\draw[thick,red] (-.8,.2)--(3,2) (3,2.2) node[holdot]{}--(5,4.5) node[pos=0.5,above left]{$f(x)$};
\end{tikzpicture}
\end{center}
\lipsum[10]
\end{document}