hypre/test/TEST_ij/coarsening.sh
falgout bdf887ff01 Added prints of iterations and residual for BoomerAMG to ij (same as in new_ij).
Fixed regression tests due to the changed output.
2012-10-19 15:41:49 +00:00

63 lines
1.7 KiB
Bash
Executable File

#!/bin/sh
#BHEADER**********************************************************************
# Copyright (c) 2008, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
# This file is part of HYPRE. See file COPYRIGHT for details.
#
# HYPRE is free software; you can redistribute it and/or modify it under the
# terms of the GNU Lesser General Public License (as published by the Free
# Software Foundation) version 2.1 dated February 1999.
#
# $Revision$
#EHEADER**********************************************************************
TNAME=`basename $0 .sh`
#=============================================================================
# compare with baseline case
#=============================================================================
FILES="\
${TNAME}.out.0\
${TNAME}.out.1\
${TNAME}.out.2\
${TNAME}.out.3\
${TNAME}.out.4\
${TNAME}.out.5\
"
for i in $FILES
do
echo "# Output file: $i"
tail -21 $i | head -6
done > ${TNAME}.out
FILES="\
${TNAME}.out.6\
${TNAME}.out.7\
"
for i in $FILES
do
echo "# Output file: $i"
tail -3 $i
done >> ${TNAME}.out
# Make sure that the output files are reasonable
CHECK_LINE="Complexity"
OUT_COUNT=`grep "$CHECK_LINE" ${TNAME}.out | wc -l`
SAVED_COUNT=`grep "$CHECK_LINE" ${TNAME}.saved | wc -l`
if [ "$OUT_COUNT" != "$SAVED_COUNT" ]; then
echo "Incorrect number of \"$CHECK_LINE\" lines in ${TNAME}.out" >&2
fi
if [ -z $HYPRE_NO_SAVED ]; then
diff -U3 -bI"time" ${TNAME}.saved ${TNAME}.out >&2
fi
#=============================================================================
# remove temporary files
#=============================================================================
rm -f ${TNAME}.testdata* ${TNAME}.testdata.tmp0