F16UBF (PDF version)
F16 Chapter Contents
F16 Chapter Introduction
NAG Library Manual

NAG Library Routine Document


Note:  before using this routine, please read the Users' Note for your implementation to check the interpretation of bold italicised terms and other implementation-dependent details.

+ Contents

    1  Purpose
    7  Accuracy

1  Purpose

F16UBF calculates the value of the 1-norm, the -norm, the Frobenius norm or the maximum absolute value of the elements of a complex m by n band matrix stored in banded packed form.
It can also be used to compute the value of the 2-norm of a row n-vector or a column m-vector.

2  Specification

REAL (KIND=nag_wp) F16UBF

3  Description

Given a complex m by n band matrix, A, F16UBF calculates one of the values given by
A1=maxji=1maij (the 1-norm of A),
A=maxij= 1naij (the -norm of A),
AF=i=1mj=1n aij21/2 (the Frobenius norm of A),  or
maxi,jaij (the maximum absolute element value of A).
If m or n is 1 then additionally F16UBF can calculate the value A2=ai2 (the 2-norm of A).

4  References

Basic Linear Algebra Subprograms Technical (BLAST) Forum (2001) Basic Linear Algebra Subprograms Technical (BLAST) Forum Standard University of Tennessee, Knoxville, Tennessee http://www.netlib.org/blas/blast-forum/blas-report.pdf

5  Parameters

1:     INORM – INTEGERInput
On entry: specifies the value to be returned. The integer codes shown below can be replaced by the equivalent named constants of the form NAG_?_NORM. These named constants are available via the nag_library module and are also used in the example program for clarity.
The 1-norm.
The 2-norm of a row or column vector.
The Frobenius (or Euclidean) norm.
The -norm.
The value maxi,jaij (not a norm).
  • INORM=171, 173, 174, 175 or 177;
  • if INORM=173, M=1 or N=1.
2:     M – INTEGERInput
On entry: m, the number of rows of the matrix A. If M0 on input, F16UBF returns 0.
3:     N – INTEGERInput
On entry: n, the number of columns of the matrix A. If N0 on input, F16UBF returns 0.
4:     KL – INTEGERInput
On entry: kl, the number of subdiagonals within the band of A. If KL0 on input, F16UBF returns 0.
5:     KU – INTEGERInput
On entry: ku, the number of superdiagonals within the band of A. If KU0 on input, F16UBF returns 0.
6:     AB(LDAB,*) – COMPLEX (KIND=nag_wp) arrayInput
Note: the second dimension of the array AB must be at least max1,N.
On entry: the m by n band matrix A.
The matrix is stored in rows 1 to kl+ku+1, more precisely, the element Aij must be stored in
ABku+1+i-jj  for ​max1,j-kuiminm,j+kl.
7:     LDAB – INTEGERInput
On entry: the first dimension of the array AB as declared in the (sub)program from which F16UBF is called.
Constraint: LDABKL+KU+1.

6  Error Indicators and Warnings

If any constraint on an input parameter is violated, an error message is printed and program execution is terminated.

7  Accuracy

The BLAS standard requires accurate implementations which avoid unnecessary over/underflow (see Section 2.7 of Basic Linear Algebra Subprograms Technical (BLAST) Forum (2001)).

8  Further Comments


9  Example

Reads in a 6 by 4 banded complex matrix A with two subdiagonals and one superdiagonal, and prints the four norms of A.

9.1  Program Text

Program Text (f16ubfe.f90)

9.2  Program Data

Program Data (f16ubfe.d)

9.3  Program Results

Program Results (f16ubfe.r)

F16UBF (PDF version)
F16 Chapter Contents
F16 Chapter Introduction
NAG Library Manual

© The Numerical Algorithms Group Ltd, Oxford, UK. 2012