Aller au contenu

Mathc initiation/a323

Un livre de Wikilivres.


Sommaire


Installer et compiler ces fichiers dans votre répertoire de travail.


c00a3.c
/* ---------------------------------- */
/* save as c00a3.c                    */
/* ---------------------------------- */
#include "x_hfile.h"
#include      "fa.h"
/* ---------------------------------- */
int main(void)
{
double Ix = lint2d_ds(yyf, g,h, a,b,LOOP);
double Iy = lint2d_ds(xxf, g,h, a,b,LOOP); 

 clrscrn();
 
 printf(" If a thin wire has the shape of a plane curve C\n");
 printf(" and if the linear mass density at (x,y) is F(x,y),\n");
 printf(" find the moments of inertia Ix and Iy with the\n");
 printf(" respect to the x- and y-axes, respectively.\n\n");

 printf(" With :\n\n");
 printf(" F x,y -> %s \n\n", feq);
 printf(" and C has the parametrization :\n\n\n");
 printf(" x = %s;     y = %s;     %.1f < t =< %.1f \n\n\n",
          geq, heq, a, b);
 stop();

 clrscrn();

 printf(" Compute the moment of inertia Ix.\n\n");
 printf("         (\n");
 printf(" Ix = int( y**2  F(x,y) ds =  %+.3f\n",  Ix);
 printf("         (C\n\n\n");

 printf(" Compute the moment of inertia Iy.\n\n");
 printf("         (\n");
 printf(" Iy = int( x**2  F(x,y) ds =  %+.3f\n",  Iy);
 printf("         (C\n\n\n");

 stop();

 return 0;
}
/* ---------------------------------- */
/* ---------------------------------- */



Exemple de sortie écran :
 If a thin wire has the shape of a plane curve C
 and if the linear mass density at (x,y) is F(x,y),
 find the moments of inertia Ix and Iy with the
 respect to the x- and y-axes, respectively.

 With :

 F x,y -> y 

 and C has the parametrization :


 x = cos(t);     y = sin(t);     0.0 < t =< 3.1 


 Press return to continue.


Exemple de sortie écran :
 Compute the moment of inertia Ix.

         (
 Ix = int( y**2  F(x,y) ds =  +1.333
         (C


 Compute the moment of inertia Iy.

         (
 Iy = int( x**2  F(x,y) ds =  +0.667
         (C


 Press return to continue.