/************************************************************* /* PURPOSE: Calculate the net flux of runoff out of Texas /* /* INPUTS: txmsk3 is a grid with 1's in Texas and 0's outside of /* Texas; txfdmod is a flow direction grid; flowsac3 is a flow /* accumulation grid /* /*************************************************************** DOCELL if (txmsk3 eq 1) then begin if (txfdmod eq 1) then if (txmsk3(1,0) eq 0) then fluxgrid = -1 * ( /home/seann/texas/precip/flowsac3 ) else fluxgrid = 0 if (txfdmod eq 2) then if (txmsk3(1,1) eq 0) then fluxgrid = -1 * ( /home/seann/texas/precip/flowsac3 ) else fluxgrid = 0 if (txfdmod eq 4) then if (txmsk3(0,1) eq 0) then fluxgrid = -1 * ( /home/seann/texas/precip/flowsac3 ) else fluxgrid = 0 if (txfdmod eq 8) then if (txmsk3(-1,1) eq 0) then fluxgrid = -1 * ( /home/seann/texas/precip/flowsac3 ) else fluxgrid = 0 if (txfdmod eq 16) then if (txmsk3(-1,0) eq 0) then fluxgrid = -1 * ( /home/seann/texas/precip/flowsac3 ) else fluxgrid = 0 if (txfdmod eq 32) then if (txmsk3(-1,-1) eq 0) then fluxgrid = -1 * ( /home/seann/texas/precip/flowsac3 ) else fluxgrid = 0 if (txfdmod eq 64) then if (txmsk3(0,-1) eq 0) then fluxgrid = -1 * ( /home/seann/texas/precip/flowsac3 ) else fluxgrid = 0 if (txfdmod eq 128) then if (txmsk3(1,-1) eq 0) then fluxgrid = -1 * ( /home/seann/texas/precip/flowsac3 ) else fluxgrid = 0 end if (txmsk3 eq 0) then begin if (txfdmod eq 1) then if (txmsk3(1,0) eq 1) then fluxgrid = /home/seann/texas/precip/flowsac3 else fluxgrid = 0 if (txfdmod eq 2) then if (txmsk3(1,1) eq 1) then fluxgrid = /home/seann/texas/precip/flowsac3 else fluxgrid = 0 if (txfdmod eq 4) then if (txmsk3(0,1) eq 1) then fluxgrid = /home/seann/texas/precip/flowsac3 else fluxgrid = 0 if (txfdmod eq 8) then if (txmsk3(-1,1) eq 1) then fluxgrid = /home/seann/texas/precip/flowsac3 else fluxgrid = 0 if (txfdmod eq 16) then if (txmsk3(-1,0) eq 1) then fluxgrid = /home/seann/texas/precip/flowsac3 else fluxgrid = 0 if (txfdmod eq 32) then if (txmsk3(-1,-1) eq 1) then fluxgrid = /home/seann/texas/precip/flowsac3 else fluxgrid = 0 if (txfdmod eq 64) then if (txmsk3(0,-1) eq 1) then fluxgrid = /home/seann/texas/precip/flowsac3 else fluxgrid = 0 if (txfdmod eq 128) then if (txmsk3(1,-1) eq 1) then fluxgrid = /home/seann/texas/precip/flowsac3 else fluxgrid = 0 end END /*&type netflux /*quit /*quit /*flux = scalar(0) /*DOCELL /* flux += fluxgrid /*END /*show flux &return