< Mathc complexes
Installer et compiler ces fichiers dans votre répertoire de travail.
![]() |
gj1_zsing.c ' |
---|
/* ------------------------------------ */
/* Save as : gj1_zsing.c */
/* ------------------------------------ */
#include "w_a.h"
/* ------------------------------------ */
void fun(int r)
{
/* i_AbR0_mZ(R_Ab,C_A,C_b));*/
double **Ab = r_singular_Ab_mZ(i_AbR0_mZ( r, r, C1),999);
double **A = c_Ab_A_mZ(Ab,i_mZ(r,r));
double **b = c_Ab_b_mZ(Ab,i_mZ(r,C1));
clrscrn();
printf(" A :");
p_mZ(A,5,0,5,0,5);
printf(" b :");
p_mZ(r_mZ(b,999.),5,0,5,0,5);
stop();
clrscrn();
printf(" Copy/Past into the octave window.\n\n");
p_octave_mZ(c_A_b_Ab_mZ(A,b,Ab),"Ab",1,0, 0);
printf(" rref(Ab,.00000000001)\n\n");
printf(" gj_mZ(Ab) :");
p_mZ(gj_mZ(Ab),1,5,1,5,3);
f_mZ(Ab);
f_mZ(b);
f_mZ(A);
}
/* ------------------------------------ */
int main(void)
{
time_t t;
srand(time(&t));
do
{
fun(rp_I(4)+1);
} while(stop_w());
return 0;
}
/* ------------------------------------ */
/* ------------------------------------ */
La matrice A a deux lignes identique mais avec un b différent. Systeme incompatible.
Exemple de sortie écran :
------------------------------------
A :
+48 +728i +538 +498i -941 +322i +142 +596i
+102 -397i -873 +788i -441 +780i -937 +234i
+48 +728i +538 +498i -941 +322i +142 +596i
+102 -397i -873 +788i -441 +780i -937 +234i
b :
-927 -603i
-445 -975i
-331 -701i
+192 -273i
Press return to continue.
------------------------------------
Copy/Past into the octave window.
Ab=[
+48+728*i,+538+498*i,-941+322*i,+142+596*i,-927-603*i;
+102-397*i,-873+788*i,-441+780*i,-937+234*i,-445-975*i;
+48+728*i,+538+498*i,-941+322*i,+142+596*i,-331-701*i;
+102-397*i,-873+788*i,-441+780*i,-937+234*i,+192-273*i]
rref(Ab,.00000000001)
gj_mZ(Ab) : This(ese) row(s) are incompatible.
row 3; row 4;
This(ese) equation(s) was already defined
with an other value(s)
The system is inconsistent.
I prefer to close the program.
Press return to continue.
Cet article est issu de Wikibooks. Le texte est sous licence Creative Commons - Attribution - Partage dans les Mêmes. Des conditions supplémentaires peuvent s'appliquer aux fichiers multimédias.