Math module

mat_norm

procedure · 1 overloadSource

The maximum absolute row sum of a Matrix3 (the infinity norm), or with tpose true the maximum absolute column sum (the one norm). norm_inf and norm_one are the two fixed forms.

ExampleOpen in playground ↗
m := Matrix3.{ 1, -2, 0, 0, 1, 1, 4, 0, 0 };
assert(mat_norm(m, false) == 4 && mat_norm(m, true) == 5);
mat_norm :: (M: Matrix3, tpose: bool) -> float

The largest sum of absolute values over the rows, or over the columns.

Parameters

M: Matrix3
the matrix.
tpose: bool
true sums down columns, false across rows.

Returns

float

See also