####################################################################################################################################### # # # G E N E R A T I O N D ' U N E V A R I E T E T R I M E N S I O N N E L L E T O R S A D E E # # P A R L A M E T H O D E D E S P R O J E C T O R S : # # # # # # Author of '$xiirs/.PROK.21.1.$U' : # # # # Jean-Francois Colonna (LACTAMME, 20050630095512). # # # ####################################################################################################################################### $Z setParam _____Torsade 2.0 $Z # Une valeur 1 pour '$_____Torsade' donne une variete de type "Mobius", alors que 2 donne # $Z # une variete orientable... # $Z setParam _____FacteurZ 1.5 $Z setParam _____Rayon 0.01 $Z setParam _____Rotation_OX 0.2 $Z setParam _____Rotation_OY 1.0 $Z setParam _____Rotation_OZ 0.0 $Z setParam _____Zoom 1.0 $Z setParam _____Grossissement 2.0 $Z SET Premiere=1 $Z SET Derniere=16 $Z Pal $c #include <stdio.h> $c $c extern double cos(); $c extern double sin(); $c $c #define N0 Premiere $c #define N Derniere $c $c int main() $c { $c int n; $c $c for (n=N0 ; n<=N ; n++) $c { $c double phi=((3.141592653589793)*((double)(n-N0)))/((double)(N-N0)); $c $c printf("$xci/polaire$X $c standard=FAUX $c amplificateur=1 translateur=0 $c alpha=1 beta=0 omega=1 phi=`calcul ($_____Torsade*%f)` $c Tx=0.5 Ty=0.5 $c R=$xTV/CHAMP$COORD_X.%04d $c $formatI\n" $c ,phi $c ,n $c ); $c printf("$xci/polaire$X $c standard=FAUX $c amplificateur=1 translateur=0 $c alpha=0 beta=1 omega=1 phi=`calcul ($_____Torsade*%f)` $c Tx=0.5 Ty=0.5 $c R=$xTV/CHAMP$COORD_Y.%04d $c $formatI\n" $c ,phi $c ,n $c ); $c printf("$xci/init$X $c standard=FAUX $c valeur=`calcul $_____FacteurZ*(%f)` $c R=$xTV/CHAMP$COORD_Z.%04d $c $formatI\n" $c ,-cos(2*phi) $c ,n $c ); $c printf("$xci/init$X $c standard=FAUX $c valeur=$_____Rayon $c R=$xTV/CHAMP.r.%04d $c $formatI\n" $c ,n $c ); $c } $c } $Z @ Zmax = $Derniere - $Premiere $Z $xci/acces_3D.11$X \ $Z A=$xTV/CHAMP$COORD_X. \ $Z premiere=$Premiere \ $Z zero=VRAI \ $Z R=$xTV/dCHAMP$COORD_X. \ $Z Zmax=$Zmax ValiderAxes=FAUX \ $Z $formatI $Z $xci/acces_3D.11$X \ $Z A=$xTV/CHAMP$COORD_Y. \ $Z premiere=$Premiere \ $Z zero=VRAI \ $Z R=$xTV/dCHAMP$COORD_Y. \ $Z Zmax=$Zmax ValiderAxes=FAUX \ $Z $formatI $Z $xci/acces_3D.11$X \ $Z A=$xTV/CHAMP$COORD_Z. \ $Z premiere=$Premiere \ $Z zero=VRAI \ $Z R=$xTV/dCHAMP$COORD_Z. \ $Z Zmax=$Zmax ValiderAxes=FAUX \ $Z $formatI $Z $xrs/project3D.11$X \ $Z np=1 \ $Z albumFx=$xTV/CHAMP$COORD_X. premiereFx=$Premiere \ $Z albumFy=$xTV/CHAMP$COORD_Y. premiereFy=$Premiere \ $Z albumFz=$xTV/CHAMP$COORD_Z. premiereFz=$Premiere \ $Z albumRAYON=$xTV/CHAMP.r. premiereR=$Premiere \ $Z ROTATION_OX=$_____Rotation_OX \ $Z ROTATION_OY=$_____Rotation_OY \ $Z ROTATION_OZ=$_____Rotation_OZ \ $Z ZOOM=$_____Zoom \ $Z pu=0.1 eu=80 dpu=40 \ $Z pv=0.1 ev=80 dpv=40 \ $Z pw=0.1 ew=40 dpw=80 \ $Z lignes_de_coordonnees=$_____Grossissement \ $Z Lz=100 \ $Z N_AU_CARRE=VRAI \ $Z pxx=0 pyy=0 pzz=0 \ $Z pxu=1 pyv=1 pzw=1 \ $Z bicubique=VRAI \ $Z R=$_____imageR \ $Z chiffres=0 \ $Z Zmax=$Zmax ValiderAxes=FAUX \ $Z $formatI