Commit 5724ee7f authored by thomas.forbriger's avatar thomas.forbriger
Browse files

[WP] (i20_gremlin_example): provide means to run gremlin

parent 0527c059
......@@ -19,7 +19,7 @@ FILETYPE=su
all:
flist: Makefile $(wildcard *.cfg) README COPYING
flist: Makefile $(wildcard *.cfg *.sh) README COPYING
echo $^ | tr ' ' '\n' | sort > $@
.PHONY: edit
......@@ -155,10 +155,16 @@ layer%.VP.mod.xxx: layer.VP.mod.cfg; /bin/cp -vpd $< $@
# calculate Fourier-Bessel expansion coefficients
# -----------------------------------------------
# apply Fourier-Bessel transformation
%.grn: %.$(FILETYPE)
gredax $< $@ -ty $(FILETYPE) -n 100 -s 3.5 -f 80. -t 0. -T 10. \
-1 -v -o
# apply normalization scaling
%.norm.grn: %.grn
/bin/rm -fv $@
grenorm $< $@ -v -l 0.7 -m 10 -a
# display Fourier-Bessel expansion coefficients
%.grn.ps: %.grn
export PGPLOT_PS_HEIGHT=7070 ; \
......@@ -191,6 +197,22 @@ layerLQ.VP.ini.pmod.xxx layerHQ.VP.ini.pmod.xxx: layer.VP.ini.pmod.cfg
# start gremlin
# -------------
.PHONY:
layerLQ.gpa.xxx layerHQ.gpa.xxx: layer.gpa.cfg
/bin/cp -vpd $< $@
# start gremlin
#
# %.pmod.xxx initial model
# %.mute.norm.grn Fourier-Bessel expansion coefficients
# %.tt.xxx P-wave arrival times
# %.gpa.xxx gremlin control parameters
#.PHONY: layerLQ.gremlin
#.PHONY: layerHQ.gremlin
#.PHONY: %.gremlin
%.gremlin: %.ini.pmod.xxx %.mute.norm.grn %.tt.xxx %.gpa.xxx
cat | gremlin -M $(word 1,$^) \
-G $(word 2,$^) \
-T $(word 3,$^) \
-P $(word 4,$^)
# ----- END OF Makefile -----
#!/bin/sh
# this is <gremlin.sh>
# ----------------------------------------------------------------------------
#
# Copyright (c) 2016 by Thomas Forbriger (BFO Schiltach)
#
# run gremlin on given test case
#
# REVISIONS and CHANGES
# 28/06/2016 V1.0 Thomas Forbriger
#
# ============================================================================
#
MODEL=$1.ini.pmod.xxx
COEFF=$1.mute.norm.grn
ARRIV=$1.tt.xxx
PARAM=$1.gpa.xxx
# create all necessary files by running make
make $MODEL $COEFF $ARRIV $PARAM || { echo "aborting..."; exit 2; }
# the initialize function allows to pass an initial command sequence to
# gremlin
initialize() {
cat << HERE
dda
spa
HERE
cat
}
# run gremlin
initialize | gremlin -M $MODEL -G $COEFF -T $ARRIV -P $PARAM
# ----- END OF gremlin.sh -----
Berkheim Festplatz Moden anpassen
fmin, fmax, smin, smax, xmax
8., 130., 0.5, 6.5, 0.110
balance, tt-error, greenerror, greenmode, logstretch
0.5 , 0.002, 0.2 , 1, 0.1
prefit, ttprefit
0, 4
halfspace, stepsize, master, finemodel
30., 0.10, 2, 80
source depth, amplitude, type
0., 1., 1
min/max Vp, Vs, rho , Qp, Qs
0.01, 0.01, 1.0, 1., 1.
5., 4.0, 2.5, 1000., 1000.
relative stepsize for partial derivative approximation
1.e-4
$Id$
03/05/2002 changed greenerror
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