Re: Error in example p. 35 of manual
<zulkifli <at> ee.its.ac.id>
2009-02-03 00:04:32 GMT
> Zulkifli
>
> with CVS version and including \usetikzpackage{intersections} it works for me:
>
> -----------------------
> \documentclass[11pt,a4paper]{article}
> \usepackage{tikz}
> \usetikzlibrary{intersections}
>
> \begin{document}
> \begin{tikzpicture}[scale=3]
> \clip (-2,-0.2) rectangle (2,0.8);
> \draw[step=.5cm,gray,very thin] (-1.4,-1.4) grid (1.4,1.4);
\filldraw[fill=green!20,draw=green!50!black] (0,0) -- (3mm,0mm)
> arc(0:30:3mm) -- cycle;
> \draw[->] (-1.5,0) -- (1.5,0) coordinate (x axis);
> \draw[->] (0,-1.5) -- (0,1.5) coordinate (y axis);
> \draw (0,0) circle (1cm);
> \draw[very thick,red] (30:1cm) -- node[left=1pt,fill=white] {$\sin
> \alpha$} (30:1cm |- x axis);
> \draw[very thick,blue] (30:1cm |- x axis) --
> node[below=2pt,fill=white] {$\cos \alpha$} (0,0);
> \path [name path=upward line] (1,0) -- (1,1);
> \path [name path=sloped line] (0,0) -- (30:1.5cm);
> \draw [name intersections={of=upward line and sloped line,
> by=t}][very thick,orange] (1,0) -- node
> [right=1pt,fill=white]{$\displaystyle \tan \alpha
> \color{black}=\frac{{\color{red}\sin \alpha}}{\color{blue}\cos
> \alpha}$} (t);
> \draw (0,0) -- (t);
> \foreach \x/\xtext in {-1, -0.5/-\frac{1}{2}, 1}
> \draw (\x cm,1pt) -- (\x cm,-1pt) node[anchor=north,fill=white]
> {$\xtext$};
> \foreach \y/\ytext in {-1, -0.5/-\frac{1}{2}, 0.5/\frac{1}{2}, 1}
> \draw (1pt,\y cm) -- (-1pt,\y cm) node[anchor=east,fill=white]
> {$\ytext$};
> \end{tikzpicture}
> \end{document}
> -------------------
> Regards,
>
> Ignasi
>
Thank you, it works now, but another error occurs from example CVS manual. But I
am not ask about it since it is CVS version.
Until now, I am still considering to learn tikz by reading manual and type the
examples. However, since there may be error from example in manual, I would like
to ask suggestions how to learn tikz reach the level of finishing all of the
tutorials.
Thank you in advance.
Regards,
Zulkifli
------------------------------------------------------------------------------
Create and Deploy Rich Internet Apps outside the browser with Adobe(R)AIR(TM)
software. With Adobe AIR, Ajax developers can use existing skills and code to
build responsive, highly engaging applications that combine the power of local
resources and data with the reach of the web. Download the Adobe AIR SDK and
Ajax docs to start building applications today-http://p.sf.net/sfu/adobe-com