2017-11-13 4 views
0

Sie haben eine Idee, warum Latex die falsche Funktion plottet?Latex-Plot falsch Grafik

Diese meine Funktion ist:

 \draw [scale=0.5,domain=-3:3,smooth,variable=\x] plot (\x,0.5*\x^4 - 3*\x^2+ 4) node[right] {$f(x)=0.5*x^4 - 3*x^2 + 4$}; 

und das ist das Ergebnis: Latex Graph

Aber ist sollte wie folgt aussehen: Right Graph

Danke

Antwort

0

In tikz, Klammern sind erforderlich, um negative Zahlen richtig zu quadrieren.

\draw [scale=0.5,domain=-3:3,smooth,variable=\x] plot (\x,{0.5*(\x)^4 - 3*(\x)^2+ 4}) node[right] {$f(x)=0.5*x^4 - 3*x^2 + 4$}; 

sollte diese produzieren, was you wanted.