?? matinverseverify.c
字號:
#include "MatrixInverse.h"
int main()
{
floatComplexMatrix *mat;
floatComplexMatrix *matInverse;
floatComplexMatrix *I;
mat=floatComplexMatrixAlloc(3,3);
mat->a[0][0]=floatComplexSet(1.0,1.0);
mat->a[0][1]=floatComplexSet(2.0,1.0);
mat->a[0][2]=floatComplexSet(3.0,2.0);
mat->a[1][0]=floatComplexSet(4.0,2.0);
mat->a[1][1]=floatComplexSet(5.0,1.0);
mat->a[1][2]=floatComplexSet(2.0,7.0);
mat->a[2][0]=floatComplexSet(3.0,8.0);
mat->a[2][1]=floatComplexSet(9.0,1.0);
mat->a[2][2]=floatComplexSet(3.0,2.0);
printf("The original Matrix A:\n");
floatPrintComplexMatrix(mat);
matInverse=floatComplexMatrixInverse(mat);
printf("The Inverse of matrix A:\n");
floatPrintComplexMatrix(matInverse);
I=floatComplexMatrixMpy(mat,matInverse);
printf("A*A^(-1):\n");
floatPrintComplexMatrix(I);
floatComplexMatrixFree(mat);
floatComplexMatrixFree(matInverse);
return 0;
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -