tbtu_regression.sh - pism - [fork] customized build of PISM, the parallel ice sheet model (tillflux branch) (HTM) git clone git://src.adamsgaard.dk/pism (DIR) Log (DIR) Files (DIR) Refs (DIR) LICENSE --- tbtu_regression.sh (998B) --- 1 #!/bin/bash 2 3 # PISMBedThermalUnit regression test using z=0 heat flux output of verification test K 4 5 PISM_PATH=$1 6 MPIEXEC=$2 7 PISM_SOURCE_DIR=$3 8 9 # List of files to remove when done: 10 files="foo-btu.nc foo-btu.nc~ btu_test_out.txt" 11 12 rm -f $files 13 14 set -e -x 15 16 OPTS="-verbose 1 -ys 0.0 -ye 1.0 -dt 0.1 -o foo-btu.nc" 17 18 # do stuff: test with a litho_temp state variable, and without 19 $PISM_PATH/btutest -Mbz 11 -Lbz 1000 $OPTS > btu_test_out.txt 20 $PISM_PATH/btutest -Mbz 1 $OPTS >> btu_test_out.txt 21 22 set +e 23 24 # Check results: 25 diff btu_test_out.txt - <<END-OF-OUTPUT 26 NUMERICAL ERRORS in upward heat flux at z=0 relative to exact solution: 27 bheatflx0 : max prcntmax av 28 0.0034644 11.2927879 0.0034644 29 NUM ERRORS DONE 30 NUMERICAL ERRORS in upward heat flux at z=0 relative to exact solution: 31 bheatflx0 : max prcntmax av 32 0.0113218 36.9052106 0.0113218 33 NUM ERRORS DONE 34 END-OF-OUTPUT 35 36 if [ $? != 0 ]; 37 then 38 exit 1 39 fi 40 41 rm -f $files; exit 0 42