PDF version (NAG web site
, 64-bit version, 64-bit version)
NAG Toolbox: nag_matop_dtfttp (f01vl)
Purpose
nag_matop_dtfttp (f01vl) copies a real triangular matrix, stored in a Rectangular Full Packed (RFP) format array, to a standard packed format array.
Syntax
Description
nag_matop_dtfttp (f01vl) packs a real
by
triangular matrix
, stored in RFP format, to packed format. This function is intended for possible use in conjunction with functions from
Chapters F07 and
F16 where some functions that use triangular matrices store them in RFP format.
The RFP storage format is described in
Rectangular Full Packed (RFP) Storage in the F07 Chapter Introduction and the packed storage format is described in
Packed storage in the F07 Chapter Introduction.
References
Gustavson F G, Waśniewski J, Dongarra J J and Langou J (2010) Rectangular full packed format for Cholesky's algorithm: factorization, solution, and inversion ACM Trans. Math. Software 37, 2
Parameters
Compulsory Input Parameters
- 1:
– string (length ≥ 1)
-
Specifies whether the normal RFP representation of
or its transpose is stored.
- The RFP representation of the matrix is stored.
- The transpose of the RFP representation of the matrix is stored.
Constraint:
or .
- 2:
– string (length ≥ 1)
-
Specifies whether
is upper or lower triangular.
- is upper triangular.
- is lower triangular.
Constraint:
or .
- 3:
– int64int32nag_int scalar
-
, the order of the matrix .
Constraint:
.
- 4:
– double array
-
The upper or lower
by
triangular matrix
(as specified by
uplo) in either normal or transposed RFP format (as specified by
transr). The storage format is described in
Rectangular Full Packed (RFP) Storage in the F07 Chapter Introduction.
Optional Input Parameters
None.
Output Parameters
- 1:
– double array
-
The
by
triangular matrix
, packed by columns.
More precisely,
- if , the upper triangle of is stored with element in for ;
- if , the lower triangle of is stored with element in for .
- 2:
– int64int32nag_int scalar
unless the function detects an error (see
Error Indicators and Warnings).
Error Indicators and Warnings
-
If , argument had an illegal value. An explanatory message is output, and execution of the program is terminated.
-
-
Dynamic memory allocation failed.
Accuracy
Not applicable.
Further Comments
None.
Example
This example reads in a triangular matrix in RFP format and copies it to packed format.
Open in the MATLAB editor:
f01vl_example
function f01vl_example
fprintf('f01vl example results\n\n');
transr = 'n';
uplo = 'u';
n = int64(4);
ar = [1.30; 2.30; 3.30; 1.10; 1.20; 1.40; 2.40; 3.40; 4.40; 2.20];
fprintf('\n');
[ifail] = x04cb('g', 'x', ar, 'f5.2', 'RFP Packed Array ar:', 'i', ...
{''}, 'n', {''}, int64(80), int64(0));
[ap, info] = f01vl(transr, uplo, n, ar);
fprintf('\n');
[ifail] = x04cb('g', 'x', ap, 'f5.2', 'Packed Array ap:', 'i', ...
{''}, 'n', {''}, int64(80), int64(0));
f01vl example results
RFP Packed Array ar:
1 1.30
2 2.30
3 3.30
4 1.10
5 1.20
6 1.40
7 2.40
8 3.40
9 4.40
10 2.20
Packed Array ap:
1 1.10
2 1.20
3 2.20
4 1.30
5 2.30
6 3.30
7 1.40
8 2.40
9 3.40
10 4.40
PDF version (NAG web site
, 64-bit version, 64-bit version)
© The Numerical Algorithms Group Ltd, Oxford, UK. 2009–2015