!----------------------------------------------------------------- ! ! Purpose ! ======= ! ! LA_LANGE returns the value of the one norm, or the Frobenius norm, ! or the infinity norm, or the element of largest absolute value ! of a complex matrix A. ! ! Description ! =========== ! ! LA_LANGE returns the value ! ! LA_LANGE = ( max(abs(A(i,j))), NORM = 'M' or 'm' ! ( ! ( norm1(A), NORM = '1', 'O' or 'o' ! ( ! ( normI(A), NORM = 'I' or 'i' ! ( ! ( normF(A), NORM = 'F', 'f', 'E' or 'e' ! ! where norm1 denotes the one norm of a matrix (maximum column sum), ! normI denotes the infinity norm of a matrix (maximum row sum) and ! normF denotes the Frobenius norm of a matrix (square root of sum of ! squares). Note that max(abs(A(i,j))) is not a matrix norm. ! ! ========= ! ! FUNCTION LA_ANGE( A, NORM, INFO ) ! REAL() :: LA_ANGE ! (), INTENT(IN) :: ! CHARACTER(LEN=1), INTENT(IN), OPTIONAL :: NORM ! INTEGER, INTENT(OUT), OPTIONAL :: INFO ! ::= REAL | COMPLEX ! ::= KIND(1.0) | KIND(1.0D0) ! ::= A(:,:) | A(:) ! ! Arguments ! ========= ! ! A (input) COMPLEX array, shape either (:,:) or (:). ! If shape is (:,:) then SIZE(A,1) == m, SIZE(A,2) == n. ! If shape is (:) then SIZE(A) == n. ! If either m or n == 0 LA_LANGE is set to zero. ! The m by n matrix A. ! ! NORM (input) CHARACTER*1 ! Specifies the value to be returned in LA_LANGE as described ! above. ! ! INFO (output) INTEGER ! = 0: successful exit ! < 0: if INFO = -i, the i-th argument had an illegal value ! If INFO is not present and an error occurs, then the program is ! terminated with an error message. ! ! --------------------------------------------------------------------- .