Extends a real symmetric matrix defined in its upper triangle to its lower triangle.
A — N by N symmetric matrix of order N to be filled out. (Input/Output)
N — Order of the matrix
A.
(Input)
Default: N = size
(A,2).
LDA — Leading
dimension of A
exactly as specified in the dimension statement of the calling
program. (Input)
Default: LDA = size
(A,1).
Generic: CALL CSFRG (A [,…])
Specific: The specific interface names are S_CSFRG and D_CSFRG.
Single: CALL CSFRG (N, A, LDA)
Double: The double precision name is DCSFRG.
The routine CSFRG converts an N ´ N matrix A in symmetric mode into a general matrix by filling in the lower triangular portion of A using the values defined in its upper triangular portion.
The lower triangular portion of a real 3 ´ 3 symmetric matrix is filled with the values defined in its upper triangular portion.
USE CSFRG_INT
USE WRRRN_INT
IMPLICIT NONE
! Declare variables
INTEGER LDA, N
PARAMETER (LDA=3, N=3)
!
REAL A(LDA,N)
! Set values for A
! A = ( 0.0 3.0 4.0 )
! ( 1.0 5.0 )
! ( 2.0 )
!
DATA A/3*0.0, 3.0, 1.0, 0.0, 4.0, 5.0, 2.0/
! Fill the lower portion of A
CALL CSFRG (A)
! Print results
CALL WRRRN ('A', A)
END
A
1 2
3
1 0.000 3.000 4.000
2
3.000 1.000 5.000
3 4.000
5.000 2.000
Visual Numerics, Inc. PHONE: 713.784.3131 FAX:713.781.9260 |