From 404f55cd0f16e899b184c3a0a4ca812a4f4abd88 Mon Sep 17 00:00:00 2001 From: Hongjian Fang Date: Sat, 12 Jan 2019 12:56:08 -0500 Subject: [PATCH] comment some unnecessary warnings before vorotomo --- src/CalSurfG.f90 | 5 +++-- src/main.f90 | 28 +++++++++++++++++----------- 2 files changed, 20 insertions(+), 13 deletions(-) diff --git a/src/CalSurfG.f90 b/src/CalSurfG.f90 index 470ccc4..a01e6f8 100644 --- a/src/CalSurfG.f90 +++ b/src/CalSurfG.f90 @@ -1030,8 +1030,8 @@ subroutine CalSurfG(nx,ny,nz,nparpi,vels,iw,rw,col,dsurf, & integer writepath integer ig, igroup - gdx=5 - gdz=5 + gdx=8 + gdz=8 asgr=1 sgdl=8 sgs=8 @@ -1282,6 +1282,7 @@ subroutine CalSurfG(nx,ny,nz,nparpi,vels,iw,rw,col,dsurf, & ALLOCATE(ttnr(idm2,idm1)) ALLOCATE(nstsr(idm2,idm1)) ENDIF + !ttnr(1:nnzb,1:nnxb)=ttn(1:nnzb,1:nnxb) ttnr=ttn nstsr=nsts ogx=vnl diff --git a/src/main.f90 b/src/main.f90 index 57c3b4c..b5f0906 100644 --- a/src/main.f90 +++ b/src/main.f90 @@ -99,7 +99,7 @@ program SurfTomo integer writepath real averdws real maxnorm - real threshold,threshold0 + real threshold0 ! FOR MODEL VARIATION !------------------------------------------------ @@ -431,7 +431,7 @@ program SurfTomo enddo averdws=averdws/maxvp write(66,*)'Maximum and Average DWS values:',maxnorm,averdws - write(66,*)'Threshold is:',threshold + !write(66,*)'Threshold is:',threshold ! WRITE OUT RESIDUAL FOR THE FIRST AND LAST ITERATION if(iter.eq.1) then @@ -514,10 +514,10 @@ program SurfTomo leniw = 2*nar+1 lenrw = nar dv = 0 - atol = 1e-3 - btol = 1e-3 - conlim = 1200 - itnlim = 1000 + atol = 1e-4 + btol = 1e-4 + conlim = 100 + itnlim = 400 istop = 0 anorm = 0.0 acond = 0.0 @@ -528,8 +528,15 @@ program SurfTomo call LSMR(m, n, leniw, lenrw,iw,rw,cbst, damp,& atol, btol, conlim, itnlim, localSize, nout,& dv, istop, itn, anorm, acond, rnorm, arnorm, xnorm) - if(istop==3) print*,'istop = 3, large condition number' + !if(istop==3) print*,'istop = 3, large condition number' + mean = sum(cbst(1:dall))/dall + std_devs = sqrt(sum(cbst(1:dall)**2)/dall - mean**2) + write(*,'(i2,a)'),iter,'th iteration...' + write(*,'(a,f7.3)'),'weight is:',weight + write(*,'(a,f8.1,a,f8.2,a,f8.3)'),'mean,std_devs and rms of & + residual after weighting: ',mean*1000,'ms ',1000*std_devs,'ms ',& + dnrm2(dall,cbst,1)/sqrt(real(dall)) do i =1,dall cbst(i)=cbst(i)/datweight(i) @@ -537,10 +544,9 @@ program SurfTomo mean = sum(cbst(1:dall))/dall std_devs = sqrt(sum(cbst(1:dall)**2)/dall - mean**2) - write(*,'(i2,a)'),iter,'th iteration...' - write(*,'(a,f7.3)'),'weight is:',weight - write(*,'(a,f8.1,a,f8.2,a,f8.3)'),'mean,std_devs and rms of & - residual: ',mean*1000,'ms ',1000*std_devs,'ms ',& + !write(*,'(i2,a)'),iter,'th iteration...' + !write(*,'(a,f7.3)'),'weight is:',weight + write(*,'(a,f8.1,a,f8.2,a,f8.3)'),'residual before weighting: ',mean*1000,'ms ',1000*std_devs,'ms ',& dnrm2(dall,cbst,1)/sqrt(real(dall)) write(66,'(i2,a)'),iter,'th iteration...' write(66,'(a,f7.3)'),'weight is:',weight