SCULIB_GAUSSJ

Numerical Recipes in Fortran routine for solution of linear equations by Gauss-Jordan elimination

Description:

Linear equation solution by Gauss-Jordan elimination. A(1:N,1:N) is an input matrix stored in an array of physical dimensions NP by NP. B(1:N,1:M) is an input matrix containing the M right-hand side vectors, stored in an array of physical dimensions NP by MP. On output, A(1:N,1:N) is replaced by its matrix inverse and B(1:N,1:M) is replaced by the corresponding set of solution vectors. Parameter NMAX is the largest anticipated value of N. Copied from GAUSSJ on p.30 of Numerical Recipes in Fortran, with STATUS added.

Invocation

CALL SCULIB_GAUSSJ (A, N, NP, B, M, MP, STATUS)

Arguments

A ( NP, NP ) = REAL (Given & Returned)
Input matrix. On exit, contains its inverse.
N = INTEGER (Given)
Required size of A ( < NP)
NP = INTEGER (Given)
Dimensions of input matrix.
B ( NP, MP) = REAL (Given & Returned)
Input matrix containing M right-hand side vectors. On exit, contains the solution vectors.
M = INTEGER (Given)
Required size of B. ( < MP)
MP = INTEGER (Given)
Size of second dimension of B.
STATUS = INTEGER (Given & Returned)
Global status.

Copyright

Copyright ©1995,1996,1997,1998,1999 Particle Physics and Astronomy Research Council. All Rights Reserved.