Aller au contenu

Mathc initiation/a483

Un livre de Wikilivres.


Sommaire

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

c00e2.c
/* --------------------------------- */
/* save as c00e2.c                   */
/* --------------------------------- */
#include  "x_afile.h"
#include      "fe2.h"
/* --------------------------------- */
int main(void)
{
double M =  J_vwu(              f,
                                X,Y,Z,
                                k0,k1,LOOP,
                                z0,z1,LOOP,
                                r0,r1,LOOP); 
 clrscrn();
 
 printf("     f :  x,y,z -> %s\n\n", feq);

 printf(" The change of variables.\n"); 
 printf(" X     :  r,k,z -> %s  \t\t\t   \n",Xeq);
 printf(" Y     :  r,k,z -> %s  \t\t\t   \n",Yeq);
 printf(" Z     :  r,k,z -> %s  \t\t\t \n\n",Zeq);

 printf(" The cylindrical coordinates.\n");  
 printf(" k1   r,z   -> %s  \n", k1eq);
 printf(" k0   r,z   -> %s\n\n", k0eq);

 printf(" z1   r     -> %s  \n", z1eq);
 printf(" z0   r     -> %s\n\n", z0eq);

 printf(" r1         -> %s  \n", r1eq); 
 printf(" r0         -> %s\n\n", r0eq);
                          
 printf("        (%s    (%s   (%s         (dkdzdr)\n",r1eq,z1eq,k1eq);
 printf(" A = int(  int( int( f(X,Y,Z) |J| dvdwdu = %.6f\n", M);
 printf("        (%s    (%s   (%s\n\n",               r0eq,z0eq,k0eq);
      
 stop();

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

Exemple de sortie écran :

     f :  x,y,z -> z

 The change of variables.
 X     :  r,k,z -> (r*cos(k))  			   
 Y     :  r,k,z -> (r*sin(k))  			   
 Z     :  r,k,z -> (z)  			 

 The cylindrical coordinates.
 k1   r,z   -> 2 PI  
 k0   r,z   -> 0

 z1   r     -> 1  
 z0   r     -> 0

 r1         -> 2  
 r0         -> 0

        (2    (1   (2 PI         (dkdzdr)
 A = int(  int( int( f(X,Y,Z) |J| dvdwdu = 6.283185
        (0    (0   (0

 Press return to continue.