dtblok Subroutine

subroutine dtblok(bloks, integs, nbloks, ipivot, iflag, detsgn, detlog)

************80

! DTBLOK gets the determinant of an almost block diagonal matrix.

Discussion:

The matrix's PLU factorization must have been obtained 
previously by FCBLOK.

The logarithm of the determinant is computed instead of the
determinant itself to avoid the danger of overflow or underflow
inherent in this calculation.

Modified:

14 February 2007

Author:

Carl DeBoor

Reference:

Carl DeBoor,
A Practical Guide to Splines,
Springer, 2001,
ISBN: 0387953663,
LC: QA1.A647.v27.

Parameters:

Input, real ( kind = 8 ) BLOKS(*), the factorization of A computed
by FCBLOK.

Input, integer ( kind = 4 ) INTEGS(3,NBLOKS), describes the block 
structure of A.

Input, integer ( kind = 4 ) NBLOKS, the number of blocks in A.

Input, integer ( kind = 4 ) IPIVOT(*), pivoting information.
The dimension of IPIVOT is the sum ( INTEGS(1,1:NBLOKS) ).

Input, integer ( kind = 4 ) IFLAG, = (-1)**(number of interchanges during
factorization) if successful, otherwise IFLAG = 0.

Output, real ( kind = 8 ) DETSGN, the sign of the determinant.

Output, real ( kind = 8 ) DETLOG, the natural logarithm of the 
determinant, if the determinant is not zero.  If the determinant
is 0, then DETLOG is returned as 0.

Arguments

Type IntentOptional Attributes Name
real(kind=8) :: bloks(*)
integer(kind=4) :: integs(3,nbloks)
integer(kind=4) :: nbloks
integer(kind=4) :: ipivot(1)
integer(kind=4) :: iflag
real(kind=8) :: detsgn
real(kind=8) :: detlog