#!/usr/bin/perl5 -w # this gets checked into /CM/scripts $today = `/bin/date +%Y.%m.%d`; $foo = `/home/jeneen/STAGING/bin/_sgi4/time_index -d in=$today`; $day = $foo - 2; print "$day\n"; $last = $day - 1; system("/home/jeneen/STAGING/script/mkmaps/fd_M_96m_make_1.5_eof.sh first=$day"); $SYNOPDIR = "/synoptic/eof"; $path = $ENV{'PATH'}; $ENV{'PATH'} = "/home/jeneen/STAGING/bin/_sgi4:$path"; $ENV{'IDL_DIR'} = "/usr/local/bin/idl"; open(PEQ, "/CM/bin/_sgi4/peq -A -w prog:mdi_eof,level:lev1.5,series:fd_M_96m_01d[$day]|") || die "$!\n"; while () { if (/^in_(\d+)_wd/) { ($foo, $foo, $dir) = split; chomp($dir); print "day = $day\n"; system("mkdir $SYNOPDIR/fd_M_96m_01d/fd_M_96m_01d.00$day"); system("rm -rf $SYNOPDIR/fd_M_96m_01d/fd_M_96m_01d.00$day/*"); system("cp $dir/* $SYNOPDIR/fd_M_96m_01d/fd_M_96m_01d.00$day"); system("mkdir $SYNOPDIR/fd_Mag_remap_01d/fd_Mag_remap_01d.00$day"); system("rm -rf $SYNOPDIR/fd_Mag_remap_01d/fd_Mag_remap_01d.00$day/*"); system("rm $SYNOPDIR/fd_Mag_remap_small_01d/fd_Mag_remap_small_01d.00$day"); system("mkdir $SYNOPDIR/fd_Mag_remap_small_01d/fd_Mag_remap_small_01d.00$day"); system("rm -rf $SYNOPDIR/fd_Mag_remap_small_01d/fd_Mag_remap_small_01d.00$day/*"); system("/CM/bin/_sgi4/v2helio z=1 MOFFSET=1 VCORLEV=0 MAPRMAX=0.994 MAPLGMAX=89.75 MAPLGMIN=-89.75 MAPBMAX=90 LGSHIFT=2 MAPMMAX=1800 SINBDIVS=540 in=$SYNOPDIR/fd_M_96m_01d/fd_M_96m_01d.00$day/ out=$SYNOPDIR/fd_Mag_remap_01d/fd_Mag_remap_01d.00$day/"); system("/home/jeneen/STAGING/bin/_sgi4/rebin_vds nx=359 ny=360 in=$SYNOPDIR/fd_Mag_remap_01d/fd_Mag_remap_01d.00$day/ out=$SYNOPDIR/fd_Mag_remap_small_01d/fd_Mag_remap_small_01d.00$day/"); system("/CM/bin/_sgi4/eofsynop qualmask=xxx in=$SYNOPDIR/fd_Mag_remap_small_01d/fd_Mag_remap_small_01d.00$day/ new=$SYNOPDIR/fits/eofsynop.00$day.fits old=$SYNOPDIR/fits/eofsynop.00$last.fits"); $last = $day; system("rm -rf $SYNOPDIR/fd_Mag_remap_01d/fd_Mag_remap_01d.00$day/*"); system("rmdir $SYNOPDIR/fd_Mag_remap_01d/fd_Mag_remap_01d.00$day/"); system("ingest -pa archive_hold=5 in=$SYNOPDIR/fd_Mag_remap_small_01d/fd_Mag_remap_small_01d.00$day/ out=prog:mdi_eof,level:remap,series:fd_Mag_360_01d\[$day]"); } } close(PEQ);