Mathc matrices/c26j
Apparence
Installer et compiler ces fichiers dans votre répertoire de travail.
gj_s2.c |
---|
/* ------------------------------------ */
/* Save as : gj_s2.c */
/* ------------------------------------ */
#include "v_a.h"
/* ------------------------------------ */
void fun(int r)
{
double **Ab = r_singular_Ab_mR(i_Abr_Ac_bc_mR(r,r,C1),999);
double **A = c_Ab_A_mR(Ab,i_mR(r,r));
double **b = c_Ab_b_mR(Ab,i_mR(r,C1));
clrscrn();
printf(" A :");
p_mR(A,S8,P0,C7);
printf(" b :");
r_mR(b,999.); /* I change the value of b */
p_mR(b,S8,P0,C7);
printf(" Ab :");
p_mR(c_A_b_Ab_mR(A,b,Ab),S8,P0,C7);
stop();
clrscrn();
printf(" Copy/Past into the octave window.\n\n");
p_Octave_mR(Ab,"Ab",P0);
printf("\n rref(Ab,.00000000001)\n\n");
stop();
clrscrn();
printf(" gj_mR(Ab) :");
gj_PP_mR(Ab,YES);
p_mR(Ab,S10,P4,C7);
is_system_consistent_mR(Ab);
f_mR(Ab);
f_mR(b);
f_mR(A);
}
/* ------------------------------------ */
int main(void)
{
time_t t;
srand(time(&t));
do
{
fun(rp_I(R5)+R1);
} while(stop_w());
return 0;
}
/* ------------------------------------ */
/* ------------------------------------ */
Système d'équations incompatibles ! +0.00000 == +654.00000 et +0.00000 == +526.00000
Exemple de sortie écran :
------------------------------------
A :
-255 -569 -35 -391 -155
+380 +426 +622 -899 -779
-497 -429 -509 -655 +20
+380 +426 +622 -899 -779
+380 +426 +622 -899 -779
b :
+424
+80
+208
+734
+606
Ab :
-255 -569 -35 -391 -155 +424
+380 +426 +622 -899 -779 +80
-497 -429 -509 -655 +20 +208
+380 +426 +622 -899 -779 +734
+380 +426 +622 -899 -779 +606
Press return to continue.
Copy/Past into the octave window.
Ab=[
-255,-569,-35,-391,-155,+424;
+380,+426,+622,-899,-779,+80;
-497,-429,-509,-655,+20,+208;
+380,+426,+622,-899,-779,+734;
+380,+426,+622,-899,-779,+606]
rref(Ab,.00000000001)
Press return to continue.
gj_mR(Ab) :
+1.00000 +0.00000 +0.00000 +8.74503 +3.88021 -1.38717
+0.00000 +1.00000 -0.00000 -2.93820 -1.29837 -0.19161
+0.00000 +0.00000 +1.00000 -4.77563 -2.73372 +1.10732
+0.00000 +0.00000 +0.00000 -0.00000 +0.00000 +654.00000
+0.00000 +0.00000 +0.00000 -0.00000 +0.00000 +526.00000
This(ese) row(s) are incompatible.
row 4; row 5;
The system is inconsistent.
I prefer to close the program.
Press return to continue.