8 # ------------------------------------------------------------------------------------------
10 # Utility script to test JGraph2D, JFit2D and JPlot2D.
12 # ------------------------------------------------------------------------------------------
15 if [ -z $JPP_DIR ];
then
16 echo "Variable JPP_DIR undefined."
21 source $JPP_DIR/setenv.sh $JPP_DIR
29 usage "$script [working directory]"
51 echo $(( $TOP *
exp(-0.5*(($X - $X0)/$SIGMA)**2) *
exp(-0.5*(($Y - $Y0)/$SIGMA)**2) ))
56 for ((
X = -3.0; $X <= +3.5;
X += 1.0 ));
do
57 for ((
Y = -3.0; $Y <= +3.5;
Y += 1.0 ));
do
60 let
"V = `$JPP_DIR/examples/JMath/getPoisson -e $U`"
62 printf
"%7.3f %7.3f %7.3f\n" $X $Y $V >>
$WORKDIR/$GRAPH_TXT
73 set_variable FORMULA "[0] * exp(-0.5 * (x-[1])*(x-[1]) / ([2]*[2])) * exp(-0.5 * (y-[3])*(y-[3]) / ([4]*[4]))"
then JLigier sh continue fi cat
o $QUALITY_ROOT d $DEBUG!CHECK_EXIT_CODE JPlot1D f
then fatal Wrong number of arguments fi set_variable STRING $argv[1] set_variable DETECTORXY_TXT $WORKDIR $DETECTORXY_TXT tail read X Y CHI2 RMS printf optimum n $X $Y $CHI2 $RMS awk v Y
then fatal Wrong number of arguments fi JConvertDetectorFormat a o
*fatal Wrong number of arguments esac set_variable GRAPH_TXT
then echo Variable JPP_DIR undefined exit fi source $JPP_DIR setenv sh $JPP_DIR if do_usage *then usage $script[(input file)+] fi set_variable DEBUG set_variable WORKDIR TMPDIR
then echo Variable JPP_DIR undefined exit fi source $JPP_DIR setenv sh $JPP_DIR &dev null set_variable
then echo Variable JPP_DIR undefined exit fi source $JPP_DIR setenv sh $JPP_DIR &dev null set_variable DEBUG set_variable WORKDIR
then fatal The output file must have the wildcard in the e g root fi eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY JAcoustics sh $DETECTOR_ID source JAcousticsToolkit sh CHECK_EXIT_CODE typeset A EMITTERS get_tripods $WORKDIR tripod txt EMITTERS get_transmitters $WORKDIR transmitter txt EMITTERS for EMITTER in
no fit printf nominal n $STRING awk v X
then fatal Wrong number of arguments fi set_variable DETECTOR $argv[1] set_variable STRING $argv[2] set_array QUANTILES set_variable FORMULA *[0] exp(-0.5 *(x-[1])*(x-[1])/([2]*[2]))" set_variable MODULE `getModule -a $DETECTOR -L "$STRING 0"` source JAcousticsToolkit.sh typeset -A TRIPODS get_tripods $WORKDIR/tripod.txt TRIPODS XMEAN
then getFile sh $JPP_ARCHIVE $DETECTOR_ID $RUNS[1] $KEY $VERSION $WORKDIR
esac $JPP_BIN JLogger sh $LOGGER until pgrep JGetMessage</dev/null > dev null
#define DEBUG(A)
Message macros.