Mathc matrices/013
Installer et compiler ces fichiers dans votre répertoire de travail.
c00a.c |
---|
/* ------------------------------------ */
/* Save as : c00a.c */
/* ------------------------------------ */
#include "v_a.h"
/* ------------------------------------ */
#define FACTOR_E +1.E-0
/* ------------------------------------ */
void fun(int r)
{
double **U = r_mR( i_mR(R1, r),9);
double **V = r_mR( i_mR(r ,C1),9);
double **A = rToeplitz_mR(U,V,i_mR(r , r) );
double **Minor = i_mR(r-C1,r-C1);
int minor_r = rp_I(r);
int minor_c = rp_I(r);
clrscrn();
printf(" A :");
p_mR(A,S4,P0,C6);
printf(" Minor(R%d,C%d) :\n",minor_r, minor_c);
p_mR(minor_mR(A,Minor,minor_r,minor_c),S4,P0,C6);
f_mR(U);
f_mR(V);
f_mR(A);
f_mR(Minor);
}
/* ------------------------------------ */
int main(void)
{
time_t t;
srand(time(&t));
do
{
fun(rp_I(R4)+R1);
} while(stop_w());
return 0;
}
/* ------------------------------------ */
/* ------------------------------------ */
Matrice de Toeplitz.
Exemple de sortie écran :
A :
-7 -4 -2 -3 +2
-9 -7 -4 -2 -3
-7 -9 -7 -4 -2
-4 -7 -9 -7 -4
+7 -4 -7 -9 -7
Minor(R1,C2) :
-9 -4 -2 -3
-7 -7 -4 -2
-4 -9 -7 -4
+7 -7 -9 -7
Press return to continue
Press X return to stop