Mathc complexes/a293
Quelques propriétés des valeurs propres. Matrices symétriques conjugués
Installer et compiler ces fichiers dans votre répertoire de travail.
c05a.c |
---|
/* ------------------------------------ */
/* Save as : c05a.c */
/* ------------------------------------ */
#include "w_a.h"
/* ------------------------------------ */
void fun(int r)
{
double s = rp_I(9);
double **A = rcsymmetric_mZ( i_mZ(r, r),99.);
double **EigsValueA = eigs_mZ(A, i_mZ(r,C1) );
double **ID = eye_mZ( i_mZ(r, r));
double **sID = smul_mZ(s, ID,i_mZ(r, r));
double **Apls_sID = add_mZ(A, sID,i_mZ(r, r));
double **EigsValueApls_sID = eigs_mZ(Apls_sID,i_mZ(r,C1));
double **M = m1_mZ( i_mZ(r,C1));
double **sM = smul_mZ(s,M, i_mZ(r,C1));
clrscrn();
printf(" A :");
p_mZ(A,S7,P0,S6,P0,C6);
printf(" EigsValue A :");
p_mZ(EigsValueA,S7,P0,S3,P0,C6);
printf(" A + %.0f*ID :",s);
p_mZ(Apls_sID,S7,P0,S6,P0,C6);
printf(" EigsValue A + %.0f*ID :",s);
p_mZ(EigsValueApls_sID,S7,P0,S3,P0,C6);
stop();
clrscrn();
printf(" EigsValue A :");
p_mZ(EigsValueA,S7,P0,S3,P0,C6);
printf(" EigsValue A + %.0f*ID :",s);
p_mZ(EigsValueApls_sID,S7,P0,S3,P0,C6);
printf(" EigsValue A + %.0f :",s);
add_mZ(EigsValueA,sM,M);
p_mZ(M,S7,P0,S3,P0,C6);
f_mZ(A);
f_mZ(EigsValueA);
f_mZ(ID);
f_mZ(sID);
f_mZ(Apls_sID);
f_mZ(EigsValueApls_sID);
f_mZ(M);
f_mZ(sM);
}
/* ------------------------------------ */
int main(void)
{
time_t t;
srand(time(&t));
do
{
fun(rp_I(R3)+R1);
} while(stop_w());
return 0;
}
/* ------------------------------------ */
/* ------------------------------------ */
Les valeurs propres de A+sID correspondent aux valeurs propres de A plus s : Exemple de sortie écran :
A :
+25665 +0i -646 -3240i +9327 -7240i
-646 +3240i +8622 +0i +1223 +7257i
+9327 +7240i +1223 -7257i +10600 +0i
EigsValue A :
+33801 -0i
+10562 -0i
+524 -0i
A + 3*ID :
+25668 +0i -646 -3240i +9327 -7240i
-646 +3240i +8625 +0i +1223 +7257i
+9327 +7240i +1223 -7257i +10603 +0i
EigsValue A + 3*ID :
+33804 +0i
+10565 -0i
+527 +0i
Press return to continue.
EigsValue A :
+33801 -0i
+10562 -0i
+524 -0i
EigsValue A + 3*ID :
+33804 +0i
+10565 -0i
+527 +0i
EigsValue A + 3 :
+33804 -0i
+10565 -0i
+527 -0i
Press return to continue
Press X return to stop