New in Wolfram
Mathematica
8: Enhanced 2D and 3D Graphics
◄
previous
|
next
►
Graphics & Visualization
Custom Arrowheads on Curved Arrows
Rotate a B-spline curve with custom arrowheads to create an atom symbol.
In[1]:=
X
Animate[Graphics[{EdgeForm[Black], Red, Disk[{0, 0}, .05], Black, Arrowheads[ Table[{0.02, p + t, Graphics[{EdgeForm[Black], Hue[2 t], Disk[]}]}, {p, {0, 0.5}}]], GeometricTransformation[ Arrow[BSplineCurve[{{-1, 0}, {0, -(1/4)}, {1, 0}, {0, 1/4}}, SplineDegree -> 3, SplineClosed -> True]], Table[RotationMatrix[(\[Theta] + 90 t) \[Degree]], {\[Theta], 0, 135, 45}]]}, PlotRange -> 2/3, ImageSize -> Medium], {t, 0, 0.5}]
Out[1]=
Play Animation
»
Stop Animation
»