|
Revision 85, 0.5 KB
(checked in by aqua, 21 months ago)
|
|
add console mine project
|
| Line | |
|---|
| 1 | #ifndef __MATRIX_H__ |
|---|
| 2 | #define __MATRIX_H__ |
|---|
| 3 | |
|---|
| 4 | typedef struct { |
|---|
| 5 | int col; |
|---|
| 6 | int row; |
|---|
| 7 | |
|---|
| 8 | double** var; |
|---|
| 9 | } matrix; |
|---|
| 10 | |
|---|
| 11 | #ifdef __cplusplus |
|---|
| 12 | extern "C" { |
|---|
| 13 | #endif |
|---|
| 14 | |
|---|
| 15 | matrix* matrix_new( int row, int col ); |
|---|
| 16 | void matrix_free( matrix* m ); |
|---|
| 17 | |
|---|
| 18 | matrix* matrix_multiple( matrix* a, matrix* b ); |
|---|
| 19 | matrix* matrix_inv( matrix* m ); |
|---|
| 20 | |
|---|
| 21 | matrix* matrix_transpose( matrix* m ); |
|---|
| 22 | |
|---|
| 23 | void matrix_init( matrix* m, double* src ); |
|---|
| 24 | void matrix_extract( double* dst, matrix* m ); |
|---|
| 25 | |
|---|
| 26 | void matrix_load_identity( matrix* m ); |
|---|
| 27 | |
|---|
| 28 | #ifdef __cplusplus |
|---|
| 29 | } |
|---|
| 30 | #endif |
|---|
| 31 | |
|---|
| 32 | #endif |
|---|