*DECK ALDDLF
      SUBROUTINE ALDDLF (L4,ASS,MU1)
*
*-----------------------------------------------------------------------
*
* IN-PLACE L-D-L(T) FACTORIZATION OF A SYMMETRIC POSITIVE DEFINITE
* MATRIX IN COMPRESSED DIAGONAL STORAGE MODE.
* DOUBLE PRECISION VERSION.
*
* INPUT PARAMETERS:
*    L4 : ORDER OF THE COEFFICIENT MATRIX.
*   ASS : COEFFICIENT MATRIX IN COMPRESSED DIAGONAL STORAGE MODE.
*         A(I,J)=ASS(MU1(I)-I+J) IF J.LE.I AND J.GT.I+MU1(I-1)-MU1(I)
*               =A(J,I)          IF I.LT.J
*               =0.0             ELSE
*         DIMENSION ASS(MU1(L4)-MU1(1)+1)
*   MU1 : POSITION OF EACH DIAGONAL ELEMENT IN VECTOR ASS.
*         DIMENSION MU1(L4)
*
* OUTPUT PARAMETER:
*   ASS : LU FACTORS.
*
*-----------------------------------------------------------------------
*
      INTEGER L4,MU1(L4)
      DOUBLE PRECISION ASS(*),S,R
*
      ASS(MU1(1))=1.0D0/ASS(MU1(1))
      IF (L4.EQ.1) RETURN
      DO 10 K=2,L4
      K1=MU1(K)-K
      KM=MU1(K-1)+1-K1
      IF(KM+1.GT.K) GO TO 7
      DO 2 I=KM+1,K-1
      R=ASS(K1+I)
      ASS(K1+I)=0.0D0
      S=0.0D0
      I1=MU1(I)-I
      IM=MU1(I-1)+1-I1
      DO 5 J=MAX0(IM,KM),I
 5    S=S+ASS(K1+J)*ASS(I1+J)
 2    ASS(K1+I)=R-S
      S=0.0D0
      DO 6 I=KM,K-1
      R=ASS(K1+I)
      ASS(K1+I)=R*ASS(MU1(I))
 6    S=S+R*ASS(K1+I)
      ASS(MU1(K))=ASS(MU1(K))-S
 7    ASS(MU1(K))=1.0D0/ASS(MU1(K))
 10   CONTINUE
      RETURN
      END
