Aller au contenu

Mathc complexes/a185

Un livre de Wikilivres.


Application

Installer et compiler ces fichiers dans votre répertoire de travail.

c00b.c
/* ------------------------------------ */
/*  Save as :   c00b.c                  */
/* ------------------------------------ */
#include "w_a.h"
/* ------------------------------------ */
void fun(int r)
{
double **Ab = r_singular_Ab_mZ(    i_Abr_Ac_bc_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, S5,P0, S4,P0, C6);
  printf(" b :");
  p_mZ(b, S5,P0, S4,P0, C6);
  stop();

  clrscrn();
  printf(" Copy/Paste into the octave window.\n\n");
  p_Octave_mZ(Ab,"Ab",P0, P0);
  printf(" rref(Ab,.00000000001)\n\n");
  printf(" Ab: gj_PP_mZ(Ab); :");
  gj_PP_mZ(Ab);
  p_mZ(Ab,S9,P4,S9,P4,C4);
  printf(" You can see that in some row you have  0 = 0. "
         " Consistent matrix.\n");  

  f_mZ(Ab);
  f_mZ(b);
  f_mZ(A);
}
/* ------------------------------------ */
int main(void)
{
time_t t;

  srand(time(&t));

do
{
  fun(RC3);

} while(stop_w());

  return 0;
}
/* ------------------------------------ */
/* ------------------------------------ */
Une matrice A avec des lignes identiques, et des valeurs de b identiques. 
Le système est cohérent: +0 = +0 +0i.

Exemple de sortie écran :

 A :
 -253-871i  +268+571i  +270-419i 
 -253-871i  +268+571i  +270-419i 
 +839-336i  +538 +36i  +756+326i 

 b :
 +235+164i 
 +235+164i 
 -230-711i 

 Press return to continue. 


 Copy/Paste into the octave window.

 Ab=[
-253-871*i,+268+571*i,+270-419*i,+235+164*i;
-253-871*i,+268+571*i,+270-419*i,+235+164*i;
+839-336*i,+538+36*i,+756+326*i,-230-711*i]

 rref(Ab,.00000000001)

 Ab: gj_PP_mZ(Ab); :
  +1.0000  +0.0000i   -0.6870  +0.1081i   +0.3606  +0.4147i   -0.2459  +0.1984i 
  +0.0000  -0.0000i   +1.0000  +0.0000i   +0.2495  +0.1581i   +0.1421  -0.8529i 
  -0.0000  -0.0000i   +0.0000  +0.0000i   +0.0000  -0.0000i   +0.0000  +0.0000i 

 You can see that in some row you have  0 = 0.  Consistent matrix.

 Press   return to continue
 Press X return to stop