Fichier cycloidespherique_01.jps — Modifié le 19 Mars 2008 à 23 h 05
%% d'apres un code original de Maxime Chupin et Manuel Luque
-2 2 setxrange
-2 2 setyrange
100 setxunit
10 6 12 SetCamPos
0 0 0 SetCamView
/ScreenDist .075 def
-10 10 setxrange3d
-3 3 setyrange3d
2 setlinejoin
/g {
3 dict begin
/t exch def
#rpn# (-2.065260000*Sin(t)+2.065260000*Cos(3*t)*Sin(t)+.8624533334*Cos(t)*Sin(3*t))
#rpn# (2.065260000*Cos(t)-2.065260000*Cos(3*t)*Cos(t)+.8624533334*Sin(3*t)*Sin(t))
#rpn# (2/3*Sin(1.668)*(1-Cos(3*t)))
end
} def
/g' { % derivee premiere
3 dict begin
/t exch def
#rpn# (-2.065260000*Cos(t)-7.058233333*Sin(3*t)*Sin(t)+4.652620000*Cos(3*t)*Cos(t))
#rpn# (-2.065260000*Sin(t)+7.058233333*Cos(t)*Sin(3*t)+4.652620000*Cos(3*t)*Sin(t))
#rpn# (2*Sin(1.668)*Sin(3*t))
end
} def
/g'' { % derivee seconde
3 dict begin
/t exch def
#rpn# (2.065260000*Sin(t)-25.82732000*Cos(3*t)*Sin(t)-21.01609333*Cos(t)*Sin(3*t))
#rpn# (-2.065260000*Cos(t)-21.01609333*Sin(3*t)*Sin(t)+25.82732000*Cos(3*t)*Cos(t))
#rpn# (6*Sin(1.668)*Cos(3*t))
end
} def
.1 setlinewidth
gris
% t_min t_max rayon_tube [resolution]
0 6.28 (g) .25 [360 12] newtube
dup [.1 .3] solidputhuecolors
drawsolid**