Retour

toupie.tex

Télécharger le fichier Fichier PDF
Image PNG
\documentclass{article}
\usepackage[dvipsnames,svgnames]{pstricks}
\usepackage{pst-solides3d}
 
\begin{document}
\pagestyle{empty}
 
\begin{pspicture}(-6,-5)(6,7)
\psframe(-6,-5)(6,7)
\psset[pst-solides3d]{viewpoint=20 20 10 rtp2xyz,Decran=20,lightsrc=10 15 0}
% Parametric Surfaces
\psSolid[object=grille,base=-3 3 -3 3,action=draw,linecolor=red](0,0,-3)
\defFunction[algebraic]{toupie}(u,v)
   {(abs(u)-1)^2 * cos(v)}
   {(abs(u)-1)^2 * sin(v)}
   {u}
\psSolid[object=surfaceparametree,linecolor={[cmyk]{1,0,1,0.5}},
   base=1 -1 0 2 pi mul,incolor=green!50,fillcolor=yellow!50,
   function=toupie,linewidth=0.5\pslinewidth,unit=3,
   ngrid=30]%
\gridIIID[Zmin=-3,Zmax=3](-3,3)(-3,3)
\end{pspicture}
 
\end{document}