Mathc complexes/03n
Apparence
Installer et compiler ces fichiers dans votre répertoire de travail.
c00a.c |
---|
/* ------------------------------------ */
/* Save as : c00a.c */
/* ------------------------------------ */
#include "w_a.h"
/* ------------------------------------ */
#define RCA RC4
#define CX C1
/* ------------------------------------ */
/* ------------------------------------ */
int main(void)
{
double a[RCA*(RCA*C2)]={
+3,1, -4,1, -2,1, -1,1,
+5,2, -3,2, -0,2, -2,2,
+6,3, -0,3, -3,3, -2,3,
+3,4, -3,4, -1,4, -3,4
};
double x_B[RCA*(CX*C2)]={
+1,+1,
+2,+2,
+3,+3,
+4,+4
};
double b[RCA*(RCA*C2)]={
+1,+2, +2,+5, +6,+2, +6,+5,
+3,+3, +2,+4, +1,+3, +6,+4,
+5,+4, +5,+3, +3,+4, +6,+3,
+5,+5, +5,+2, +2,+5, +4,+2
};
double **A = ca_A_mZ(a, i_mZ(RCA,RCA));
double **B = ca_A_mZ(b, i_mZ(RCA,RCA));
double **X_B = ca_A_mZ(x_B, i_mZ(RCA,CX));
double **invB = inv_mZ(B, i_mZ(RCA,RCA));
double **invBA = i_mZ(RCA,RCA);
double **D = i_mZ(RCA,RCA);
double **DX_B = i_mZ(RCA,CX);
clrscrn();
printf(" In the B basis\n\n"
" Find the linear application [T(x_B)]_B = D*x_B \n\n"
" D = InvB A B ");
mul_mZ(invB,A,invBA);
mul_mZ(invBA,B,D);
p_mZ(D, S10,P2, S8,P2, C4);
printf(" x_B : ");
p_mZ(X_B, S10,P2, S8,P2, C4);
printf(" [T(x_B)]_B = D x_B");
p_mZ(mul_mZ(D,X_B,DX_B), S10,P2, S8,P2, C4);
stop();
f_mZ(A);
f_mZ(X_B);
f_mZ(B);
f_mZ(invB);
f_mZ(invBA);
f_mZ(D);
f_mZ(DX_B);
return 0;
}
/* ------------------------------------ */
/* ------------------------------------ */
Calculons [T(x)]_B = D* [x]_B en base B.
Exemple de sortie écran :
In the B basis
Find the linear application [T(x_B)]_B = D*x_B
D = InvB A B
+4.59 +24.55i -6.58 +21.29i -0.02 +28.53i +2.30 +44.72i
+11.03 -13.75i +8.85 +3.23i +20.08 -7.85i +31.96 -8.76i
-6.87 +4.32i -6.36 -2.81i -11.03 +1.79i -16.55 +2.32i
-9.83 -4.90i +2.85 -6.41i -5.04 -13.94i -8.41 -19.57i
x_B :
+1.00 +1.00i
+2.00 +2.00i
+3.00 +3.00i
+4.00 +4.00i
[T(x_B)]_B = D x_B
-331.03 +332.15i
+282.69 +150.91i
-132.29 -105.53i
+84.94 -190.71i
Press return to continue.