Commit 26740641 authored by thomas.forbriger's avatar thomas.forbriger Committed by thomas.forbriger
Browse files

migrated chopmod to gfortran

This is a legacy commit from before 2015-03-01.
It may be incomplete as well as inconsistent.
See COPYING.legacy and README.history for details.


SVN Path:     http://gpitrsvn.gpi.uni-karlsruhe.de/repos/TFSoftware/trunk
SVN Revision: 4314
SVN UUID:     67feda4a-a26e-11df-9d6e-31afc202ad0c
parent 65d45c4f
......@@ -92,7 +92,8 @@
#
# ============================================================================
#
PROGRAMS= cmt2refmet momte queko rcvgen modrecipes flamops flamop gemmodpg
PROGRAMS= cmt2refmet momte queko rcvgen modrecipes flamops flamop gemmodpg \
chopmod
.PHONY: all
all: install
......@@ -160,9 +161,8 @@ flamops flamop gemmodpg: %: %.o
# $(CC) $< -o $@ -ltf -lrefread $(F2CLIB) -L$(LOCLIBDIR)
# newprog $@
#
# chopmod: %: %.o
# $(CC) $< -o $@ -ltf -lemod $(F2CLIB) -L$(LOCLIBDIR)
# newprog $@
chopmod: %: %.o
$(FC) $< -o $@ -ltf -lemod $(F2CLIB) -L$(LOCLIBDIR)
#
# resi ires: %: %.o
# $(CC) $< -o $@ -lsffu -lsff -ltf -ltime $(F2CLIB) -L$(LOCLIBDIR)
......
......@@ -35,10 +35,11 @@ c V1.5 09/02/97 introduced velocity reference frequency
c V1.6 14/02/97 introduced transform of velocties to dispersed velocities
c for a dominant period
c V1.7 17/03/99 provide different density transformations
c V1.8 22/12/11 migrated to gfortran
c
program chopmod
character*70 version
parameter(version='CHOPMOD V1.7 spherical --> flat earth')
parameter(version='CHOPMOD V1.8 spherical --> flat earth')
c----------------------------------------------------------------------
c
c STRATEGY
......@@ -116,7 +117,7 @@ c calculations
double precision zos, zus, zzo, zzu, zzm, rrm
double precision zualpha, zubeta, zurho, zsalpha, zsbeta, zsrho
c commandline
integer maxopt, lastarg, iargc
integer maxopt, lastarg
parameter(maxopt=9)
character*2 optid(maxopt)
character*40 optarg(maxopt)
......@@ -189,10 +190,10 @@ c set options
call tf_cmdline(1, lastarg,
& maxopt, optid, optarg, optset, opthasarg)
debug=optset(1)
read(optarg(2), '(f10)') stepsize
read(optarg(3), '(f10)') minradius
read(optarg(2), *) stepsize
read(optarg(3), *) minradius
replace=optset(4)
read(optarg(5), '(f10)') scanstep
read(optarg(5), *) scanstep
noefa=optset(6)
read(optarg(7), *) nuref
disperse=optset(8)
......@@ -227,7 +228,8 @@ c go through all sections of polynomal model and chop model
if (debug) print *,'DEBUG: depth range minz,minr,minrt',
& efa_z(R, minradius),minradius,efa_r(R, efa_z(R, minradius))
nlayer=0
do isec=nsection,1,-1
isec=nsection
do while (isec.ge.1)
insection=.true.
c top of section
if (noefa) then
......@@ -310,6 +312,7 @@ c reached radius limit?
rrr=efa_r(R, zu(nlayer))
endif
if (rrr.lt.minradius) isec=1
isec=isec-1
enddo
c----------------------------------------------------------------------
c go through all layers and evaluate parameter values
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment