Mathc initiation/Fichiers c : c64ca
Apparence
Installer et compiler ces fichiers dans votre répertoire de travail.
c18a.c |
---|
/* ---------------------------------- */
/* save as c18a.c */
/* ---------------------------------- */
#include "x_hfile.h"
#include "fa.h"
/* --------------------------------- */
int main(void)
{
double m = flux_dzdydx( M,N,P,
u, v,LOOP,
s, t,LOOP,
ax,bx,LOOP);
/* --------------------------------- */
clrscrn();
printf(" Use the divergence theorem to find,\n\n");
printf(" the flux of F through S.\n\n");
printf(" // /// \n");
printf(" || ||| \n");
printf(" || F.n dS = ||| div F dV \n");
printf(" || ||| \n");
printf(" // /// \n");
printf(" S Q \n\n\n");
printf(" If F = Mi + Nj + Pk \n\n\n");
printf(" /// /// \n");
printf(" ||| ||| \n");
printf(" ||| div F dV = ||| M_x + N_y + P_z dV \n");
printf(" ||| ||| \n");
printf(" /// /// \n");
printf(" Q Q \n\n\n");
stop();
/* --------------------------------- */
clrscrn();
printf(" / b / t(x) / v(x, y) \n");
printf(" | | | \n");
printf(" | | | M_x + N_y + P_z dzdydx = %.3f \n",m);
printf(" | | | \n");
printf(" / a / s(x) / u(x, y) \n\n\n");
printf(" With.\n\n\n");
printf(" F : (x,y,z)-> (%s)i + (%s)j + (%s)k \n\n",Meq,Neq,Peq);
printf(" v : (x,y)-> %s \n", veq);
printf(" u : (x,y)-> %s \n\n", ueq);
printf(" t : (x)-> %s \n", teq);
printf(" s : (x)-> %s \n\n", seq);
printf(" bx = %+.1f\n ax = %+.1f\n\n",bx,ax);
stop();
return 0;
}
/* --------------------------------- */
/* --------------------------------- */
Ce travail consiste à adapter l'intégrale triple au calcul du flux en 3d par le théorème de la divergence : (M_x + N_y + P_z)
Exemple de sortie écran :
Use the divergence theorem to find,
the flux of F through S.
// ///
|| |||
|| F.n dS = ||| div F dV
|| |||
// ///
S Q
If F = Mi + Nj + Pk
/// ///
||| |||
||| div F dV = ||| M_x + N_y + P_z dV
||| |||
/// ///
Q Q
Press return to continue.
Exemple de sortie écran :
/ b / t(x) / v(x, y)
| | |
| | | M_x + N_y + P_z dzdydx = 24.000
| | |
/ a / s(x) / u(x, y)
With.
F : (x,y,z)-> + y*sin(x)i + y^2*zj + (x+3*z)k
u : (x,y)-> -1
v : (x,y)-> +1
s : (x)-> -1
t : (x)-> +1
ax = -1.0 bx = +1.0
dV = dz dy dx
Press return to continue.