Commit 0fabb93e authored by thomas.forbriger's avatar thomas.forbriger
Browse files

[FEATURE] (issue7_refract): make offset dependent scaling more robust

- With the previous commits the average scaled amplitude in a given offset
  range is made the standard reference for amplitude scaling in modes 2 and 3.
- This commit makes sure that the scaling exponent will never become negative.

A negative scaling exponent would result in a singularity of scaled amplitudes
at zero offset. Since amplitudes always are expected to decay with offset,
negative exponents are not required for amplitude scaling.
parent c1fb5c89
......@@ -267,7 +267,7 @@ c ============================
c
if (optset(24)) plflag_linestyle=opt_Lcycle
if (optset(29)) plflag_color=opt_Ccycle
if (optset(46)) plpar_expo=opt_Sexp
if (optset(46)) plpar_expo=max(0.,opt_Sexp)
plpar_forceminoff=optset(53)
if (plpar_forceminoff) plpar_minoff=opt_Sminoff
if (optset(54)) plpar_radius=opt_Sradius
......
......@@ -381,7 +381,7 @@ c
flag_replot=.true.
elseif (plpar_pmmode.eq.3) then
if (verbose) print *,'reduce scaling exponent...'
plpar_expo=plpar_expo-0.08
plpar_expo=max(0.,plpar_expo-0.08)
call mpcfactors
flag_replot=.true.
else
......
......@@ -186,7 +186,7 @@ c
print *,' '
print *,'-Sx x1,x2 display offset range [x1,x2]'
print *,'-St t1,t2 display time range [t1,t2]'
print *,'-Se exp set scaling exponent'
print *,'-Se exp set scaling exponent (must not be negative)'
print *,'-Sa lev set scaling amplitude level'
print *,'-Sc lev set scaling clipping level'
print *,'-Sm mode set scaling mode'
......
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