matrix.h

来自「它建立在最优原则的基础上,采用动态规划方法,可以优雅而高效地解决许多用贪心技术或」· C头文件 代码 · 共 49 行

H
49
字号
/**
* File    : Matrix.h
 * Author  : Wind
 * Email   : zealotwjr@163.com
 * Date    : 2005-9-30
 * Purpose : 
 * */

#include "../head/Global.h"
 
#ifndef MATRIX_H_
#define MATRIX_H_

typedef struct {
    int col;
    int row;
    double * array ;
} Matrix;

/**
  * @describ Initial Matrix
  * @return Status indicating whether matrix initializtion is successful.
  *         If success return SUCCESS,otherwise return FAIL
  * */
Status initialMatrix(Matrix * m,int row,int col);


/**
 * @describ Matrix multiply
 * @param   Matrix * a
 * @param   Matrix * b
 * @param   Matrix * c
 * @return  STATUS
 * */
Status matrixMultiply(Matrix * a,Matrix * b ,Matrix * c);


/**
 * obtain element address of Matrix * m->array at [row][col]
 * */
double * M(Matrix * m ,int row,int col);

void printMatrix(Matrix * m);

Status destroyMatrix(Matrix * m );

Status matrixTranspose(Matrix * m);
#endif /*MATRIX_H_*/

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?