norm_matrixT_norm_matrixNormMatrixNormMatrixnorm_matrix (算子)

名称

norm_matrixT_norm_matrixNormMatrixNormMatrixnorm_matrix — 矩阵的范数。

签名

norm_matrix( : : MatrixID, NormType : Value)

Herror T_norm_matrix(const Htuple MatrixID, const Htuple NormType, Htuple* Value)

void NormMatrix(const HTuple& MatrixID, const HTuple& NormType, HTuple* Value)

double HMatrix::NormMatrix(const HString& NormType) const

double HMatrix::NormMatrix(const char* NormType) const

double HMatrix::NormMatrix(const wchar_t* NormType) const   ( Windows only)

static void HOperatorSet.NormMatrix(HTuple matrixID, HTuple normType, out HTuple value)

double HMatrix.NormMatrix(string normType)

def norm_matrix(matrix_id: HHandle, norm_type: str) -> float

描述

算子 norm_matrixnorm_matrixNormMatrixNormMatrixNormMatrixnorm_matrix computes the norm of the elements of the Matrix defined by the matrix handle MatrixIDMatrixIDMatrixIDMatrixIDmatrixIDmatrix_id. The return value is a floating point number.

The type of norming of the matrix can be selected via the parameter NormTypeNormTypeNormTypeNormTypenormTypenorm_type:

'frobenius-norm'"frobenius-norm""frobenius-norm""frobenius-norm""frobenius-norm""frobenius-norm"

The Frobenius norm is computed. 结果的计算公式为: with m = number of rows and n = number of columns of the Matrix.

示例:

'infinity-norm'"infinity-norm""infinity-norm""infinity-norm""infinity-norm""infinity-norm"

The infinity norm is computed. The result is the largest value of the sum of the absolute values of the elements of the rows. The formula for the calculation is: with m = number of rows and n = number of columns of the Matrix.

示例:

'1-norm'"1-norm""1-norm""1-norm""1-norm""1-norm"

The 1-norm is computed. The result is the largest value of the sum of the absolute values of the elements of the columns. The formula for the calculation is: with m = number of rows and n = number of columns of the Matrix.

示例:

'2-norm'"2-norm""2-norm""2-norm""2-norm""2-norm"

The 2-norm is computed. The result is the largest singular value of the Matrix. 结果的计算公式为:

示例:

执行信息

参数

MatrixIDMatrixIDMatrixIDMatrixIDmatrixIDmatrix_id (输入控制)  matrix HMatrix, HTupleHHandleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

输入矩阵的矩阵句柄。

NormTypeNormTypeNormTypeNormTypenormTypenorm_type (输入控制)  string HTuplestrHTupleHtuple (string) (string) (HString) (char*)

Type of norm.

默认值: '2-norm' "2-norm" "2-norm" "2-norm" "2-norm" "2-norm"

值列表: '1-norm'"1-norm""1-norm""1-norm""1-norm""1-norm", '2-norm'"2-norm""2-norm""2-norm""2-norm""2-norm", 'frobenius-norm'"frobenius-norm""frobenius-norm""frobenius-norm""frobenius-norm""frobenius-norm", 'infinity-norm'"infinity-norm""infinity-norm""infinity-norm""infinity-norm""infinity-norm"

ValueValueValueValuevaluevalue (输出控制)  real HTuplefloatHTupleHtuple (real) (double) (double) (double)

Norm of the input matrix.

结果

如果参数有效,算子 norm_matrixnorm_matrixNormMatrixNormMatrixNormMatrixnorm_matrix 返回值 2 ( H_MSG_TRUE )。如有必要,则抛出异常。

可能的前趋

create_matrixcreate_matrixCreateMatrixCreateMatrixCreateMatrixcreate_matrix

另见

sum_matrixsum_matrixSumMatrixSumMatrixSumMatrixsum_matrix, mean_matrixmean_matrixMeanMatrixMeanMatrixMeanMatrixmean_matrix

参考文献

David Poole: “Linear Algebra: A Modern Introduction”; Thomson; Belmont; 2006.
Gene H. Golub, Charles F. van Loan: “Matrix Computations”; The Johns Hopkins University Press; Baltimore and London; 1996.

模块

基础