#!/bin/csh

foreach i (chl.*.hdf)
   echo $i
   set j=$i:r
   set k=$j:e
#   echo $k
   mv $i chlor.$k.hdf
end

echo " "
ls -1 chlor*hdf
