1
C/MEMBR ADD NAME=BNORM,SSI=0
2
double precision function bnorm (n, a, nra, ml, mu, w)
4
c-----------------------------------------------------------------------
6
c this function computes the norm of a banded n by n matrix,
7
c stored in the array a, that is consistent with the weighted max-norm
8
c on vectors, with weights stored in the array w.
9
c ml and mu are the lower and upper half-bandwidths of the matrix.
10
c nra is the first dimension of the a array, nra .ge. ml+mu+1.
11
c in terms of the matrix elements a(i,j), the norm is given by..
12
c bnorm = max(i=1,...,n) ( w(i) * sum(j=1,...,n) abs(a(i,j))/w(j) )
14
c-----------------------------------------------------------------------
15
integer n, nra, ml, mu
16
integer i, i1, jlo, jhi, j
18
double precision an, sum
19
dimension a(nra,n), w(n)
27
10 sum = sum + abs(a(i1-j,j))/w(j)
32
c----------------------- end of function bnorm -------------------------