#! /bin/sh # PATH="/bin:/usr/bin"; export PATH if [ -z "$1" ]; then echo "Usage: ${0}: fname" 1>&2; exit 1 fi f="$1" echo "$f.log -> $f.out" egrep ', n = |^real |^BV: 0 Node-' "$f.log" | while read x1 x2 x3 x4 x5 x6 x7 rest do read y1 y2 y3 y4 y5 y6 y7 rest if read z1 z2; then echo "$y7 $x4 $z2" fi done > "$f.out"