#! /bin/bash
# Last edited on 2011-05-28 21:55:21 by stolfi

# Adds 101 kPA to the core pressures (A and B) of all entries.

gawk \
  -v FS='|' \
  -v OFS='|' \
  ' /^201/{ 
      printf "%s | %s | %s", $1,$2,$3;
      printf " | %s", ($4+0 < 88888 ? $4 + 101 : $4);
      printf " | %s", ($5+0 < 88888 ? $5 + 101 : $5);
      for (i=6; i <= NF; i++) { printf " | %s", $(i); }
      printf "\n"; next;
    }
    // { print; }
  '
  
