1234567891011121314151617181920212223242526272829303132333435363738394041 |
- \documentclass{article}
- \usepackage[pdftex,active,tightpage]{preview}
- \setlength\PreviewBorder{2mm}
- \usepackage{pgfplots}
- \usepackage{tikz}
- \usetikzlibrary{arrows, positioning, calc, intersections, decorations.markings}
-
- \begin{document}
- % Define this as a command to ensure that it is same in both cases
- \newcommand*{\ShowIntersection}[2]{
- \fill
- [name intersections={of=#1 and #2, name=i, total=\t}]
- [red, opacity=1, every node/.style={above left, black, opacity=1}]
- \foreach \s in {1,...,\t}{(i-\s) circle (2pt)
- node [above left] {\s}};
- }
- \begin{preview}
- \begin{tikzpicture}
- \begin{axis}[
- %width=15cm, height=15cm, % size of the image
- %xmin= 0, % start the diagram at this x-coordinate
- %xmax= 250, % end the diagram at this x-coordinate
- %ymin=-7, % start the diagram at this y-coordinate
- %ymax= 7, % end the diagram at this y-coordinate
- ylabel=y,
- xlabel=x,
- axis lines=left,
- tick style={draw=none},
- xticklabels={,,},
- yticklabels={,,}
- ]
- \addplot[name path global=a, domain=30:250, red, thick,samples=500]
- {-0.00192*x*x*x+0.85*x*x-121.92*x+5815.75};
- % {-226/117649*x*x*x+100005/117649*x*x-14343768/117649*x+684216906/117649};
- \end{axis}
- \end{tikzpicture}
- \end{preview}
- \end{document}
|