Application


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


c00a.c
/* ------------------------------------ */
/*  Save as :   c00a.c                  */
/* ------------------------------------ */
#include "w_a.h"
/* ------------------------------------ */
#define FACTOR_E    +1.E-5         
#define RCA          RC3  
/* ------------------------------------ */       
/* ------------------------------------ */
void fun(void)
{                          
double a[RCA*(RCA*C2)] ={   
 +26191,+1471,   -3444,+9191,   +18535, -3803,
  -3444,-9191,  +27183,+1470,    -3591, -9206,
 +18535,+3803,   -3591,+9206,   +29984, +5471};
                       
double **A      =   ca_A_mZ(a, i_mZ(RCA,RCA));
double **V      = eigs_V_mZ(A, i_mZ(RCA,RCA),FACTOR_E);
double **invV   =    inv_mZ(V, i_mZ(RCA,RCA));
double **EValue =   eigs_mZ(A, i_mZ(RCA, RCA));

double **T      =              i_mZ(RCA,RCA);

  clrscrn(); 
  printf(" A :");
  p_mZ(A, S8,P0, S6,P0, C3);     

  printf(" V :");
  p_mZ(V, S9,P5, S8,P5, C4); 
 
  printf(" EValue = invV * A * V");
  mul_mZ(invV,A,T);
  mul_mZ(T,V,EValue);
  p_mZ(clean_eyes_mZ(EValue), S9,P2, S8,P2, C4); 
         
  printf(" A = V * EValue * invV");
  mul_mZ(V,EValue,T);
  mul_mZ(T,invV,A); 
  p_mZ(A, S8,P0, S6,P0, C3);
  stop();
              
  f_mZ(A);
  f_mZ(V);  
  f_mZ(invV);  
  f_mZ(T);  
  f_mZ(EValue);
}
/* ------------------------------------ */
int main(void)
{
    fun();
    
  return 0;
}
/* ------------------------------------ */
/* ------------------------------------ */


Exemple de référence :  Il permet de vérifier les calculs.


Exemple de sortie écran :
 A :
  +26191 +1471i    -3444 +9191i   +18535 -3803i 
   -3444 -9191i   +27183 +1470i    -3591 -9206i 
  +18535 +3803i    -3591 +9206i   +29984 +5471i 

 V :
 +0.58221-0.15613i  +0.17560-0.27263i  -0.74729+0.09427i 
 -0.23974-0.38731i  +0.58534+0.64006i  -0.05694-0.03403i 
 +0.65512+0.00000i  +0.37754+0.00000i  +0.65443+0.00000i 

 EValue = invV * A * V
+54119.26+3187.50i     +0.00   +0.00i     +0.00   +0.00i 
    +0.00   +0.00i +20176.51+2040.40i     +0.00   +0.00i 
    +0.00   +0.00i     +0.00   +0.00i  +9062.22+3184.09i 

 A = V * EValue * invV
  +26191 +1471i    -3444 +9191i   +18535 -3803i 
   -3444 -9191i   +27183 +1470i    -3591 -9206i 
  +18535 +3803i    -3591 +9206i   +29984 +5471i 

 Press return to continue.