Mathc matrices/094
Apparence
Installer et compiler ces fichiers dans votre répertoire de travail.
c00d.c |
|---|
/* ------------------------------------ */
/* Save as : c00d.c */
/* ------------------------------------ */
#include "v_a.h"
/* ------------------------------------ */
#define RCA RC4
/* ------------------------------------ */
/* ------------------------------------ */
int main(void)
{
double a[RCA*RCA] ={
+0.812500000000, -0.656250000000, -1.406250000000, -0.656250000000,
-0.250000000000, +0.125000000000, -1.875000000000, -0.875000000000,
+0.125000000000, +0.437500000000, +1.937500000000, +0.437500000000,
-0.250000000000, -0.875000000000, -1.875000000000, +0.125000000000
};
/* You can choose the value of the point P */
double P[RCA*C1] ={
+2,
+5,
+6,
+3,
};
double **A = ca_A_mR(a, i_mR(RCA,RCA));
double **p = ca_A_mR(P, i_mR(RCA,C1));
double **Pp = mul_mR(A,p, i_mR(RCA,C1));;
clrscrn();
printf(" A :");
p_mR(A, S9,P12, C4);
printf(" You can choose the value of the point p\n\n"
" p:");
p_mR(p, S9,P1, C4);
printf(" The projection of p on the hyperplan defined by v1,"
" v2 and v3.\n\n"
" Pp: Copy this matrix into c00e.c");
P_mR(Pp, 18,P12, C4);
stop();
f_mR(A);
f_mR(p);
f_mR(Pp);
return 0;
}
/* ------------------------------------ */
/* ------------------------------------ */
/* ------------------------------------ */
Vous pouvez calculer la projection d'un point P sur l'hyperplan.
Exemple de sortie écran :
A :
+0.812500000000 -0.656250000000 -1.406250000000 -0.656250000000
-0.250000000000 +0.125000000000 -1.875000000000 -0.875000000000
+0.125000000000 +0.437500000000 +1.937500000000 +0.437500000000
-0.250000000000 -0.875000000000 -1.875000000000 +0.125000000000
You can choose the value of the point p
p:
+2.0
+5.0
+6.0
+3.0
The projection of p on the hyperplan defined by v1, v2 and v3.
Pp: Copy this matrix into c00e.c
-12.062500000000,
-13.750000000000,
+15.375000000000,
-15.750000000000
Press return to continue.