Algosim documentation: IsEssentiallyZeroRow

IsEssentiallyZeroRow

Tests if a matrix row contains only zeros, except possibly the rightmost entry.

Syntax

Description

If A is a matrix and n a valid row index in A, then IsEssentiallyZeroRow(A, n, ε) returns true iff the nth row of A consists only of zeros (compared with epsilon ε), except possibly the rightmost entry on the row.

Examples

A ≔ ❨❨1, 5, 3, 2, 1❩, ❨0, 0, 1, 2, 3❩, ❨0, 0, 0, 0, 1❩❩
⎛1  5  3  2  1⎞
⎜0  0  1  2  3⎟
⎝0  0  0  0  1⎠
IsEssentiallyZeroRow(A, 3)
true

See also