37 lines
1.1 KiB
Plaintext
37 lines
1.1 KiB
Plaintext
\begin{tikzpicture}
|
|
|
|
\begin{axis}[
|
|
x=1cm,y=1cm,
|
|
axis lines=middle,
|
|
axis x line=middle,
|
|
axis y line=middle,
|
|
%enlarge x limits=0.15,
|
|
%enlarge y limits=0.15,
|
|
every axis x label/.style={at={(current axis.right of origin)},anchor=north east},
|
|
every axis y label/.style={at={(current axis.above origin)},anchor=north east},
|
|
xmin=-0.5,
|
|
xmax=6.,
|
|
ymin=-0.5,
|
|
ymax=5,
|
|
ytick={1,...,2},
|
|
xtick={3},
|
|
xlabel=$x$,
|
|
ylabel=$y$,
|
|
]
|
|
|
|
\addplot[domain=0.75:3, blue!80!black, line width=1,samples=50] {3/x};
|
|
\addplot[domain=3:5, blue!80!black, line width=1,samples=50] {x-1};
|
|
\addplot[color=blue!80!black, only marks, style={mark=*, fill=white}] coordinates {(3,2)};
|
|
\addplot[color=blue!80!black, only marks, style={mark=* }] coordinates {(3,1)};
|
|
|
|
\draw [dashed, draw=black] (axis cs: -0.05,1) -- (axis cs: 3,1);
|
|
\draw [dashed, draw=black] (axis cs: -0.05,2) -- (axis cs: 3,2);
|
|
\draw [dashed, draw=black] (axis cs: 3,-0.05) -- (axis cs: 3,2);
|
|
|
|
\node[] at (axis cs:4.5,4.5) {\footnotesize$y=\left\{\begin{array}{l}
|
|
\frac{3}{x} \text { für } 0<x \leq 3 \\
|
|
x-1 \text { für } x>3
|
|
\end{array}\right.$};
|
|
|
|
\end{axis}
|
|
\end{tikzpicture} |