Monday, 26 August 2013

tikz problem (non-continuous function)

tikz problem (non-continuous function)

I want to plot a function (x^3)/((x^2)-1) but it doesn't work.
\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}[domain=-5:5,smooth]
\draw[->] (-5,0) -- (5,0) node[right] {$x$};
\draw[->] (0,-5) -- (0,5) node[above] {$y$};
\draw [color=blue, thick] plot ({\x},{pow(\x,3)/(pow(\x,2)-1)});
\end{tikzpicture}
\end{document}
It does something like this. It should be non-continuous function, not this.

How to fix it? Thanks.

No comments:

Post a Comment