Sommaire


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

c00b.c
/* ---------------------------------- */
/* save as c00b.c                    */
/* --------------------------------- */
#include  "x_hfile.h"
#include       "fb.h"
/* --------------------------------- */
int main(void)
{
double  ay = -1,
        by =  1,
        ny = 2*150, nx = 2*150, nz = 2*150;

double  M =  trapezoid_dxdzdy(f,
                              ux,vx,nx,
                              sz,tz,nz,
                              ay,by,ny);
 
 clrscrn();
 printf(" f : x,y,z -> %s\n\n", feq);

 printf(" v : y,z   -> %s  \n", veq);
 printf(" u : y,z   -> %s\n\n", ueq);
 
 printf(" t : y     -> %s  \n", teq);
 printf(" s : y     -> %s\n\n", seq);

 printf(" With the trapezoidal's rule.\n\n\n");
 printf("        (%+.1f  (%s    (%s    \n", by, teq, veq);
 printf(" A = int(   int(             int(  %s  dx dz dy = %.6f\n",feq, M);
 printf("        (%+.1f  (%s   (%s\n\n\n", ay, seq, ueq);

 printf(" Code Mathematica : \n\n"
        " integral 1  dx dz dy from -1 to 1  from "
        "(-sqrt(1-y**2)) to sqrt(1-y**2) from 0 to (2-y-z)\n\n\n");
 stop();

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


Exemple de sortie écran :

 f : x,y,z -> 1

 v : y,z   -> 2-y-z  
 u : y,z   -> 0

 t : y     -> sqrt(1-y**2)  
 s : y     -> -sqrt(1-y**2)

 With the trapezoidal's rule.


        (+1.0  (sqrt(1-y**2)     (2-y-z    
 A = int(   int(    int(      1  dx dz dy = 6.281905
        (-1.0  (-sqrt(1-y**2)     (0


 Press return to continue.