14300 00 453 II>>t.IMAX 



14400 453 AMATRX(IMAX*2, II*1.)»-DX*B*YETW0( II ) 



14500 AMATRX(IMAX+2. IMAX*2)=0.0 



1460O C*NOW MUST INPUT THE BMATRX . 



14 700 SUMF1A=0.0 



14800 SUMF1B=0.0 



14900 DO 455 11 = 1, IMAX 



tSOOO SUMF 1B = 5UMF1B + XLAMB*0.6*DX»YEFIVE( II ) 



15100 DO 455 JJ=JBEGIN(II ) .UMAX 



15200 455 SUMF 1A = SUMF 1A-2. '(ZC II . JJ ) -B»DYTWO( II . dJ ) ) *DYTWO( 1 1 . JJ) 



15300 BMATRX ( 1 . 1 ) = - ( SUMF 1 A-SUMF IB) 



15400 DO 460 11=1. IMAX 



15500 SUMFII=0.0 



15600 DO 462 JJ = JBEGIN( I I ) . UMAX 



15700 462 SUMFII=SUMFI I +2 . • ( Z( I I , Jd ) -B'DYTWO(I I . JJ ) ) »EXPGN*B»DYM0NE( 1 1 , JU) 



15800 SUMF 11= SUMF I I +XLAMB*DX*B' YETWO( II ) 



15900 460 BMATRX( II+1 . 1 )=--SUMFII 



16000 SUMV=0.0 



16100 DO 465 11 = 1 . IMAX 



16200 465 SUMV = SUMV*-0.6*DX*B*YEFIVE(II ) 



16300 BMATRX ( IMAX + 2. 1 ) = - ( SUMV-VME AS ) 



16400 C*NEXT LET'S CALL THE MATRIX INVERSION ROUTINE VIA IMSL 



16500 CALL LE0T2F( AMATRX. 1 . IMAX+2.23,BMATRX,3,WKAREA,IER) 



16600 C*THE SOLN IS RETURNED IN THE VECTOR BMATRX 



16700 C'FINALLY. WE MUST UPDATE THE X VECTOR IN AX=B. 



16800 B=B+BMATRX( 1 , 1 ) 



16900 XLAMB=XLAMB+BMATRX( IMAX+2, 1 ) 



17000 DO 470 11=1 . IMAX 



17100 470 YDEL( II)=YDEL(II )+BMATRX(II+1. 1) 



17200 C'CHECK THE CRITERION FOR COMPLETION 



17300 SUMVEC=0.0 



17400 00 475 11=1 . IMAX 



17500 475 SUMVEC=SUMVEC+ABS(BMATRX( II , 1 ) ) 



17600 IF(SUMVEC.LT . (0. 1*( IMAX + 2) )) GO TO 11 



17700 WHITE(6.*/) B , 1 TER . ( I , YDEL( 1 ) , 1 - 1 . IMAX ) . XLAMB 



17800 10 CONTINUE 



17900 11 CONTINUE 



18000 C*LET'S WRITE IT ALL OUT. 



18100 WRITE(6,*/) ITER.B.(I.V0EL(I).I-1.IMAX) 



18200 STOP 



18300 END 



110 



