summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/generic/pst-solides3d/doc/par-anneaux.tex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/doc/generic/pst-solides3d/doc/par-anneaux.tex')
-rw-r--r--Master/texmf-dist/doc/generic/pst-solides3d/doc/par-anneaux.tex452
1 files changed, 452 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/generic/pst-solides3d/doc/par-anneaux.tex b/Master/texmf-dist/doc/generic/pst-solides3d/doc/par-anneaux.tex
new file mode 100644
index 00000000000..d2f097f82eb
--- /dev/null
+++ b/Master/texmf-dist/doc/generic/pst-solides3d/doc/par-anneaux.tex
@@ -0,0 +1,452 @@
+
+\section {Solide anneau}
+
+Cette partie traite des anneaux cylindriques. Dans la commande
+\verb+\psSolid+, cet objet est tracé avec l'option :
+\verb+[object=anneau]+, dont il faut fixer
+3 paramètres :
+\begin{itemize}
+ \item le rayon intérieur \verb+[r=1.5]+ (valeur par défaut) ;
+ \item le rayon extérieur \verb+[R=4]+ (valeur par défaut)
+ \item la hauteur \verb+[h=6]+ (valeur par défaut).
+\end{itemize}
+
+En option, l'argument \verb+ngrid+ permet de définir le nombre de
+sections utilisées pour faire une rotation complète de
+$360$~degrés. Sa valeur par défaut est $24$.
+
+La section de l'anneau dont la forme \texttt{rectangulaire} a été
+choisie par défaut, peut être redessinée par l'utilisateur.
+Nous allons détailler différents exemples de section.
+
+\subsection {Commande pré-définie~: l'anneau à section rectangulaire.}
+
+Cette section est définie dans le plan $Oyz$, elle est paramétrée par le
+triplet $(r, R, h)$. Les valeurs du rayon
+extérieur $R$, du rayon intérieur $r$ et de la hauteur $h$ sont
+passées dans les options de \verb+\psSolid+. Par défaut, on a donc un
+anneau à section rectangulaire variable, et la définition se fait au
+moment de la transmission des valeurs pour $(r, R, h)$ dans les
+options de \verb+\psSolid+.
+
+Si l'utilisateur redéfinit la macro \TeX {} \verb+\Section+ avec des
+valeurs numériques plutôt que les paramètres $r$, $R$ et $h$, alors
+l'anneau n'est plus variable et il n'est plus besoin de transmettre
+des valeurs pour $r$, $R$, et $h$ dans les options de \verb+\psSolid+.
+
+\begin{minipage}{0.45\linewidth}
+\begin{verbatim}
+\newcommand\Section{%
+% y z
+ R h 2 div neg % sommet 1
+ % S1 (R,-h/2)
+ R h 2 div % sommet 2
+ % S2 (r,h/2)
+ r h 2 div % sommet 3
+ % S3 (r,h/2)
+ r h 2 div neg % sommet 4
+ % S4 (r,-h/2)
+ }
+\end{verbatim}
+\end{minipage}
+\hfill
+\begin{minipage}{0.45\linewidth}
+\psset{unit=0.5}
+\begin{pspicture}(-5,-3)(5,3)
+\pstVerb{/R 4 def /r 2 def /h 2 def}%
+\newcommand\RectangularSection{%
+ \pspolygon[fillstyle=vlines,linewidth=2\pslinewidth]%
+ (!R h 2 div neg)(!R h 2 div)(!r h 2 div)(!r h 2 div neg)}
+\rput(0,0){\RectangularSection}\rput(-6,0){\RectangularSection}
+\psline(-2,1)(2,1)\psline(-2,-1)(2,-1)
+\psline[linestyle=dashed,dash=1 0.2 0.05 0.2]{->}(0,-3)(0,3)
+\psline[linestyle=dashed]{->}(-4,0)(4.2,0)
+\uput[u](0,3){$z$}\uput[r](4.1,0){$y$}\uput[dl](0,0){$O$}
+\psline{->}(0,1.5)(2,1.5)\uput[u](1,1.5){$r$}
+\psline{->}(0,2.5)(4,2.5)\uput[u](2,2.5){$R$}
+\psline{<->}(5,-1)(5,1)\uput[r](5,0){$h$}
+\uput[dr](!R h 2 div neg){1}
+\uput[ur](!R h 2 div ){2}
+\uput[ul](!r h 2 div ){3}
+\uput[dl](!r h 2 div neg){4}
+\end{pspicture}
+\end{minipage}
+%
+\bgroup\centering
+%%
+\psset{unit=0.5}
+\begin{pspicture}(-5,-4)(5,4)
+\psframe(-5,-4)(5,4)
+\psset[pst-solides3d]{viewpoint=50 20 40 rtp2xyz,Decran=25,lightsrc=10 20 20}
+\psSolid[object=anneau,fillcolor=cyan,h=3,R=8,r=6,ngrid=4,RotX=10](0,0,0)
+\end{pspicture}
+%%
+\begin{pspicture}(-5,-4)(5,4)
+\psframe(-5,-4)(5,4)
+\psset[pst-solides3d]{viewpoint=50 -20 -40 rtp2xyz,Decran=25,lightsrc=-10 -20 -20}
+\psSolid[object=anneau,fillcolor=yellow,h=3,R=8,r=6,RotX=90,RotZ=10](0,0,0)
+\end{pspicture}
+\par\egroup
+%% \begin{verbatim}
+%% \begin{pspicture}(-5,-6)(5,6)
+%% \psframe(-5,-4)(5,4)
+%% \psset[pst-solides3d]{viewpoint=50 20 40 rtp2xyz,%
+%% Decran=25,lightsrc=10 20 20}
+%% \psSolid[object=anneau,fillcolor=cyan,h=3,R=8,r=6,ngrid=4,RotX=10](0,0,0)
+%% \end{pspicture}
+%% %%
+%% \begin{pspicture}(-5,-6)(5,5)
+%% \psframe(-5,-4)(5,4)
+%% \psset[pst-solides3d]{viewpoint=50 -20 -40 rtp2xyz,%
+%% Decran=25,lightsrc=-10 -20 -20}
+%% \psSolid[object=anneau,fillcolor=yellow,h=3,R=8,r=6,RotX=90,RotZ=10](0,0,0)
+%% \end{pspicture}
+%% \end{verbatim}
+\begin{verbatim}
+\psSolid[object=anneau,fillcolor=cyan,h=3,R=8,r=6,ngrid=4,RotX=10](0,0,0)
+\psSolid[object=anneau,fillcolor=yellow,h=3,R=8,r=6,RotX=90,RotZ=10](0,0,0)
+\end{verbatim}
+
+\subsection {Un simple anneau à section triangulaire}
+
+Ci-dessous un anneau très simple, à section triangulaire fixe. La
+section est définie par la donnée des $3$~points $(6, -2)$, (10, 0)
+et $(6, 2)$ dans l'option \texttt{section} de \verb+\psSolid+.
+
+\begin{center}
+\begin{minipage}{0.45\linewidth}
+\psset{unit=0.5}
+\begin{pspicture}(-5,-6)(5,6)
+\psframe(-5,-4)(5,4)
+\psset[pst-solides3d]{
+ viewpoint=50 20 40 rtp2xyz,Decran=25,
+ lightsrc=10 20 20}
+\psSolid[object=anneau,
+ section=6 -2 10 0 6 2,
+ fillcolor=cyan,RotX=10]%
+\end{pspicture}
+\end{minipage}
+%%
+\begin{minipage}{0.45\linewidth}
+\begin{verbatim}
+\psset{unit=0.5}
+\begin{pspicture}(-5,-6)(5,6)
+\psframe(-5,-4)(5,4)
+\psset[pst-solides3d]{
+ viewpoint=50 20 40 rtp2xyz,Decran=25,
+ lightsrc=10 20 20}
+\psSolid[object=anneau,
+ section=6 -2 10 0 6 2,
+ fillcolor=cyan,RotX=10]%
+\end{pspicture}
+\end{verbatim}
+\end{minipage}
+\end{center}
+
+%\newpage
+
+\subsection {Un anneau variable à section triangulaire}
+
+\newcommand\SectionTriangulaire{
+ R h 2 div neg % sommet 1
+ R r add 2 div h 2 div % sommet 2
+ r h 2 div neg % sommet 3
+}
+
+\begin{minipage}{0.45\linewidth}
+\begin{verbatim}
+\newcommand\SectionTriangulaire{
+% y <----z---->
+ R h 2 div neg
+ % S1 (R,-h/2)
+ R r add 2 div h 2 div
+ % S2 ((R+r)/2,h/2)
+ r h 2 div neg
+ % S3 (r,-h/2)
+}
+\end{verbatim}
+\end{minipage}
+\hfill
+\begin{minipage}{0.45\linewidth}
+\psset{unit=0.5}
+\begin{pspicture}(-5,-3)(5,3)
+%\psgrid
+\pstVerb{/R 4 def /r 2 def /h 2 def}%
+\newcommand\TriangularSection{%
+ \pspolygon[fillstyle=vlines,linewidth=2\pslinewidth]%
+ (!R h 2 div neg)(!R r add 2 div h 2 div)(!r h 2 div neg)}
+\rput(0,0){\TriangularSection}\rput(-6,0){\TriangularSection}
+\psline(-3,1)(3,1)\psline(-4,-1)(4,-1)
+\psline[linestyle=dashed,dash=1 0.2 0.05 0.2]{->}(0,-3)(0,3)
+\uput[u](0,3){$z$}\uput[r](4.1,0){$y$}\uput[dl](0,0){$O$}
+\psline[linestyle=dashed](2,-1)(2,1.5)
+\psline[linestyle=dashed](4,-1)(4,2.5)
+\psline[linestyle=dashed]{->}(-4,0)(4.2,0)
+\psline{->}(0,1.5)(2,1.5)\uput[u](1,1.5){$r$}
+\psline{->}(0,2.5)(4,2.5)\uput[u](2,2.5){$R$}
+\psline{<->}(5,-1)(5,1)\uput[r](5,0){$h$}
+\uput[dr](!R h 2 div neg){1}
+\uput[u](!R r add 2 div h 2 div){2}
+\uput[dl](!r h 2 div neg){3}
+\end{pspicture}
+\end{minipage}
+\begin{center}
+%%
+\psset{unit=0.5}
+\begin{pspicture}(-5,-6)(5,6)
+\psframe(-5,-4)(5,4)
+\psset[pst-solides3d]{viewpoint=50 20 40 rtp2xyz,Decran=25,lightsrc=10 20 20}
+\psSolid[object=anneau,section=\SectionTriangulaire,fillcolor=cyan,h=3,R=8,r=4,RotX=10]%
+\end{pspicture}
+%%
+\begin{pspicture}(-5,-6)(5,5)
+\psframe(-5,-4)(5,4)
+\psset[pst-solides3d]{viewpoint=50 -20 -40 rtp2xyz,Decran=25,lightsrc=-10 -20 -20}
+\psSolid[object=anneau,section=\SectionTriangulaire,fillcolor=yellow,h=3,R=8,r=4,RotX=-90,RotZ=10]%
+\end{pspicture}
+\end{center}
+%% \begin{verbatim}
+%% \begin{pspicture}(-5,-6)(5,6)
+%% \psframe(-5,-4)(5,4)
+%% \psset[pst-solides3d]{viewpoint=50 20 40 rtp2xyz,%
+%% Decran=25,lightsrc=10 20 20}
+%% \psSolid[object=anneau,section=\SectionTriangulaire,%
+%% fillcolor=cyan,h=3,R=8,r=4,RotX=10](0,0,0)
+%% \end{pspicture}
+%% %%
+%% \begin{pspicture}(-5,-6)(5,5)
+%% \psframe(-5,-4)(5,4)
+%% \psset[pst-solides3d]{viewpoint=50 -20 -40 rtp2xyz,%
+%% Decran=25,lightsrc=-10 -20 -20}
+%% \psSolid[object=anneau,section=\SectionTriangulaire,%
+%% fillcolor=yellow,h=3,R=8,r=4,RotX=-90,RotZ=10](0,0,0)
+%% \end{pspicture}
+%% \end{verbatim}
+\begin{verbatim}
+\psSolid[object=anneau,section=\SectionTriangulaire,%
+ fillcolor=cyan,h=3,R=8,r=4,RotX=10](0,0,0)
+%%
+\psSolid[object=anneau,section=\SectionTriangulaire,%
+ fillcolor=yellow,h=3,R=8,r=4,RotX=-90,RotZ=10](0,0,0)
+\end{verbatim}
+
+%%\newpage
+
+\newcommand\SectionPneu{
+ /m {90 4 div} bind def
+ /Scos {m cos 2 m mul cos add 3 m mul cos add} bind def
+ /Z0 {h 4 div} bind def
+ /c {Z0 Scos div} bind def
+ /Z1 {Z0 c m cos mul add} bind def
+ /Z2 {Z1 c m 2 mul cos mul add} bind def
+ /R1 {R c m sin mul sub} bind def
+ /R2 {R1 c m 2 mul sin mul sub} bind def
+ /R3 {R2 c m 3 mul sin mul sub} bind def
+ R h 4 div neg % 1
+ R h 4 div % 2
+ R1 Z1 % 3
+ R2 Z2 % 4
+ R3 h 2 div % 5
+ r h 2 div % 6
+ r h 2 div neg % 7
+ R3 h 2 div neg % 8
+ R2 Z2 neg % 9
+ R1 Z1 neg % 10
+ }
+
+\subsection {L'anneau à section ``pneu'' : anneau cylindrique à arêtes chanfreinées.}
+
+\begin{minipage}{0.45\linewidth}
+{\small
+\begin{verbatim}
+\renewcommand\SectionPneu{
+ /m {90 4 div} bind def
+ /Scos {m cos 2 m mul cos add 3 m mul cos add} bind def
+ /Z0 {h 4 div} bind def
+ /c {Z0 Scos div} bind def
+ /Z1 {Z0 c m cos mul add} bind def
+ /Z2 {Z1 c m 2 mul cos mul add} bind def
+ /R1 {R c m sin mul sub} bind def
+ /R2 {R1 c m 2 mul sin mul sub} bind def
+ /R3 {R2 c m 3 mul sin mul sub} bind def
+ R h 4 div neg % 1
+ R h 4 div % 2
+ R1 Z1 % 3
+ R2 Z2 % 4
+ R3 h 2 div % 5
+ r h 2 div % 6
+ r h 2 div neg % 7
+ R3 h 2 div neg % 8
+ R2 Z2 neg % 9
+ R1 Z1 neg % 10
+ }
+\end{verbatim}}
+\end{minipage}
+\hfill
+\begin{minipage}{0.45\linewidth}
+%\psset{unit=0.65}
+\begin{pspicture}(-2,-3)(5,6)
+%\psgrid
+\pstVerb{/R 4 def /r 2 def /h 2 def}%
+\pstVerb{/m {90 4 div} bind def
+ /Scos {m cos 2 m mul cos add 3 m mul cos add} bind def
+ /Z0 {h 4 div} bind def
+ /c {Z0 Scos div} bind def
+ /Z1 {Z0 c m cos mul add} bind def
+ /Z2 {Z1 c m 2 mul cos mul add} bind def
+ /R1 {R c m sin mul sub} bind def
+ /R2 {R1 c m 2 mul sin mul sub} bind def
+ /R3 {R2 c m 3 mul sin mul sub} bind def}%
+\pnode(!R h 4 div neg){S1}
+\pnode(!R h 4 div){S2}
+\pnode(!R1 Z1){S3}
+\pnode(!R2 Z2){S4}
+\pnode(!R3 h 2 div){S5}
+\pnode(!r h 2 div){S6}
+\pnode(!r h 2 div neg){S7}
+\pnode(!R3 h 2 div neg){S8}
+\pnode(!R2 Z2 neg){S9}
+\pnode(!R1 Z1 neg){S10}
+\newcommand\pneuSection{\pspolygon[fillstyle=vlines,linewidth=2\pslinewidth]%
+ (S1)(S2)(S3)(S4)(S5)(S6)(S7)(S8)(S9)(S10)}
+\rput(0,0){\pneuSection}\rput{180}{\pspolygon[fillstyle=vlines,linewidth=2\pslinewidth]%
+ (!R h 4 div neg)(!R h 4 div)(!R1 Z1)(!R2 Z2)(!R3 h 2 div)(!r h 2 div)(!r h 2 div neg)(!R3 h 2 div neg)(!R2 Z2 neg)(!R1 Z1 neg)}
+\psline(-3,1)(3,1)\psline(-3,-1)(3,-1)
+\psline[linestyle=dashed,dash=1 0.2 0.05 0.2]{->}(0,-3)(0,3)
+\uput[u](0,3){$z$}\uput[r](4.1,0){$y$}\uput[dl](0,0){$O$}
+\psline[linestyle=dashed](2,-1)(2,1.5)
+\psline[linestyle=dashed](4,-1)(4,2.5)
+\psline[linestyle=dashed]{->}(-4,0)(4.2,0)
+\psline{->}(0,1.5)(2,1.5)\uput[u](1,1.5){$r$}
+\psline{->}(0,2.5)(4,2.5)\uput[u](2,2.5){$R$}
+\psline{<->}(5,-1)(5,1)\uput[r](5,0){$h$}
+\uput[r](S1){1}
+\uput[r](S2){2}
+\uput[u](S3){3}
+\uput[u](S4){4}
+\uput[u](S5){5}
+\uput[ul](S6){6}
+\uput[dl](S7){7}
+\uput[dl](S8){8}
+\uput[dr](S9){9}
+\uput[r](S10){10}
+\psdots[linecolor=red](S1)(S2)(S3)(S4)(S5)(S6)(S7)(S8)(S9)(S10)
+\end{pspicture}
+\end{minipage}
+
+%\iffalse
+\begin{center}
+\psset{unit=0.7}
+\begin{pspicture}(-5,-5)(5,4)
+\psframe(-5,-4)(5,4)
+\psset[pst-solides3d]{viewpoint=50 20 40 rtp2xyz,Decran=25,lightsrc=10 20 20}
+\psSolid[object=anneau,section=\SectionPneu,fillcolor=cyan,h=3,R=8,r=4,RotX=10]%
+\end{pspicture}
+%%
+\begin{pspicture}(-5,-5)(5,4)
+\psframe(-5,-4)(5,4)
+\psset[pst-solides3d]{viewpoint=50 -20 -40 rtp2xyz,Decran=25,lightsrc=-10 -20 -20}
+\psSolid[object=anneau,section=\SectionPneu,fillcolor=yellow,h=3,R=8,r=4,RotX=-90,RotZ=10]%
+\end{pspicture}
+\end{center}
+%%
+\begin{gbar}
+\begin{verbatim}
+\psSolid[object=anneau,section=\SectionPneu,%
+ fillcolor=cyan,h=3,R=8,r=4,RotX=10](0,0,0)
+\psSolid[object=anneau,section=\SectionPneu,%
+ fillcolor=yellow,h=3,R=8,r=4,RotX=-90,RotZ=10]%
+\end{verbatim}
+\end{gbar}
+%\fi
+\newpage
+
+\subsection{Bobine vide}
+
+\newcommand\SectionBobine{
+ r h 2 div % 1
+ r h 2 div neg % 2
+ R h 2 div neg % 3
+ R h 3 div neg % 4
+ R h 4 div sub h 3 div neg % 5
+ R h 4 div sub h 3 div % 6
+ R h 3 div % 7
+ R h 2 div % 8
+ }
+
+\begin{minipage}{0.45\linewidth}
+\begin{verbatim}
+\newcommand\SectionBobine{
+ r h 2 div % 1
+ r h 2 div neg % 2
+ R h 2 div neg % 3
+ R h 3 div neg % 4
+ R h 4 div sub h 3 div neg % 5
+ R h 4 div sub h 3 div % 6
+ R h 3 div % 7
+ R h 2 div % 8
+ }
+\end{verbatim}
+\end{minipage}
+\hfill
+\begin{minipage}{0.45\linewidth}
+\begin{pspicture}(-2,-2)(5,2)
+\pstVerb{/RB 4 def /rB 2 def /hB 3 def}%
+\pnode(!rB hB 2 div){S1}
+\pnode(!rB hB 2 div neg){S2}
+\pnode(!RB hB 2 div neg){S3}
+\pnode(!RB hB 3 div neg){S4}
+\pnode(!RB hB 4 div sub hB 3 div neg){S5}
+\pnode(!RB hB 4 div sub hB 3 div){S6}
+\pnode(!RB hB 3 div){S7}
+\pnode(!RB hB 2 div){S8}
+\newcommand\pneuSection{\pspolygon[fillstyle=vlines,linewidth=2\pslinewidth]%
+ (S1)(S2)(S3)(S4)(S5)(S6)(S7)(S8)}
+\rput(0,0){\pneuSection}\rput{180}{\pspolygon[fillstyle=vlines,linewidth=2\pslinewidth]%
+ (!rB hB 2 div)(!rB hB 2 div neg)(!RB hB 2 div neg)(!RB hB 3 div neg)(!RB hB 4 div sub hB 3 div neg)(!RB hB 4 div sub hB 3 div)(!RB hB 3 div)(!RB hB 2 div)}
+\psline(-3,1.5)(3,1.5)\psline(-3,-1.5)(3,-1.5)
+\psline[linestyle=dashed,dash=1 0.2 0.05 0.2]{->}(0,-3)(0,3)
+\uput[u](0,3){$z$}\uput[r](4.1,0){$y$}\uput[dl](0,0){$O$}
+\psline[linestyle=dashed](2,-1)(2,1.5)
+\psline[linestyle=dashed](4,-1)(4,2.5)
+\psline[linestyle=dashed](-4,-1)(4,-1)
+\psline[linestyle=dashed](-4,1)(4,1)
+\psline[linestyle=dashed]{->}(-4,0)(4.2,0)
+\psline{->}(0,1.8)(2,1.8)\uput[u](1,1.8){$r$}
+\psline{->}(0,2.5)(4,2.5)\uput[u](2,2.5){$R$}
+\psline{<->}(5,-1.5)(5,1.5)\uput[r](5,0){$h$}
+\uput[u](S1){1}
+\uput[d](S2){2}
+\uput[d](S3){3}
+\uput[r](S4){4}
+\uput[ur](S5){5}
+\uput[dr](S6){6}
+\uput[r](S7){7}
+\uput[r](S8){8}
+\psdots[linecolor=red](S1)(S2)(S3)(S4)(S5)(S6)(S7)(S8)
+\end{pspicture}
+\end{minipage}
+\begin{center}
+\begin{pspicture}(-5,-6)(5,5)
+\psframe*[linecolor=blue!50](-5,-5)(5,4)
+\psset[pst-solides3d]{viewpoint=70 40 10 rtp2xyz,Decran=25,lightsrc=0 30 100}
+\psSolid[object=grille,base=-15 15 -15 15,fillcolor=yellow!30!black!10](0,0,-8)
+%\psSolid[object=prisme,h=2,base=-15 1 -15 -1 15 -1 15 1](0,0,-8)
+\psSolid[object=anneau,section=\SectionBobine,fillcolor=gray!50,h=6,R=8,r=4,RotX=90,linecolor=gray]%
+\end{pspicture}
+\end{center}
+\begin{gbar}
+\begin{verbatim}
+\psSolid[object=grille,base=-15 15 -15 15,fillcolor=yellow!30](0,0,-8)
+\psSolid[object=anneau,section=\SectionBobine,%
+ fillcolor=gray!50,h=6,R=8,r=4,RotX=90,linecolor=gray]%
+\end{verbatim}
+\end{gbar}
+
+
+\subsection{D'autres anneaux}
+Trois autres exemples sont disponibles sur la page :
+
+\centerline{\url{http://syracuse.eu.org/lab/bpst/pst-solides3d/anneaux}}
+
+