Aller au contenu

Mathc initiation/a325

Un livre de Wikilivres.


Sommaire


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


c00b2.c
/* ---------------------------------- */
/* save as c00b2.c                    */
/* ---------------------------------- */
#include "x_hfile.h"
#include      "fb.h"
/* ---------------------------------- */
int main(void)
{
double Mxy = lint3d_ds( zf, g,h,k, a,b,LOOP);
double Mxz = lint3d_ds( yf, g,h,k, a,b,LOOP);
double Myz = lint3d_ds( xf, g,h,k, a,b,LOOP); 

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

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

 clrscrn();

 printf(" Compute the moment Mxy.\n\n");
 printf("          (\n");
 printf(" Mxy = int( z  F(x,y) ds =  %+.3f\n",  Mxy);
 printf("          (C\n\n");

 printf(" Compute the moment Mxz.\n\n");
 printf("          (\n");
 printf(" Mxz = int( y  F(x,y) ds =  %+.3f\n",  Mxz);
 printf("          (C\n\n");

 printf(" Compute the moment Myz.\n\n");
 printf("          (\n");
 printf(" Myz = int( x  F(x,y) ds =  %+.3f\n",  Myz);
 printf("          (C\n\n");
 stop();

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



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

 With :

 F (x,y,z) -> 1 

 and C has the parametrization :


 x = cos(t);     y = sin(t);  z = (t);  0.0 < t =< 9.4 


 Press return to continue.


Exemple de sortie écran :
 Compute the moment Mxy.

          (
 Mxy = int( z  F(x,y) ds =  +62.810
          (C

 Compute the moment Mxz.

          (
 Mxz = int( y  F(x,y) ds =  +2.828
          (C

 Compute the moment Myz.

          (
 Myz = int( x  F(x,y) ds =  -0.000
          (C

 Press return to continue.