TikZ package

From Micro and Nano Mechanics Group
Jump to navigation Jump to search

PGF/Tikz is a (La)TeX macro package for generating graphics. It comes with a user-friedly syntax layer called TikZ.

Nodes and Paths

Tikz node example.png

 \begin{tikzpicture}[node distance=2cm]
   \node (3) [draw,circle, fill=yellow] {};
   \node (0) at (0.2,-2) [draw,circle,fill=blue]{}; 
   \node (4) at (0,-1.8) [draw,circle,fill=red,semitransparent]{};
   \node (2) [draw,circle,fill=magenta, right of=3]{};
   \node (1) [draw,circle,fill=green, below of=2]{};
   \path[->] (0) edge (1);
   \path[->] (1) edge (2);
   \path[->] (2) edge (3);
   \path[->] (3) edge (4);
   \node (flux) at (1,-1) [] {$\Phi$};
 \end{tikzpicture}

source

Quick preview (KTikZ)