tt3d.f ---- calculates 3-D mantle corrections for model S&P12/WM13, crustal corrections, and ellipticity corrections for any given source-receiver pair, and any phase from: P,S,*PP(pP),PKIKP,PKPAB,PKPBC, or SKS. call changephase(stlat,stlong,xlat,xlon,realdep,phase,residual2,ttime2,ecorr) call calccrust(stlat,stlong,xlat,xlon,realdep,phase,rother2,ttime2) ------------------------------------------------------------------- subroutine(s) includded in Harvard\lib Fortran code File: source Code File/Including subroutine(s)/Call Subroutine(s) ------------------------------------------------------------------- residual.h parameter (maxl=20,maxk=13,inc=180) parameter (maxk1 = maxk+1, maxl1=maxl+1) calccrust.f subroutine calccrust(stlat,stlong,xlat,xlon,realdep,phase,rother2,ttime2) call setupprem(realdep,rtime,cdep,rtime2,rdepthdiff,phase) call crusttables(i,cdep,phase) call crustgetcoeff(0,nrad,nang,c,phase) call ccol(nrad,nang,c,cvec(nmod+1),nc) call deltaz(xlat,xlon,stlat,stlong,delta2,azep2,azst2) call premtime(realdep,delta2,phase,ttime,pray,dtddep, 1 xlat,xlon,stlat,stlong,rdlat,rdlon,rddep, 2 cvec,c,amat,num,numtab,nc,nmod,rother2,rtime,rtime2, 3 rdepthdiff) changephase.f subroutine changephase(stlat,stlong,xlat,xlon,realdep,phase,residual2,ttime2,ecorr) call setupprem(realdep,rtime,cdep,rtime2,rdepthdiff,phase) call tables(i,cdep,phase) call getcoeff(0,nrad,nang,c,phase) call ccol(nrad,nang,c,cvec(nmod+1),nc) call premtime(realdep,delta2,phase,ttime,pray,dtddep, 1 xlat,xlon,stlat,stlong,rdlat,rdlon,rddep, 2 cvec,c,amat,num,numtab,nc,nmod,residual2,rtime,rtime2, 3 rdepthdiff) call ellipall(phasetemp,xlat,xlon,stlat,stlong,realdep2,ecorr,ierr) call ellipt (xlat,realdep2,delta2,azep2,ecorr,ipha) delazc.f subroutine deltaz(eplat,eplong,stlat,stlong,delta,azep,azst) ellipall.f subroutine ellipall(phase,eqlat,eqlong,stlat,stlong,depth,ellip,ierr) ellipt.f subroutine ellipt (rlat,depth,deltain,azim,ecorr,ips) interactivecrust.f subroutine crusttables(itab,cdep,phase) call splneq(ntab(itab),tb(1,j,i,itab),sd(1,j,i,itab)) subroutine crustgetcoeff(iopt,irad,iang,c,phase) call hrvmod(iumlm,irad,iang,c) call readcrust(8,iang,c) subroutine readcrust(io,iang,c) prem1f.f subroutine prem1(realdep,delta2,phase,ttime,pray,dtddep,rtime) prem2all.f subroutine faster(cvec,c,amat,num,numtab,nc,nmod,res,slat,slon,elat,elon,edep) call halphak(ii,irad(ii),iang(ii),sth1,sph1,rth1,rph1,amat(ncol+1),nc,ierr) call dot(amat,cvec,ncol,dotp) subroutine tables(itab,cdep,phase) call splneq(ntab(itab),tb(1,j,i,itab),sd(1,j,i,itab)) subroutine getcoeff(iopt,irad,iang,c,phase) call hrvmod(iumlm,irad,iang,c) subroutine ccol(irad,iang,c,cvec,ncol) subroutine halphak(itab,irad,iang,sth,sph,rth,rph,amat,ncol,ierr) call eulerf(sth,sph,rth,rph,alpha,beta,gamma,del,pth,pph) call evali(itab,jfun,dd,valr(1,jfun),vali(1,jfun),ierr) call djx(L,beta,dj,x) call yrot(l,dj,x,valr(1,jfun),vali(1,jfun),ansr,ansi) subroutine dot(a,c,ncol,dotp) real function geocen(arg) subroutine eulerf(sth,sph,rth,rph,alpha,beta,gamma,del,pth,pph) call cart(sth,sph,sx,sy,sz) call cross(sx,sy,sz,rx,ry,rz,px,py,pz) subroutine splneq(nn,u,s) subroutine djx(l,beta,dj,x) call djbeta(l,beta,dj,l21) subroutine yrot(l,dj,x,valr,vali,ansr,ansi) subroutine djbeta(j,beta,dj,nr) subroutine evali(itab,jfunc,ang,valr,vali,ierr) valr(ind)=eval(y,ntab(itab),tb(1,i,jfunc,itab),sd(1,i,jfunc,itab)) subroutine hrvmod(iumlm,irad,iang,c) subroutine cross(sx,sy,sz,rx,ry,rz,px,py,pz) function eval(y,nn,u,s) subroutine cart(thet,phi,x,y,z) character*80 function gname(prompt) prem3f.f subroutine prem3(realdep,delta2,phase,ttime,pray,dtddep,rtime) premtime7f.f subroutine premtime(realdep,delta2,phase,ttime,pray,dtddep, call prem1(realdep,delta2,phase,ttime,pray,dtddep,rtime) call faster(cvec,c,amat,num,numtab,nc,nmod,residual2, 1 slat,slon,xlat,xlon,realdep) call prem3(realdep2,delta2,phase,ttime2,pray,dtddep,rtime2) call deltaz(xlat2,xlon,slat,slon,delta3,azep3,azst3) setupprem3.f subroutine setupprem(realdep,rtime,cdep,rtime2,rdepthdiff,phase) cdep=levels(ilo)