public class Matrix extends MatrixOperation
| 限定符和类型 | 方法和说明 |
|---|---|
void |
clear()
清除矩阵数据
|
Matrix |
copy() |
double |
getAVG()
计算全矩阵元素平均值
|
Matrix |
getColumn(int y)
获取列向量
|
double |
getDet()
求矩阵的行列式 递归算法
|
double[][] |
getMatrix() |
double |
getNumber(int x,
int y)
取矩阵的数值
|
String |
getPositionString()
返回一个带坐标的矩阵字符串
|
Matrix |
getRow(int x)
获取行向量
|
double |
getSigma() |
double |
getSigmaByVector(boolean isRow,
int index)
计算矩阵中某一行向量或者列向量所有元素的和
|
Matrix |
getSonOfMatrix(int x,
int y,
int xSize,
int ySize)
将矩阵分块
|
String |
getString()
返回一个矩阵字符串
|
int |
getX()
获取行数
|
int |
getY()
获取列数
|
boolean |
isRowVector()
是否为单行
|
boolean |
isVector()
是否是一个向量矩阵
单行和单列矩阵都是向量矩阵
|
boolean |
isZero()
是否是一个单元素矩阵
|
void |
setAll(String messages)
给矩阵设置数据
|
void |
setNub(int x,
int y,
double number)
给矩阵设置值
|
add, adjointMatrix, algebraicCofactor, center, convolution, errorNub, getCrossEntropy, getEDist, getEDistByMatrix, getInverseMatrix, getKernelNub, getLinearRegression, getNorm, getNormCos, getPoolVector, getSdByMatrix, im2col, innerProduct, inverseNumber, ListToMatrix, listToRowVector, listToRowVector, mathAdd, mathDiv, mathMul, mathMulBySelf, mathSub, matrixMulPd, matrixPointDiv, matrixToList, matrixToVector, mulMatrix, push, pushVector, reverseIm2col, rowVectorToList, softMaxByMatrix, sub, transPositionpublic int getX()
public int getY()
public double getSigma()
public double getAVG()
public double[][] getMatrix()
public boolean isRowVector()
public boolean isVector()
public boolean isZero()
public void clear()
public double getDet()
throws Exception
Exception - 如果矩阵不是一个方阵抛出异常public void setAll(String messages) throws Exception
messages - 数据Exception - 给出的数据不正确时候会抛出异常public Matrix getSonOfMatrix(int x, int y, int xSize, int ySize)
x - 要分块的x坐标y - 要分块的y坐标xSize - 分块矩阵的宽度ySize - 分块矩阵的长度public Matrix getRow(int x) throws Exception
x - 你要指定的行数Exception - 超出矩阵范围抛出异常public Matrix getColumn(int y) throws Exception
y - 要制定的列数Exception - 超出矩阵范围抛出异常public String getString()
public String getPositionString()
public void setNub(int x,
int y,
double number)
throws Exception
x - x坐标y - y坐标number - 要设置的值Exception - 超出矩阵范围抛出public double getNumber(int x,
int y)
throws Exception
x - x坐标y - y坐标Exception - 超出矩阵范围抛出Copyright © 2024. All rights reserved.