Préambule

Présentation

N'oubliez pas les fichiers *.h partagés. Recuperer aussi ceux du chapitre Dessiner : Fonction vectorielle 3D.

Animer

c01.c
Animer un vecteur tangent et normales unitaire
/* ------------------------------------ */
/*  Save as :   c01.c                   */
/* ------------------------------------ */
#include "x_ahfile.h"
#include       "fa.h"
/* ------------------------------------ */
 main(void)
{
double t=0;

 printf(" r(t) = f(t)i + g(t)j + h(t)k \n\n");
 printf(" With \n\n");
 printf(" f : t-> %s  \n", feq);
 printf(" g : t-> %s  \n", geq);
 printf(" h : t-> %s\n\n", heq);

printf("\n\n Open the file \"a_main.plt\" with Gnuplot."
       "\n\n Use the \"replot\" command of gnuplot.\n\n");

 for(;t<6.*PI;t+=.05)

     G_Curve_3d(i_time(0.,6.*PI,.01),
                f,g,h,
                Tf,Tg,Th,
                t);

 printf(" open the file \"a_main.plt\" with Gnuplot.\n\n"
        " Use the command replot of gnuplot         \n\n");

 return 0;
}

Le résultat.

Résultat dans gnuplot
Résultat dans gnuplot
Cet article est issu de Wikibooks. Le texte est sous licence Creative Commons - Attribution - Partage dans les Mêmes. Des conditions supplémentaires peuvent s'appliquer aux fichiers multimédias.