Application

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

c00a.c
/* ------------------------------------ */
/*  Save as :   c00a.c                  */
/* ------------------------------------ */
#include "v_a.h"
/* ------------------------------------ */     
#define RCA          RC3  
/* ------------------------------------ */       
/* ------------------------------------ */
int main(void)
{                          
double a[RCA*RCA] ={   
+0.020000000000, -0.000000000000, +0.140000000000, 
-0.000000000000, +1.000000000000, -0.000000000000, 
+0.140000000000, -0.000000000000, +0.980000000000                                    
};

double v[RCA*RCA] ={   
+0.000000000000, +0.141421356237,       -0.989949493661,
+1.000000000000, +0.000000000000,       +0.000000000000, 
+0.000000000000, +0.989949493661,       +0.141421356237       
};   

double **A      =  ca_A_mR(a, i_mR(RCA,RCA));
double **V      =  ca_A_mR(v, i_mR(RCA,RCA));
double **invV   = invgj_mR(V, i_mR(RCA,RCA));
double **EValue =              i_mR(RCA,RCA);

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

  clrscrn(); 
  printf(" A :");
  p_mR(A, S8,P6, C3);     

  printf(" V :");
  p_mR(V, S9,P6, C4); 
 
  printf(" EValue = invV * A * V");
  mul_mR(invV,A,T);
  mul_mR(T,V,EValue);
  p_mR(EValue, S9,P6, C4); 
          
  printf(" A = V * EValue * invV");
  mul_mR(V,EValue,T);
  mul_mR(T,invV,A); 
  p_mR(A, S8,P6, C3);
  stop();  
  
  clrscrn();          
  printf(" The matrix A projects the space in the direction\n"
         " of the  eigenvector V3  on a plan  determined by\n"
         " the eigenvector V1 and V2 if :\n\n"
         " The eigenvector V1 has its eigenvalue equal to  one and   \n"
         " The eigenvector V2 has its eigenvalue equal to  one and   \n"
         " The eigenvector V3 has its eigenvalue equal to zero and \n\n"
         " If The vectors V1 and V2 and V3 are linearly independent\n\n"
         " det(V) = %.5e\n\n",det_R(V));          
  stop();  
  
  f_mR(A);
  f_mR(V);  
  f_mR(invV);  
  f_mR(T);  
  f_mR(EValue);

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


Vérifier les calculs. 


Exemple de sortie écran :

 A :
+0.020000 -0.000000 +0.140000 
-0.000000 +1.000000 -0.000000 
+0.140000 -0.000000 +0.980000 

 V :
+0.000000 +0.141421 -0.989949 
+1.000000 +0.000000 +0.000000 
+0.000000 +0.989949 +0.141421 

 EValue = invV * A * V
+1.000000 +0.000000 +0.000000 
+0.000000 +1.000000 -0.000000 
+0.000000 -0.000000 -0.000000 

 A = V * EValue * invV
+0.020000 +0.000000 +0.140000 
+0.000000 +1.000000 +0.000000 
+0.140000 +0.000000 +0.980000 

 Press return to continue. 


 The matrix A projects the space in the direction
 of the  eigenvector V3  on a plan  determined by
 the eigenvector V1 and V2 if :

 The eigenvector V1 has its eigenvalue equal to  one and   
 The eigenvector V2 has its eigenvalue equal to  one and   
 The eigenvector V3 has its eigenvalue equal to zero and 

 If The vectors V1 and V2 and V3 are linearly independent

 det(V) = 6.00000e-01

 Press return to continue.