STD.BLAS.extract_tri ( m, n, tri, dt, a );
m | Number of rows |
n | Number of columns |
tri | Indicates whether upper or lower triangle is used |
dt | Use Diagonal.NotUnitTri or Diagonal.UnitTri |
a | The matrix, usually a composite from factoring |
Return: | Triangle |
The extract_tri function extracts the upper or lower triangle. The diagonal can be the actual or implied unit diagonal.
Example:
IMPORT STD; Diagonal := STD.BLAS.Types.Diagonal; Triangle := STD.BLAS.Types.Triangle; STD.BLAS.Types.matrix_t x := [1.0, 2.0, 3.0, 2.0, 2.0, 2.0, 4.0, 4.0, 4.0]; triangle := STD.BLAS.extract_tri(3, 3, Triangle.upper, Diagonal.NotUnitTri, x);