Mathc initiation/c35ce
Installer et compiler ces fichiers dans votre répertoire de travail.
![]() |
c17e.c |
---|
/* ---------------------------------- */
/* save as c17e.c */
/* --------------------------------- */
#include "x_hfile.h"
#include "fe.h"
/* --------------------------------- */
int main(void)
{
double ay,by,ny,
nx,nz,M;
clrscrn();
printf(" f : x,y,z -> %s\n\n", feq);
printf(" v : x,y -> %s \n", veq);
printf(" u : x,y -> %s\n\n", ueq);
printf(" t : y -> %s \n", teq);
printf(" s : y -> %s\n\n", seq);
ay = 0;
by = 4;
ny = 2*50; nx = 2*50; nz = 2*50;
M = trapezoid_dzdxdy( f,
ay, by,ny,
sx, tx,nx,
uz, vz,nz);
printf(" With the trapezoidal's rule.\n\n\n");
printf(" (%+.1f (%s (%s \n", by, teq, veq);
printf(" A = int( int( int( %s dz dx dy = %.6f\n",feq, M);
printf(" (%+.1f (%s (%s\n\n\n", ay, seq, ueq);
stop();
return 0;
}
/* --------------------------------- */
Exemple de sortie écran :
f : x,y,z -> 1
v : x,y -> 4-y
u : x,y -> 0
t : y -> sqrt(y)
s : y -> -sqrt(y)
With the trapezoidal's rule.
(+4.0 (sqrt(y) (4-y
A = int( int( int( 1 dz dx dy = 17.052845
(+0.0 (-sqrt(y) (0
Press return to continue.