00001 SUBROUTINE DDASLV (NEQ, DELTA, WM, IWM) 00002 C***BEGIN PROLOGUE DDASLV 00003 C***SUBSIDIARY 00004 C***PURPOSE Linear system solver for DDASSL. 00005 C***LIBRARY SLATEC (DASSL) 00006 C***TYPE DOUBLE PRECISION (SDASLV-S, DDASLV-D) 00007 C***AUTHOR PETZOLD, LINDA R., (LLNL) 00008 C***DESCRIPTION 00009 C----------------------------------------------------------------------- 00010 C THIS ROUTINE MANAGES THE SOLUTION OF THE LINEAR 00011 C SYSTEM ARISING IN THE NEWTON ITERATION. 00012 C MATRICES AND REAL TEMPORARY STORAGE AND 00013 C REAL INFORMATION ARE STORED IN THE ARRAY WM. 00014 C INTEGER MATRIX INFORMATION IS STORED IN 00015 C THE ARRAY IWM. 00016 C FOR A DENSE MATRIX, THE LAPACK ROUTINE 00017 C DGETRS IS CALLED. 00018 C FOR A BANDED MATRIX,THE LAPACK ROUTINE 00019 C DGBTRS IS CALLED. 00020 C----------------------------------------------------------------------- 00021 C***ROUTINES CALLED DGBTRS, DGETRF 00022 C***REVISION HISTORY (YYMMDD) 00023 C 830315 DATE WRITTEN 00024 C 901009 Finished conversion to SLATEC 4.0 format (F.N.Fritsch) 00025 C 901019 Merged changes made by C. Ulrich with SLATEC 4.0 format. 00026 C 901026 Added explicit declarations for all variables and minor 00027 C cosmetic changes to prologue. (FNF) 00028 C 020204 Convert to use LAPACK 00029 C***END PROLOGUE DDASLV 00030 C 00031 INTEGER NEQ, IWM(*) 00032 DOUBLE PRECISION DELTA(*), WM(*) 00033 C 00034 EXTERNAL DGBTRS, DGETRS 00035 C 00036 INTEGER LIPVT, LML, LMU, LMTYPE, MEBAND, MTYPE, NPD, INFO 00037 PARAMETER (NPD=1) 00038 PARAMETER (LML=1) 00039 PARAMETER (LMU=2) 00040 PARAMETER (LMTYPE=4) 00041 PARAMETER (LIPVT=22) 00042 C 00043 C***FIRST EXECUTABLE STATEMENT DDASLV 00044 MTYPE=IWM(LMTYPE) 00045 GO TO(100,100,300,400,400),MTYPE 00046 C 00047 C DENSE MATRIX 00048 100 CALL DGETRS('N', NEQ, 1, WM(NPD), NEQ, IWM(LIPVT), DELTA, NEQ, 00049 * INFO) 00050 RETURN 00051 C 00052 C DUMMY SECTION FOR MTYPE=3 00053 300 CONTINUE 00054 RETURN 00055 C 00056 C BANDED MATRIX 00057 400 MEBAND=2*IWM(LML)+IWM(LMU)+1 00058 CALL DGBTRS ('N', NEQ, IWM(LML), IWM(LMU), 1, WM(NPD), MEBAND, 00059 * IWM(LIPVT), DELTA, NEQ, INLPCK) 00060 RETURN 00061 C------END OF SUBROUTINE DDASLV------ 00062 END