subroutine cut i (af,mmcutht, m cstemht, cstand, o tstemht,tstand,tflat, m dstemht,dstand,dflat, i bflg) c + + + PURPOSE + + + c Process # 32 called from doeffect.for c c This subroutine performs the biomass manipulation of cutting c biomass. The component (either crop or a biomass pool) removed c is determined by flag which is set before the call to this c subroutine. The flag may contain any number of combinations c found below. c c Flags values (binary #'s actually) c bit no. decimal value c x - all standing material cut (0) c 0 - cut standing crop at cut height (1) c 1 - cut standing residue in decomp pool #1 (2) c 2 - cut standing residue in decomp pool #2 (4) c 3 - cut standing residue in decomp pool #3 (8) c c Note that biomass for any of these pools that are cut is transfered c to the cooresponding flat pool. c cutht must be positive for this process. c c + + + KEYWORDS + + + c cut, transfer, biomass manipulation include 'p1werm.inc' include 'p1unconv.inc' c c + + + ARGUMENT DECLARATIONS + + + c real af,mmcutht real cstemht,cstand real tstemht,tstand,tflat real dstemht(mnbpls),dstand(mnbpls),dflat(mnbpls) integer bflg c c + + + ARGUMENT DEFINITIONS + + + c c af - surface area fraction of biomass cut c mmcutht - above ground height standing crop and/or c residue is cut to (mm) c c cstemht - (crop pool) current crop height (m) c cstand - (crop pool) standing biomass (kg/m^2) c c tstemht - (temporary crop pool) stem height (m) c tstand - (temporary crop pool) standing biomass (kg/m^2) c tflat - (temporary crop pool) flat biomass (kg/m^2) c c dstemht - (decomp pool) biomass stem height by pool (m) c dstand - (decomp pool) standing biomass by age pool (kg/m^2) c dflat - (decomp pool) surface biomass by age pool (kg/m^2) c c bflg - flag indicating what to cut c 0 - All standing material is cut (both crop and residue) c 1 - Crop is cut c 2 - 1'st residue pool c 4 - 2'nd residue pool c 8 - 3'rd residue pool c Note that any combination of pools or crop may be used c A bit test is done on the binary number to see what to modify c c + + + ACCESSED COMMON BLOCK VARIABLE DEFINITIONS + + + c c mnbpls - max number of decomposition pools (currently=3) c c + + + PARAMETERS + + + c c + + + LOCAL VARIABLES + + + c integer i integer tflg real cutht c c + + + LOCAL VARIABLE DEFINITIONS + + + c c i - loop variable for decomp pools (3 pools total) c tflg - temporary biomass flag c + + + END SPECIFICATIONS + + + c set tflg bits correctly for "all" pools if bflg=0 if (bflg .eq. 0) then bflg = 1 ! crop pool do 10 i=1,mnbpls tflg = tflg + 2**i ! decomp pools 10 continue else tflg = bflg endif !NOTE: mmcutht is currently in "mm", so we must convert it !to "m" here first - LEW cutht = mmcutht*mmtom C*** print *, 'cut tflg/bflg: ', tflg, bflg C*** print *, 'tflat before cutting: ', tflat C*** print *, 'cutht/cstemht/tstemht: ', cutht,cstemht,tstemht if (BTEST(tflg,0)) then if (cutht.lt.cstemht) then ! cut crop pool tflat = tflat+af* & cstand*(1.0-(cutht/cstemht)) tstand = cstand*(1.0-af*cutht/cstemht) cstemht = cutht endif if (cutht.lt.tstemht) then ! cut temporary crop pool tflat = tflat+af* & tstand*(1.0-(cutht/tstemht)) tstand = tstand*(1.0-af*cutht/tstemht) tstemht = cutht endif if ((cutht.ge.cstemht) .and. (cutht.ge.tstemht)) then ! no crop to cut C*** print *, 'No crop biomass to cut', cutht, cstemht, tstemht endif endif C*** print *, 'tflat after cutting: ', tflat C*** print *, 'cutht/cstemht/tstemht: ', cutht,cstemht,tstemht c Now need to check and see if we need to cut the decomp pools (1-3) c for each individual pool check to see if there is biomass above the c proposed cut height, if so, adjust the pool as necessary. do 40 i=1,mnbpls if (BTEST(tflg,i)) then ! cut specified decomp pool residue if (cutht.lt.dstemht(i)) then dflat(i) = dflat(i)+af*dstand(i)* & (1.0-af*cutht/dstemht(i)) dstand(i) = dstand(i)*(1.0-af*cutht/dstemht(i)) dstemht(i) = cutht C*** if (dflat(i).lt.0.0) dflat(i)=0.0 C*** if (dstand(i).lt.0.0) dstand(i)=0.0 C*** if (dstemht(i).lt.0.0) dstemht(i)=0.0 else C*** print *, 'Nothing to cut in decomp pool',i endif endif 40 continue end