-
Notifications
You must be signed in to change notification settings - Fork 1
/
CSP_GROW_CANE.FOR
1672 lines (1413 loc) · 71.5 KB
/
CSP_GROW_CANE.FOR
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
C=======================================================================
C CSP_GROW_CANE, Growth subroutine for CASUPRO sugarcane model, based
C on GROW Subroutine, J.W. Jones, F.S. Royce, O.H. Daza.
C-----------------------------------------------------------------------
C Growth and Development of Sugarcane
C-----------------------------------------------------------------------
C REVISION HISTORY
C 06/15/2005 FSR Written.
C 10/07/2005 FSR Modified for stalk-based photosynthesis
C 06/30/2010 FSR Added PLF2 variable for CASUPRO
C-----------------------------------------------------------------------
! Called by: CASUPRO
! Calls:
C=======================================================================
SUBROUTINE CSP_GROW_CANE(CONTROL, DYNAMIC,
& CAB, CropTypeCode, DeltaLeafArea, !AGEFAC,!Input
& DeltaLeafNum, DTPI, ECONO, EXCESS, FILEIO, FILECC, !Input
& FILEGC, FINREF, FRSU, GAMMA, GRLF, GRRT, GRST, !Input
& GRSU, KCAN,Kill, LeafNum, MAINTR, NLAYR, NVEG0, !Input
& PAR, PgAvalPD, PGAVAL, PgRatio, PhenoStage, !Input
& PLTPOP, PLF1, PLF2, PLWT, ROWSPC, SLA, !Input
& SLAMIN, SLAMAX, SLAPAR, SLAREF, !Input
& LSFAC, SENRT, SLDOT, Smax, SRDOT, StkHrNO, StalkState, !Input
& StkB, StkM, SumTTStalk, TGRO, !Input
& TURFAC, TURSLA, WEATHER, XDAY, XFRRT, !Input
& XFRSU, XLAI, XLAIlost, XSLATM, XSTKRT, XVSHT, YFRRT, !Input
& YFRSU, YRDOY, YRPLT, YSLA, YSTKRT, YVSHT, ZVSDI, !Input
& CDEM, FRRT, TOTWT, TOTALWT, XHLAI, YSLATM, !Input/Output
& BRDMD, CANHT, CANWH, CountStalk, DeltaLeafArealost, !Output
& LAIMX, LAIXD, LeafArea, LeafArealost, LeafAreaPlant, !Output
& LFWT, LFWTHa, LSWTlost, LSWT, LSWTHa, LFWTHalost, !Output
& LFWTlost, LSWTHalost, StkH2OFac, STKmntDEF, !Output
& RTDWP, RTWTHa, SENESCE, StalkPopul, STKWT, STKFWT, !Output
& STKFWTHa, STKWTHa, STKWTHalost, STKWTP, SuDEF, !Output
& SuH2OFac, SUWT, SUWTHa, TOPWT) !Output
!-----------------------------------------------------------------------
USE ModuleDefs !Definitions of constructed variable types,
! which contain control information, soil
! parameters, hourly weather data.
! NL defined in ModuleDefs.for
USE ModuleData
IMPLICIT NONE
SAVE
!-----------------------------------------------------------------------
CHARACTER*1 RNMODE
CHARACTER*4 StalkState(NumOfStalks,10)
!CHARACTER(11) :: CropTypeName
CHARACTER*30 FILEIO
CHARACTER*92 FILECC, FILEGC
CHARACTER*6 ECONO
INTEGER CAB, CountStalk, CropTypeCode
INTEGER DAP, DAS, Day, DOY, DYNAMIC, H, I, L
INTEGER LAIXD, LUNCRP, NLAYR, NVEG0, OpenStatus
INTEGER PhenoStage, REPNO, RUN, Smax, Stalk, TIMDIF
INTEGER XDAY(6), YEAR, YRDOY, YRPLT, YRSIM, CGLUN
INTEGER, DIMENSION(1:NumOfStalks) :: Kill
REAL BRDMD, CANHT, CANWH, CAVLF, CAVR, CDEF, DTPI, FRRT
REAL DUMFACF, FFVEG, FINREF, FRACSH, FRSU, FVEG, LAIMX
REAL GAMMA, GRLF, GRLS, GRRT, GRST, GRSU, KCAN, LAIMX_Previous
REAL LSFAC, PARSLA, PgAvalPD, PLF1, PLF2, PLTPOP, PLWT, RFPSTKG
REAL RootFac, ROWSPC, SeedCH2O, ShootCTotDem, ShootCTotSup
REAL SLA, SLAMAX, SLAMX, SLAMIN, SLAMN
REAL Stk_H2O, StkHrNO, SLAPAR, SRDOT
REAL STK, StkB, STKDMC, STKDWtmp, StkH2OFac, StkM, SUDWtmp
REAL SumLfWt, SumLSWt, SumRtWt, SuH2OFac
REAL SumStkTiWt, SumStkSuWt, TPHFAC, TURFAC, TURFSL
REAL TURSLA, XHLAI, XLAI, XLAIlost
REAL PAR, xTEMP
! REAL AGEFAC, ,PGAVL, DTX
REAL SLAREF, SLAVAR, StkEx, SuEx, TOPWT, TOTWT, VSTAGE
REAL WholeLeaf
REAL XFRRT(4), XFRSU(4), YFRRT(4), YFRSU(4), YSLA(6)
REAL TGRO(TS), XSLATM(10), XSTKRT(6), YSLATM(10), YSTKRT(6)
REAL XVSHT(10), YVSHT(10), ZVSDI(10)
REAL TABEX ! Function subroutine - Lookup utility
! REAL SIZELF, SIZREF, , SLNDOT
REAL DAYS(6)
REAL, DIMENSION(0:NumOfDays) :: CDEM,
& LeafAreaPlant, LeafAreaPlantlost,
& LFDWHalost, LSDWHalost, LFWTHa, LFWTHalost,
& LFWTP, LSWTP,
& LSWTHa, LSWTHalost, LFWTPlost, LSWTPlost, RTDWP,
& RTWTHa, RTWTP, RTWTP2, SenesHa,
& StalkPopul, STKDWHalost, STKFWTHa,
& STKWTHa, STKWTHalost,
& STKWTPlost, STKFWTP, STKWTP, SUWTHa, SUWTP
REAL, DIMENSION(1:NumOfStalks) :: EXCESS, GroDEF,
& MAINTR, PGAVAL, PGLEFT, PgRatio, SenLfNat,
& SenLfShd, SenLfWat, SLDOT, SuDEF, TOTALWT, temp
REAL, DIMENSION(0:NumOfDays, NumOfStalks) :: CAV, CDEMND,
& DeltaLeafNum, DeltaLeafArea, DeltaLeafArealost,
& LeafArea, LeafArealost, LeafNum, LFDPW, LSDPW,
& LFDW, LSDW, LFDWlost, LSDWlost, LFWT, LSWT,
& LFWTlost, LSWTlost, LFWTA,
& RatioSDC, RTDPW, RTDW, RTWT, ShootCDEM,
& ShootCSUP, STKDPW, STKDW, ! StkCDEM,
& STKmntDEF, STKFWT, STKWT, STKWTA, STKWTlost,
& SUDPW, SUDW, SUWT, SumTTStalk
!-----------------------------------------------------------------------
! Surface and soil residue due to daily senescence of plant matter
REAL SENRT(NL)
REAL SenWt(0:NL) !kg[dry matter]/ha
!REAL SenE(0:NL,NELEM) !kg[E]/ha (E=N, P, S,...)
!-----------------------------------------------------------------------
! Define constructed variable types based on definitions in
! ModuleDefs.for.
! The variable "CONTROL" is of type "ControlType".
TYPE (ControlType) CONTROL
Type (ResidueType) SENESCE
TYPE (SwitchType) ISWITCH
Type (WeatherType) WEATHER
! Transfer values from constructed data types into local variables.
DAS = CONTROL % DAS
DYNAMIC = CONTROL % DYNAMIC
FILEIO = CONTROL % FILEIO
REPNO = CONTROL % REPNO ! FSR
RUN = CONTROL % RUN
RNMODE = CONTROL % RNMODE ! FSR
YRDOY = CONTROL % YRDOY
YRSIM = CONTROL % YRSIM
!-----------------------------------------------------------------------
! Days after planting
DAP = MAX(0,TIMDIF(YRPLT,YRDOY))
!***********************************************************************
!***********************************************************************
! Run Initialization - Called once per simulation
!***********************************************************************
IF (DYNAMIC .EQ. RUNINIT) THEN
!----------------------------------------------------------------------
!----------------------------------------------------------------------
!***********************************************************************
!***********************************************************************
! Seasonal initialization - run once per season
!***********************************************************************
ELSEIF (DYNAMIC .EQ. SEASINIT) THEN
!-----------------------------------------------------------------------
CDEF = 0.0
CountStalk = 0
FRRT = 0.0 ! Brought from CSP_DEMAND.FOR
LAIMX = 0.0
TOPWT = 0.0
XHLAI = 0.0
XLAIlost = 0.0
SLAREF = 0.0
Stalk = 0
SLAVAR = 90
GRLS = GRLF
SenWt = 0.0
SENESCE % ResWt = 0.0
SENESCE % ResE = 0.0
!-----------------------------------------------------------------------
IF (CropTypeCode < 2) THEN ! Plant crop
! From seed cane per ha weight [kg fresh weight], calculate
! CH2O available for early growth [grams]
! g/plant = kg/ha * m2/plant * ha/m2 * gr/kg * CH2O/fresh cane
SeedCH2O = PLWT * 1/PLTPOP * 0.0001 * 1000 * .07
ELSE ! Ratoon crop
SeedCH2O = (PLWT * 1/PLTPOP * 0.0001 * 1000 * .07) * StkHrNO
END IF
!-----------------------------------------------------------------------
! Initialization of variables for stalk appearance and leaf area
DO Day = 0, NumOfDays
CDEM(Day) = 0.0
LeafAreaPlant(Day) = 0.0
LeafAreaPlantlost(Day) = 0.0
LFDWHalost(Day) = 0.0
LSDWHalost(Day) = 0.0
LFWTHa(Day) = 0.0
LSWTHa(Day) = 0.0
LFWTHalost(Day) = 0.0
LSWTHalost(Day) = 0.0
LFWTP(Day) = 0.0
LSWTP(Day) = 0.0
LFWTPlost(Day) = 0.0
LSWTPlost(Day) = 0.0
RTWTHa(Day) = 0.0
RTWTP(Day) = 0.0 !new
RTWTP2(Day) = 0.0 !new
RTDWP(Day) = 0.0
SenesHa(Day) = 0.0
STKDWHalost(Day) = 0.0
STKFWTHa(Day) = 0.0
STKWTHa(Day)= 0.0
STKWTHalost(Day) = 0.0
STKFWTP(Day) = 0.0
STKWTP(Day) = 0.0
SUWTHa(Day) = 0.0
STKWTPlost(Day) = 0.0
SUWTP(Day) = 0.0
StalkPopul(Day) = 0.0
END DO ! Day
DO Stalk = 1, NumOfStalks
EXCESS(Stalk) = 0.0
GroDEF(Stalk) = 0.0
MAINTR(Stalk) = 0.0
PGAVAL(Stalk) = 0.0
PGLEFT(Stalk) = 0.0
PgRatio(Stalk) = 0.0
SenLfNat(Stalk) = 0.0
SenLfShd(Stalk) = 0.0
SenLfWat(Stalk) = 0.0
SLDOT(Stalk) = 0.0
SuDEF(Stalk) = 0.0
TOTALWT(Stalk) = 0.0
temp(Stalk) = 0.0
END DO ! Stalk
DO Day = 0, NumOfDays
DO Stalk = 1, NumOfStalks
CAV(Day, Stalk) = 0.0
CDEMND(Day, Stalk) = 0.0
DeltaLeafArealost(Day, Stalk)= 0.0
LeafArea(Day,Stalk) = 0.0
LeafArealost(Day,Stalk) = 0.0
LFDPW(Day, Stalk) = 0.0
LSDPW(Day, Stalk) = 0.0
LFDW(Day, Stalk) = 0.0
LSDW(Day, Stalk) = 0.0
LFWT(Day, Stalk) = 0.0
LSWT(Day, Stalk) = 0.0
LFDWlost(Day, Stalk) = 0.0
LSDWlost(Day, Stalk) = 0.0
LFWTlost(Day, Stalk) = 0.0
LSWTlost(Day, Stalk) = 0.0
LFWTA(Day, Stalk) = 0.0
RTDPW(DAY, Stalk) = 0.0
RTDW(DAY, Stalk) = 0.0
RTWT(DAY, Stalk) = 0.0
ShootCDEM(Day,Stalk) = 0.0
ShootCSUP(Day,Stalk) = 0.0
STKDPW(Day,Stalk) = 0.0
STKDW(Day, Stalk) = 0.0
STKmntDEF(Day,Stalk) = 0.0
STKFWT(Day, Stalk) = 0.0
STKWT(Day, Stalk) = 0.0
STKWTA(DAY, Stalk) = 0.0
STKWTlost(Day,Stalk) = 0.0
SUDPW(DAS,Stalk) = 0.0
SUDW(Day, Stalk) = 0.0
SUWT(Day, Stalk) = 0.0
END DO ! Stalk
END DO ! Day
!---------------------------------------------------------------------
CALL GET(ISWITCH)
IF (INDEX('Y' ,ISWITCH%IDETG) > 0 .AND.
& INDEX('YDA',ISWITCH%IDETL) > 0) THEN
! Open file to write results from CSP_Grow_Cane.FOR
CALL GETLUN('CSP_GRO',CGLUN)
OPEN(UNIT = CGLUN, FILE = "CSP_GrowCane.OUT", STATUS ="UNKNOWN",
& ACTION = "WRITE", POSITION = "APPEND", IOSTAT = OpenStatus)
WRITE(CGLUN,'("*GROWTH ASPECTS OUTPUT FILE",
& " - RESULTS FROM CSP_GROW_CANE.FOR")')
!Write headers
CALL HEADER(SEASINIT, CGLUN, RUN)
! Units: ----------------------------------------------------------
WRITE(CGLUN,'("!"110X,"senesced")')
WRITE(CGLUN,'("!"53X,"kg/ha kg/ha kg/ha kg/ha /m2
& m2/p #/p kg/p kg/ha kg/ha ")')
!---------------------------------------------------------------------
WRITE(CGLUN,'("@YEAR DOY DAS DAP PHSTG LAI LAIlost PGAVL
& SLA LWAD SWAD RWAD SUAD SNAD LAPD SNPD STWPD
& Leaf Stalk")',ADVANCE="NO")
DO Stalk = 1, Smax
WRITE(CGLUN,'(" SWD",I2.2)',ADVANCE="NO") Stalk
END DO
DO Stalk = 1, Smax
WRITE(CGLUN,'(" SUW",I2.2)',ADVANCE="NO") Stalk
END DO
DO Stalk = 1, Smax
WRITE(CGLUN,'(" LWD",I2.2)',ADVANCE="NO") Stalk
END DO
DO Stalk = 1, Smax
WRITE(CGLUN,'(" LND",I2.2)',ADVANCE="NO") Stalk
END DO
DO Stalk = 1, Smax
WRITE(CGLUN,'(" LAD",I2.2)',ADVANCE="NO") Stalk
END DO
ENDIF
C-----------------------------------------------------------------------
C SET VARIETY SPECIFIC LEAF PARAMETERS
! Scaling of leaf parameters of current cultivar with respect to
! the selected cultivar
C-----------------------------------------------------------------------
!!! DUMFAC = SLAVAR / 105 ! was SLAREF from SPE file
!!! F = DUMFAC * FINREF
!!! FVEG = DUMFAC * SLAMAX
!!! SLAMN = DUMFAC * SLAMIN
!!! SLAMX = DUMFAC * SLAMAX
!***********************************************************************
!***********************************************************************
! Daily Rate calculations
!***********************************************************************
ELSE IF (DYNAMIC .EQ. RATE) THEN
CountStalk = 0
ShootCTotDem = 0.
ShootCTotSup = 0.
StkEx = 0.
SuEx = 0.
SumStkTiWt = 0.
SumStkSuWt = 0.
SumLfWt = 0.
SumLSWt = 0.
SumRtWt = 0.
DO Stalk = 1, Smax
SuDEF(Stalk) = 0.0
End Do
!-----------------------------------------------------------------------
C Compute F, specific leaf area for new leaf weight
C-----------------------------------------------------------------------
! TPHFAC Reduction in specific leaf area due to daytime temperature
! being less than optimal (0-1)
!!! TPHFAC = 0.
!!! DO I = 1,24
!!! TPHFAC = TPHFAC + TABEX (YSLATM,XSLATM,TGRO(I),5)
!!! ENDDO
!!! TPHFAC = TPHFAC/24.
C-----------------------------------------------------------------------
!!! PARSLA = (SLAMN + (SLAMX - SLAMN) * EXP(SLAPAR * PAR)) / SLAMX
!!! TURFSL = MAX(0.1, (1.0 - (1.0 - TURFAC) * TURSLA))
! TURFSL = 1.0 ! temporary diagnosis FSR
C-----------------------------------------------------------------------
! Compute overall effect of TMP, PAR, water stress on SLA (F)
! First for veg stages, then transition to rep stage from R1 to
C end leaf effect of PAR on SLA, COX PEANUT SCI. 5:27, 1978
C-----------------------------------------------------------------------
!!! FFVEG = FVEG * TPHFAC * PARSLA * TURFSL
!!! F = FFVEG
! IF (XFRT*FRACDN .GE. 0.05) F = FFVEG * (1.0 - XFRT * FRACDN)
!-----------------------------------------------------------------------
! Compute SLAREF based on six observations: XDAY(6) days after planting
! and YSLA(6). With sufficient data, may change DAP for thermal time.
IF (DAP <= XDAY(1)) THEN
SLAREF = YSLA(1)
ELSEIF (DAP > XDAY(1) .AND. DAP < XDAY(6)) THEN
! Call to TABEX requires 'REAL' arguments
DO I = 1, 6
DAYS(I) = FLOAT(XDAY(I))
ENDDO
SLAREF = TABEX(YSLA, DAYS, FLOAT(DAP), 6)
ELSEIF (DAP >= XDAY(6)) THEN
SLAREF = YSLA(6)
ENDIF
!-----------------------------------------------------------------------
! Potential Stalk Growth
!
! OHD code & comments from his CSP_DEMAND subroutine is as follows:
!
! This is a temporary function deduced from experiment Lote 14,
! used here as an approximation for the time being. OHD
!
! PGROSTK = (2.8929 * VSTAGE ** 2 + 9.3593 * VSTAGE) / SKPOP
!
! The following function is the 1st derivative of the equation above OHD
!
! RFPSTKG = (5.7858 * VSTAGE + 9.3593) / SKPOP * TURFAC
!
! RFPSTKG Rate Function of Potential STalK Growth (g [stalk]/m2 - leaf)
! (g [stalk] / stalk - leaf) = (g [stalk] / m2 - leaf) / (stalks/m2)
!
! FSR - This function may currently be a weak link in growth simulation.
! Since VSTAGE = LeafNum(DAS,1), the equation had to be modified to
! simulate development of each (not just primary) stalk. Replaced VSTAGE
! with LeafNum(DAS,Stalk) and DLFN with DeltaLeafNum(DAS,Stalk).
!
! RFPSTKG = (5.7858 * LeafNum(DAS-1, Stalk) + 9.3593) / SKPOP * TURFAC
! Note: Use DAS-1 because LeafNum is the result of the (previous day's)
! INTEGR, which is being used here in calculating a RATE.
!
! DPSGRF = NewStalk * RFPSTKG * DLFN
! DPSTKG = DPSTK * PLTPOP
!
! DLFN DeltaLeafNum(DAS,1) (leaf?)
! DPSGRF Potential growth of stalk of reference cane variety
! (g [stalk]/plant) = (stalks/plant)*(g [stalk]/stalk-leaf) * leaf
! DPSTK Potential growth of stalk of selected cane variety
! (g [stalk]/plant) = ratio * (g [stalk]/plant)
! DPSTKG Potential increase of stalk growth
! g [stalk]/m2 = (g [stalk]/plant) (plants/m2)
DO Stalk = 1, Smax
! Section for stalk weight growth rate
!
! Calculates the rate of increase of stalk weight for each stalk.
! Original OHD constants were arbitrarily adjusted to generate more
! reasonable estimates using per-stalk growth.
!
C Note: Parameter CAB postpones demand for stalk tissue until after leaves
C comprising "cabbage" have formed. Note that there are fewer internodes than
C leaves (or at least very short internodes due to stalkless "cabbage" leaf group)
C and stalk does not become apparent until the "great growth" period begins.
!
IF ((LeafNum(DAS-1,Stalk) >= CAB) .AND.
& (StalkState(Stalk,1) .EQ. 'LIVE')) THEN
!!! RFPSTKG = (StkM * LeafNum(DAS-1, Stalk) + StkB) / TURFAC
! The above formulation, dividing by TURFAC, does not make sense.
! TURFAC is a type of multiplier, inhibiting growth as it decreases.
! Since TURFAC = 1.0 is no stress, I will simply change / to *.
RFPSTKG = (StkM * LeafNum(DAS-1, Stalk) + StkB) * TURFAC
STKDPW(DAS,Stalk) = RFPSTKG * DeltaLeafNum(DAS,Stalk)
ELSE
STKDPW(DAS,Stalk) = 0
END IF
! Where: (note: Some units in OHD comments were ambiguous; this attempts to clarify)
! DeltaLeafNum(DAS,Stalk) - increase in # of leaves / stalk / day
! RFPSTKG Rate function of potential stalk growth (not stalk-order specific)
! (g [stalk] / stalk - leaf) = (g [stalk] / m2 - leaf) / (stalks/m2)
! STKDPW(i,j) Potential increase in stalk weight; day i and stalk j (FSR)
! (g[stalk]/stalk) = (g[stalk]/stalk-leaf) * leaf
! StkB Constant used in calculation the rate of increase of stalk weight
! for each stalk. (OHD equation)
! StkM Coefficient used in calculation the rate of increase of stalk weight
! for each stalk. (OHD equation)
! TURFAC Water stress factor for expansion (0 - 1)
! 1 is no stress, 0 is full stress
!***********************************************************************
!**** New method for stalk (tiller) DM and sugar weight calculation ****
! We should replace the above algorithm with a node length and diameter
! function, using the Tabex trio in the ECO file:
! XVSHT Node (v-stage or VS) number, reference stalk
! YVSHT Mature internode length, reference stalk (cm)
! ZVSDI Mature internode diameter, reference stalk (cm)
! These parameters are already present in this sub-routine.
!***********************************************************************
! Potential Leaf and Leaf-Sheath Growth
!
! LFDPW (i,j) Potential increase in leaf weight; day i and stalk j (FSR)
! (g[leaftissue]/stalk-d) = g[leaftissue]/cm2 * cm2/stalk-d
! LSDPW (i,j) Potential increase in leaf sheath weight; day i and stalk j
!
! Section for leaf weight growth rate
! Calculates the potential rate of increase of leaf weight for each stalk
IF (StalkState(Stalk,1) .EQ. 'LIVE') THEN
LFDPW(DAS,Stalk) = (1/SLAREF) * DeltaLeafArea(DAS,Stalk)
LSDPW(DAS,Stalk) = LSFAC * LFDPW(DAS,Stalk) ! sheath as a
! proportion of
ELSE ! leaf DM
LFDPW(DAS,Stalk) = 0.
LSDPW(DAS,Stalk) = 0.
END IF
!-----------------------------------------------------------------------
! Potential Root Growth
!
! RTDPW Potential increase of root growth (g [root] / stalk / day
! FRRT Fraction of potential leaf and stalk growth that is used to
! determine potential root growth.
! OHD used the main stalk leafnumber (XFRRT) in a TABEX function,
! to calculate FRRT (YFRRT).
! Potential root growth is a fraction of the sum of rates of potential
! leaf growth and potential stalk growth.
! When TURFAC=1 (No water stress) the right most term becomes 1 (OHD)
! RTDPW(DAS) = FRRT * AGADPW(DAS) * (2 - TURFAC)
! FSR changed these to by-stalk functions, substituting
! [LeafNum(DAS-1, Stalk)] for VSTAGE, and
! [STKDPW(DAS,Stalk) + LFDPW(DAS,Stalk)] for AGADPW(DAS).
! and also added RootFac, to push more of the root demand on the primary
! and other early stalks during early stool development (PhenoStage < 4).
!
IF (CropTypeCode < 2) THEN ! Plant (not ratoon) crop
IF (StalkState(Stalk,1) .EQ. 'LIVE') THEN
IF (PhenoStage < 4) THEN
! STK = Stalk ! convert Stalk value from int to real
RootFac = TABEX(YSTKRT, XSTKRT, STK, 6)
ELSE
RootFac = 1.0
END IF ! (NewStalk > 6)
FRRT = TABEX(YFRRT, XFRRT, LeafNum(DAS-1, Stalk), 4)
RTDPW(DAS,Stalk) = FRRT * RootFac
& * (STKDPW(DAS,Stalk)+LFDPW(DAS,Stalk)+LSDPW(DAS,Stalk))
& * (2 - TURFAC)
ELSE ! Stalk not LIVE
RTDPW(DAS,Stalk) = 0.
END IF ! (StalkState(Stalk,1) .EQ. 'LIVE')
ELSE ! (i.e., CropTypeCode >= 2)
! Ratoon crop version of root growth. No RootFac.
IF (StalkState(Stalk,1) .EQ. 'LIVE') THEN
FRRT = TABEX(YFRRT, XFRRT, LeafNum(DAS-1, Stalk), 4)
RTDPW(DAS,Stalk) = FRRT
& * (STKDPW(DAS,Stalk)+LFDPW(DAS,Stalk)+LSDPW(DAS,Stalk))
& * (2 - TURFAC)
ELSE
RTDPW(DAS,Stalk) = 0.
END IF ! (StalkState(Stalk,1) .EQ. 'LIVE')
END IF ! (CropTypeCode < 2)
!-----------------------------------------------------------------------
! Potential sucrose Production
!
! FRSU = TABEX(YFRSU, XFRSU, VSTAGE, 4)
!
! Potential sucrose growth is a fraction of the sum of rates of potential
! leaf growth and potential stalk growth
!
! DPSUG = FRSU * (DPLFG + DPSTKG)
!
! FRSU fraction of potential leaf and stalk growth that is
! depositioned as sucrose
! DPLFG potential increase of leaf growth (g [leaf] / plant)
! DPSUG potential increase of sucrose accumulation (g [sucrose] / plant)
! SUDPW(i,j) Potential increase in sucrose weight; day i and stalk j
! (g[sucrose]/stalk-d)
C Note: Parameter CAB postpones demand for stalk tissue until after leaves
C comprising "cabbage" have formed, therefore no sugars should be produced.
IF ((LeafNum(DAS-1,Stalk) >= CAB) .AND.
& (StalkState(Stalk,1) .EQ. 'LIVE')) THEN
FRSU = TABEX(YFRSU, XFRSU, LeafNum(DAS-1, Stalk), 4)
SUDPW(DAS,Stalk) = FRSU * (STKDPW(DAS,Stalk)
& + LFDPW(DAS,Stalk)+LSDPW(DAS,Stalk))
ELSE
SUDPW(DAS,Stalk) = 0.
END IF
END DO ! (Stalk = 1, Smax)
!-----------------------------------------------------------------------
! Calculate CH2O Demand based on Potential Growth
! Daily potential CH2O demand for per-stalk leaf, stalk, root and
! sucrose growth.
!-------- Determine carbon demand of each tiller (not primary) SHOOT
! Primary stalk receives early C from seed cane, not
! from other stalks ShootCDEM
DO Stalk = 1, Smax
IF (StalkState(Stalk,2) .EQ. 'TILR' .AND.
& LeafNum(DAS-1,Stalk)<CAB) THEN
!
ShootCDEM(DAS,Stalk) = (STKDPW(DAS,Stalk) * GRST)
& + (LFDPW(DAS,Stalk) * GRLF)
& + (LSDPW(DAS,Stalk) * GRLF)! GRLF for sheath
& + (RTDPW(DAS,Stalk) * GRRT)
& + (SUDPW(DAS,Stalk) * GRSU)
! ShootCTotDem is demand for shoot CH2O that will not come from shoot itself.
ShootCTotDem = ShootCTotDem
& + MAX(0.,(ShootCDEM(DAS,Stalk) - PGAVAL(Stalk)))
ELSE
ShootCDEM(DAS,Stalk) = 0.0
ENDIF ! (StalkState(Stalk,2) .EQ. 'TILR' .AND.
END DO
!-------- Determine portion of shoot carbon for each stalk to supply
DO Stalk = 1, Smax
ShootCSUP(DAS,Stalk) = ShootCTotDem * PgRatio(Stalk)
! This is last use of ShootCTotDem
END DO
!-------- Determine carbon demand for each STALK (and primary shoot)
! Include C supplied to meet shoot demand
DO Stalk = 1, Smax
IF (LeafNum(DAS-1, Stalk) >= CAB .OR.
& StalkState(Stalk,2) .EQ. 'PRIM') THEN
CDEMND(DAS,Stalk) = (STKDPW(DAS,Stalk) * GRST)
& + (LFDPW(DAS,Stalk) * GRLF)
& + (LSDPW(DAS,Stalk) * GRLF)
& + (RTDPW(DAS,Stalk) * GRRT)
& + (SUDPW(DAS,Stalk) * GRSU)
& + ShootCSUP(DAS,Stalk)
CDEMND(DAS,Stalk) = CDEMND(DAS,Stalk) ! temp for debugging
! ShootCSUP, provides CH2O for (non-primary) shoots
! having < CAB leaves. Outer stalks with higher light interception
! supply CH2O to pool, even when small
ELSE
CDEMND(DAS,Stalk) = 0.0 ! for LeafNum(DAS-1, Stalk) < CAB
ENDIF ! (LeafNum(DAS-1, Stalk) >= CAB)
END DO
!-----------------------------------------------------------------------
! Negative PGAVAL indicates CH2O from PG is less than maintenance
! respiration need. No CH2O from PG is available for growth, and stored
! sucrose may be used to make up CH2O deficit (except for leaf maintenance).
! If insufficient stored sucrose is available, the deficit amount is
! recorded as STKmntDEF(DAS,Stalk) and will be used to drive senescence of
! leaves and stalks. FSR
!
! FSR - Stalks clearly loose leaves while full of sucrose, so leaf maintenance
! was separated from stalk maintenance. The question is to what extent stalks
! will senesce while containing sucrose. If the sucrose is delaying stalk
! senescence unrealistically, the amount of sucrose permitted to subsidize
! maintenance will be limited in the code below.
!
! If PGAVAL is positive, there will be PG for stalk growth; if
! negative, either stored sucrose will meet maintenance needs, or a
! maintenance deficit will contribute to stalk senescence.
DO Stalk = 1, Smax
IF (LeafNum(DAS-1, Stalk) >= CAB .AND. PGAVAL(Stalk) < 0) THEN
STKmntDEF(DAS,Stalk) = PGAVAL(Stalk)
& + (SUWT(DAS-1,Stalk) * GRSU)
IF (STKmntDEF(DAS,Stalk) >= 0) THEN !Sucrose covers deficit
SuDEF(Stalk) = PGAVAL(Stalk) / GRSU
SuDEF(Stalk) = MIN(SuDEF(Stalk), 0.) ! No deficit
STKmntDEF(DAS,Stalk) = 0.
ELSE ! Sucrose insufficient to cover deficit
SuDEF(Stalk) = - SUWT(DAS-1,Stalk) !deficit absorbed all sucrose
ENDIF ! STKmntDEF(DAS,Stalk) >= 0
PGAVAL(Stalk) = 0.0
CAV(DAS,Stalk) = PGAVAL(Stalk)
ELSE ! PGAVAL is sufficient to cover maintenance respiration
! and plant growth can proceed. CH2O available for each
! stalk is saved as CAV(DAS,Stalk)
! Or if [LeafNum(DAS-1, Stalk) < CAB]?? Is this correct (FSR)?
CAV(DAS,Stalk) = PGAVAL(Stalk)
END IF ! (LeafNum(DAS-1, Stalk) >= CAB .AND. PGAVAL(Stalk)
! Ratio of Supply to Demand for Carbon, by stalk
IF (CDEMND(DAS,Stalk) > 0) THEN ! Eliminates young shoots
RatioSDC(DAS,Stalk) = MAX(0.,CAV(DAS,Stalk)/CDEMND(DAS,Stalk))
RatioSDC(DAS,Stalk) = RatioSDC(DAS,Stalk) ! temp for debuging
ELSE
RatioSDC(DAS,Stalk) = 0.0
END IF ! (CDEMND(DAS,Stalk)) > 0)
END DO ! Stalk = 1, Smax
!-----------------------------------------------------------------------
! Calculate growth rates based on non-limiting CH2O
DO Stalk = 1, Smax
IF (StalkState(Stalk,1) .EQ. 'LIVE') THEN
IF (RatioSDC(DAS,Stalk) >= 1) THEN !CH2O is not limiting for
! this stalk on this day
LFDW(DAS,Stalk) = LFDPW(DAS,Stalk)
LSDW(DAS,Stalk) = LSDPW(DAS,Stalk)
STKDW(DAS,Stalk) = STKDPW(DAS,Stalk)
RTDW(DAS,Stalk) = RTDPW(DAS,Stalk)
SUDW(DAS,Stalk) = SUDPW(DAS,Stalk)
! Include ShootCDEM here? Since no distinction
! beween potential & actual, maybe not.
CAV(DAS,Stalk) = CAV(DAS,Stalk)
& - (LFDW(DAS,Stalk) * GRLF)
& - (LSDW(DAS,Stalk) * GRLF)
& - (STKDW(DAS,Stalk) * GRST)
& - (RTDW(DAS,Stalk) * GRRT)
& - (SUDW(DAS,Stalk) * GRSU)
& - ShootCSUP(DAS,Stalk)
ShootCTotSup = ShootCTotSup + ShootCSUP(DAS,Stalk)
!-----------------------------------------------------------------------
! Total amount of today's potential stalk, leaf, root and sucrose growth
! for all stalks
!
! Within these IF statements, remaining CH2O in each
! stalk (CAV - CDEMND)is computed and converted into as
! much as another days demand (for that day) of sucrose
! or stalk DM. The GAMMA parameter determines the
! partition for CH2O to stalk DM or sucrose.
IF (SUDW(DAS,Stalk) > 0) THEN ! if sucrose exists,
! then a stalk must exist
SUDWtmp = ((1-GAMMA) * CAV(DAS,Stalk)) / GRSU
! Limits daily sucrose accumulation from excess CH2O
SUDWtmp = MIN(SUDWtmp,SUDPW(DAS,Stalk))
SUDW(DAS,Stalk) = SUDW(DAS,Stalk) + SUDWtmp
STKDWtmp = (GAMMA * CAV(DAS,Stalk)) / GRST
! Limits daily stalk DM accumulation from excess CH2O
STKDWtmp = MIN(STKDWtmp,STKDPW(DAS,Stalk))
STKDW(DAS,Stalk) = STKDW(DAS,Stalk) + STKDWtmp
ELSE
IF (STKDW(DAS,Stalk) > 0) THEN ! if stalk but no sucrose
STKDWtmp = (GAMMA * CAV(DAS,Stalk)) / GRST
! Limits daily stalk DM accumulation from excess CH2O
STKDWtmp = MIN(STKDWtmp,STKDPW(DAS,Stalk))
STKDW(DAS,Stalk) = STKDW(DAS,Stalk) + STKDWtmp
END IF
CAV(DAS,Stalk) = CAV(DAS,Stalk)
& -((SUDWtmp*GRSU) + (STKDWtmp*GRST))
END IF
temp(Stalk) = CAV(DAS,Stalk) ! debugging
SUDWtmp = 0.0
STKDWtmp = 0.0
!-----------------------------------------------------------------------
! Calculate CH2O-limited growth rates
ELSE ! RatioSDC(DAS,Stalk) < 1 CH2O is limiting on this day
IF (StalkState(Stalk,2) .EQ. 'PRIM') THEN
!Begin with primary stalk(s)
IF (LeafNum(DAS-1,Stalk) < CAB) THEN ! primary SHOOTS only
GroDEF(Stalk) = CDEMND(DAS,Stalk) - CAV(DAS,Stalk)
GroDEF(Stalk) = MIN(GroDEF(Stalk), SEEDCH2O)
CAV(DAS,Stalk) = CAV(DAS,Stalk) + GroDEF(Stalk)
SEEDCH2O = SEEDCH2O - GroDEF(Stalk)
SEEDCH2O = MAX(0., SEEDCH2O)
END IF ! (LeafNum(DAS-1,Stalk) < CAB)
!-----------------------------------------------------------------------
! Prioritize proportion PLF1 (early stalk development)
! or PLF2 (mature stalk) of limited CH2O to leaf growth
IF(SumTTStalk(DAS-1, Stalk) .LT. DTPI) THEN
CAVLF = PLF1 * CAV(DAS,Stalk) ! Primary only here
CAVR = (1 - PLF1) * CAV(DAS,Stalk)
ELSE
CAVLF = PLF2 * CAV(DAS,Stalk)
CAVR = (1 - PLF2) * CAV(DAS,Stalk)
END IF ! (LeafNum(DAS-1,Stalk) < CAB)
!-----------------------------------------------------------------------
! CH2O-limited LEAF growth rate
LFDW(DAS,Stalk) = LFDPW(DAS,Stalk)
LSDW(DAS,Stalk) = LSDPW(DAS,Stalk)
! Leaf PG reduced by leaf increment:
CAVLF = CAVLF
& - ((LFDW(DAS,Stalk)*GRLF)+(LSDW(DAS,Stalk)*GRLF))
! Is there any leaf PG left for other component growth?
IF (CAVLF <= 0) THEN
! Reduce from potential growth to limited growth
WholeLeaf = LFDW(DAS,Stalk) + LSDW(DAS,Stalk)
WholeLeaf = WholeLeaf + (CAVLF / GRLF)
WholeLeaf = MAX(0.0, WholeLeaf)
LFDW(DAS,Stalk) = (1/(1+LSFAC)) * WholeLeaf
LSDW(DAS,Stalk) = WholeLeaf - LFDW(DAS,Stalk)
CAVLF = MAX(0., CAVLF)
END IF ! CAVLF(DAS,Stalk) <= 0) Leaf
CAVR = CAVR + CAVLF
! Partition proportion of limited CH2O to TOPS growth
! Future section for partially developed leaves, stem (cabbage)
! TPDW(DAS,Stalk) = (CAVR / GRTP) * TPDPW(DAS,Stalk)
! & / (TPDPW(DAS,Stalk)+STKDPW(DAS,Stalk)+RTDPW(DAS,Stalk)+SUDPW(DAS,Stalk))
!--------------------------------------------------------------
! Partition proportion of limited CH2O to STALK growth
IF (STKDPW(DAS,Stalk) > 0) THEN
STKDW(DAS,Stalk) = (CAVR / GRST) * STKDPW(DAS,Stalk)
& / (STKDPW(DAS,Stalk)+ RTDPW(DAS,Stalk)+ SUDPW(DAS,Stalk)
& + ShootCSUP(DAS,Stalk)/GRST)
ELSE
STKDW(DAS,Stalk) = 0
END IF
!--------------------------------------------------------------
! Partition proportion of limited CH2O to ROOT growth
IF (RTDPW(DAS,Stalk) > 0) THEN
RTDW(DAS,Stalk) = (CAVR / GRRT) * RTDPW(DAS,Stalk)
& / (STKDPW(DAS,Stalk)+ RTDPW(DAS,Stalk)+ SUDPW(DAS,Stalk)
& + ShootCSUP(DAS,Stalk)/GRRT)
ELSE
RTDW(DAS,Stalk) = 0
END IF
!--------------------------------------------------------------
! Partition proportion of limited CH2O to SUCROSE
IF (SUDPW(DAS,Stalk) > 0) THEN
SUDW(DAS,Stalk) = (CAVR / GRSU) * SUDPW(DAS,Stalk)
& / (STKDPW(DAS,Stalk)+ RTDPW(DAS,Stalk)+ SUDPW(DAS,Stalk)
& + ShootCSUP(DAS,Stalk)/GRSU)
ELSE
SUDW(DAS,Stalk) = 0
END IF
!--------------------------------------------------------------
! Partition proportion of limited CH2O to New Shoots
IF (ShootCSUP(DAS,Stalk) > 0) THEN
ShootCSUP(DAS,Stalk) = CAVR * ShootCSUP(DAS,Stalk)
& / ((STKDPW(DAS,Stalk) * GRST)
& +(RTDPW(DAS,Stalk) * GRRT)
& +(SUDPW(DAS,Stalk) * GRSU)
& + ShootCSUP(DAS,Stalk))
ELSE
ShootCSUP(DAS,Stalk) = 0
END IF
!--------------------------------------------------------------
! Account for use of CAV
CAV(DAS,Stalk) = CAV(DAS,Stalk)
& -(LFDW(DAS,Stalk) * GRLF)
& -(LSDW(DAS,Stalk) * GRLF)
& -(STKDW(DAS,Stalk)* GRST)
& -(RTDW(DAS,Stalk) * GRRT)
& -(SUDW(DAS,Stalk) * GRSU)
& - ShootCSUP(DAS,Stalk)
! & -(TPDW(DAS,Stalk) * GRTP) Future use of TOPS component
ShootCTotSup = ShootCSUP(DAS,Stalk)
CAVLF = 0.0
CAVR = 0.0
!Note: this should go to ELSE ! not primary stalk
!---------------------------------------------------------------------
! Use CH2O stored in seed cane to supplement shoot growth of
! the primary stalk, and CH2O from photosynthesizing stalks to
! supply growth of the following shoots.
ELSE ! for non-primary shoots
IF (LeafNum(DAS-1,Stalk) < CAB) THEN
GroDEF(Stalk) = ShootCDEM(DAS,Stalk) - CAV(DAS,Stalk)
GroDEF(Stalk) = MIN(GroDEF(Stalk), ShootCTotSup)
CAV(DAS,Stalk) = CAV(DAS,Stalk) + GroDEF(Stalk)
ShootCTotSup = ShootCTotSup - GroDEF(Stalk)
ShootCTotSup = MAX(0., ShootCTotSup)
END IF ! (LeafNum(DAS-1,Stalk) < CAB)
!-----------------------------------------------------------------------
! Prioritize proportion PLF1 (early stalk development)
! or PLF2 (mature stalk) of limited CH2O to leaf growth
IF(SumTTStalk(DAS-1, Stalk) .LT. DTPI) THEN
CAVLF = PLF1 * CAV(DAS,Stalk)
CAVR = (1 - PLF1) * CAV(DAS,Stalk)
ELSE
CAVLF = PLF2 * CAV(DAS,Stalk)
CAVR = (1 - PLF2) * CAV(DAS,Stalk)
END IF ! (LeafNum(DAS-1,Stalk) < CAB)
!-----------------------------------------------------------------------
! CH2O-limited LEAF growth increments
LFDW(DAS,Stalk) = LFDPW(DAS,Stalk)
LSDW(DAS,Stalk) = LSDPW(DAS,Stalk)
! Leaf PG reduced by leaf increment:
CAVLF = CAVLF
& - ((LFDW(DAS,Stalk)*GRLF)+(LSDW(DAS,Stalk)*GRLF))
! Is there any leaf PG left for other component growth?
IF (CAVLF <= 0) THEN
! Reduce from potential growth to limited growth
WholeLeaf = LFDW(DAS,Stalk) + LSDW(DAS,Stalk)
WholeLeaf = WholeLeaf + (CAVLF / GRLF)
WholeLeaf = MAX(0.0, WholeLeaf)
LFDW(DAS,Stalk) = (1/(1+LSFAC)) * WholeLeaf
LSDW(DAS,Stalk) = WholeLeaf - LFDW(DAS,Stalk)
!!! LFDW(DAS,Stalk) = LFDW(DAS,Stalk) + (CAVLF / GRLF)
CAVLF = MAX(0., CAVLF)
END IF ! CAVLF(DAS,Stalk) <= 0) Leaf
CAVR = CAVR + CAVLF
! Partition proportion of limited CH2O to TOPS growth
! Future section for partially developed leaves, stem (cabbage)
! TPDW(DAS,Stalk) = (CAVR / GRTP) * TPDPW(DAS,Stalk)
! & / (TPDPW(DAS,Stalk)+STKDPW(DAS,Stalk)+RTDPW(DAS,Stalk)+SUDPW(DAS,Stalk))
! Partition proportion of limited CH2O to STALK growth
IF (STKDPW(DAS,Stalk) > 0) THEN
STKDW(DAS,Stalk) = (CAVR / GRST) * STKDPW(DAS,Stalk)
& / (STKDPW(DAS,Stalk)+ RTDPW(DAS,Stalk)+ SUDPW(DAS,Stalk))
ELSE
STKDW(DAS,Stalk) = 0
END IF
!--------------------------------------------------------------
! Partition proportion of limited CH2O to ROOT growth
IF (RTDPW(DAS,Stalk) > 0) THEN
RTDW(DAS,Stalk) = (CAVR / GRRT) * RTDPW(DAS,Stalk)
& / (STKDPW(DAS,Stalk)+ RTDPW(DAS,Stalk)+ SUDPW(DAS,Stalk))
ELSE
RTDW(DAS,Stalk) = 0
END IF
!--------------------------------------------------------------
! Partition proportion of limited CH2O to SUCROSE
IF (SUDPW(DAS,Stalk) > 0) THEN
SUDW(DAS,Stalk) = (CAVR / GRSU) * SUDPW(DAS,Stalk)
& / (STKDPW(DAS,Stalk)+ RTDPW(DAS,Stalk)+ SUDPW(DAS,Stalk))
ELSE
SUDW(DAS,Stalk) = 0
END IF
!--------------------------------------------------------------
! Account for use of CAV
CAV(DAS,Stalk) = CAV(DAS,Stalk)
& -(LFDW(DAS,Stalk) * GRLF)
& -(LSDW(DAS,Stalk) * GRLF)
& -(STKDW(DAS,Stalk)* GRST)
& -(RTDW(DAS,Stalk) * GRRT)
& -(SUDW(DAS,Stalk) * GRSU)