Документ взят из кэша поисковой машины. Адрес оригинального документа : http://foroff.phys.msu.ru/illposed/programs/Fig4_8.txt
Дата изменения: Mon Jul 7 00:04:43 2008
Дата индексирования: Mon Oct 1 22:05:15 2012
Кодировка:
Fig 4.8
=======



00001 IMPLICIT REAL*8(A-H,O-Z)
00002 IMPLICIT INTEGER*4(I-N)
00003 DIMENSION U0(41),Z(41),U(41,260),Z0(41)
00004 EXTERNAL AK
00005 X1=0.
00006 X2=1.
00007 Y1=-2.
00008 Y2=2.
00009 N=41
00010 M=41
00011 IMAX=100
00012 IC=1
00013 DL=0.
00014 C2=1.
00015 DO 1 J=1,N
00016 X=X1+(X2-X1)/(N-1.)*(J-1.)
00017 1 Z0(J)=1.-X*X
00018 CALL PTICR0(AK,U,X1,X2,Y1,Y2,N,M)
00019 CALL PTICR3(U,Z0,U0,N,M)
00020 DO 4 J=1,N
00021 Z(J)=0.5
00022 4 CONTINUE
00023 CALL PTILR(AK,U0,X1,X2,Y1,Y2,N,M,Z,AN,
*DL,ITER,IMAX,C2,IC,U,41*260,IERR)
00024 PRINT 5,Z0,Z,DL,AN,ITER,IERR
00025 STOP
00026 5 FORMAT(15X,'Exact solution:'/'.'/
* 8(5F11.6/),F11.6/'.'/
*15X,'Approximate solution:'/'.'/
* 8(5F11.6/),F11.6/'.'/
*10X,'Right side error square :',
* D14.6/
*10X,'Discrepancy :',
* D14.6/
*10X,'Number of iterations :',
* I14/
*10X,'Return code (IERR) :',
* I14)
00027 END


00001 FUNCTION AK(X,Y)
00002 IMPLICIT REAL*8(A-H,O-Z)
00003 IMPLICIT INTEGER*4(I-N)
00004 AK=1./(1.+100.*(X-Y)**2)
00005 RETURN
00006 END





Exact solution:

1.000000 .999375 .997500 .994375 .990000
.984375 .977500 .969375 .960000 .949375
.937500 .924375 .910000 .894375 .877500
.859375 .840000 .819375 .797500 .774375
.750000 .724375 .697500 .669375 .640000
.609375 .577500 .544375 .510000 .474375
.437500 .399375 .360000 .319375 .277500
.234375 .190000 .144375 .097500 .049375
.000000

Approximate solution:

1.000000 .999382 .997406 .994848 .989138
.983531 .983531 .961528 .961528 .948344
.948344 .912060 .912060 .894492 .894492
.835698 .835698 .835698 .808443 .752639
.752639 .728142 .728142 .628439 .628439
.609002 .584398 .584398 .584398 .386254
.386254 .386254 .386254 .361675 .307676
.183705 .183705 .159545 .095421 .048805
.000000

Right side error square : .000000D+00
Discrepancy : .442992D-15
Number of iterations : 100
Return code (IERR) : 3