Using TIKZ - College of the Redwoods
Using TIKZ - College of the Redwoods
Using TIKZ - College of the Redwoods
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
Plotting Functions<br />
We’re now going to plot <strong>the</strong> graph <strong>of</strong> <strong>the</strong> function f (x) = x(x + 2)(x − 2).<br />
Open WorkshopFiles/workshop10.tex in TeXShop and compile.<br />
\ d o c u m e n t c l a s s { a r t i c l e }<br />
\ usepackage { t i k z }<br />
\ b e g i n { document }<br />
\ b e g i n { t i k z p i c t u r e }<br />
\ draw [ h e l p l i n e s ] (−5,−5) g r i d ( 5 , 5 ) ;<br />
\ draw [ t h i c k ,] ( −5 ,0) −−(5,0) node [ r i g h t ] {$ x $ } ;<br />
\ draw [ t h i c k ,] (0 , −5) −−(0,5) node [ above ] {$ y $ } ;<br />
\ draw [ t h i c k , b l u e ] p l o t (\ x , { \ x ∗(\ x+2) ∗(\ x −2) }) ;<br />
\ end { t i k z p i c t u r e }<br />
\ end { document }<br />
David Arnold (CR) <strong>Using</strong> <strong>TIKZ</strong> November 20, 2010 12 / 24