Skip to content

Commit 6951589

Browse files
committed
Update to 2012Rev627
1 parent e8ab34f commit 6951589

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+443
-326
lines changed

VERSIONS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
VERSION_MAJOR 2012
2-
VERSION_MINOR 622
2+
VERSION_MINOR 627
33
VERSION_PATCH

src/allocate_parms.f

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ subroutine allocate_parms
6363
mstdo = 113
6464
motot = 600 !! (50 years limit)
6565

66+
allocate (surlag(mhru))
6667
!!!!!!!!!! drains
6768
allocate (wnan(mlyr))
6869

@@ -509,6 +510,8 @@ subroutine allocate_parms
509510
allocate (wat_tbl(mhru))
510511
allocate (sol_swpwt(mhru))
511512
allocate (conk(mlyr,mhru))
513+
allocate (r2adj(mhru))
514+
allocate (sol_stpwt(mlyr,mhru)) !Moriasi 4/8/2014
512515
! Drainmod tile equations 01/2006
513516
allocate (conv_wt(mlyr,mhru))
514517
allocate (crdep(mlyr,mhru))
@@ -1194,6 +1197,7 @@ subroutine allocate_parms
11941197
allocate (potlagi(mhru))
11951198

11961199
allocate (pplnt(mhru))
1200+
allocate (prf(mch)) !Moriasi 4/8/14
11971201
allocate (qdr(mhru))
11981202
allocate (qdayout(mhru))
11991203
allocate (rch_dakm(mxsubch))

src/autoirr.f

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,8 +192,6 @@ subroutine autoirr
192192
endif
193193
end if
194194

195-
!! changed format below
196-
!!1000 format (a5,1x,a7,3i6,2a15,7f10.2,10x,f10.2,70x,f10.2)
197195
1000 format (a5,1x,a4,3i6,2a15,7f10.2,10x,f10.2,70x,i10,10x,i10)
198196

199197
return

src/bacteria.f

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ subroutine bacteria
1414
!! bactlpq(:) |# cfu/m^2 |less persistent bacteria in soil solution
1515
!! bactlps(:) |# cfu/m^2 |less persistent bacteria attached to soil
1616
!! |particles
17-
!! bactminlp |# cfu/m^2 |Threshold detection level for lestt persistent
17+
!! bactminlp |# cfu/m^2 |Threshold detection level for less persistent
1818
!! |bacteria
1919
!! |when bacteria levels drop to this amount the
2020
!! |model considers bacteria in the soil to be

src/biozone.f

Lines changed: 98 additions & 98 deletions
Large diffs are not rendered by default.

src/bmp_wet_pond.f

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ subroutine wet_pond
171171
b1 = wtp_sdslope(sb) ** 2 + 1.
172172
seepa = a1 * pndwdth ** 2 + 2. * (a1 + 1) * pndwdth * qdepth *
173173
& b1 ** 0.5 + 5.64 * qdepth ** 2 * b1 * wtp_sdslope(sb) !m2
174-
b1 = 2.* beta * ht
174+
b1 = 2.* beta * qdepth !jeong 05/22/14
175175
surfa = (a1 * pndwdth + b1) * (pndwdth + b1) !m2
176176

177177
seep = wtp_k(sb) / 1000. / 60. * idt * seepa !m3

src/caps.f

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ subroutine caps(file_name)
2525

2626
character (len=*) :: file_name
2727
character (len=Len(file_name)) :: temp_name
28-
character (len=26) :: low_case = "abcdefghijklmnopqrstuvwxyz",
29-
& up_case = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
28+
character (len=26) :: low_case = "abcdefghijklmnopqrstuvwxyz",
29+
& up_case = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
3030
integer :: ii, j
3131

3232
temp_name = ""
@@ -40,8 +40,8 @@ subroutine caps(file_name)
4040
end do
4141

4242
temp_name = AdjustL (temp_name) !moves leading blanks to right end
43-
43+
4444
file_name = temp_name
4545

4646
return
47-
end
47+
end

src/dailycn.f

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ subroutine dailycn
7373
if (icn <= 0) then
7474
!! traditional CN method (function of soil water)
7575
if ((sol_sw(j) + Exp(xx)) > 0.001) then
76-
r2 = r2adj * smx(j) * (1. - sol_sw(j) / (sol_sw(j) + Exp(xx)))
76+
r2 = r2adj(j) * smx(j) * (1. - sol_sw(j)/(sol_sw(j)+Exp(xx)))
7777
end if
7878
else
7979
!! alternative CN method (function of plant ET)

src/grass_wway.f

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ subroutine grass_wway
109109
110110
!! Sediment yield (kg) from fraction of area drained by waterway
111111
112-
sedin = sedyld(ihru) * hru_km(ihru)
112+
sedin = sedyld(ihru)
113113
!! Calculate sediment losses in sheetflow at waterway sides
114114
115115
!! calculate area of sheeflow in m^2 assumne *:1 side slope 8.06 = (8^2+1^2)^.5

src/grow.f

Lines changed: 21 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
subroutine grow
2-
2+
33
!! ~ ~ ~ PURPOSE ~ ~ ~
44
!! this subroutine adjusts plant biomass, leaf area index, and canopy height
55
!! taking into account the effect of water, temperature and nutrient stresses
@@ -67,7 +67,7 @@ subroutine grow
6767
!! phuacc(:) |none |fraction of plant heat units accumulated
6868
!! plt_et(:) |mm H2O |actual ET simulated during life of plant
6969
!! plt_pet(:) |mm H2O |potential ET simulated during life of plant
70-
!! strsn(:) |none |fraction of potential plant growth achieved
70+
!! strsn(:) |none |fraction of potential plant growth achieved
7171
!! |on the day where the reduction is caused by
7272
!! |nitrogen stress
7373
!! strsp(:) |none |fraction of potential plant growth achieved
@@ -80,7 +80,7 @@ subroutine grow
8080
!! |on the day where the reduction is caused by
8181
!! |water stress
8282
!! t_base(:) |deg C |minimum temperature for plant growth
83-
!! tmpav(:) |deg C |average air temperature on current day in
83+
!! tmpav(:) |deg C |average air temperature on current day in
8484
!! |HRU
8585
!! vpd |kPa |vapor pressure deficit
8686
!! wac21(:) |none |1st shape parameter for radiation use
@@ -173,27 +173,27 @@ subroutine grow
173173
delg = (tmpav(j) - t_base(idp)) / phu_plt(j)
174174
end if
175175
if (delg < 0.) delg = 0.
176-
phuacc(j) = phuacc(j) + delg
176+
phuacc(j) = phuacc(j) + delg
177177
178178
179179
!! if plant hasn't reached maturity
180180
if (phuacc(j) <= 1.) then
181181

182-
!! compute temperature stress - strstmp(j)
182+
!! compute temperature stress - strstmp(j)
183183
call tstr
184184

185185
!! calculate optimal biomass
186186

187187
!! calculate photosynthetically active radiation
188188
par = 0.
189-
par = .5 * hru_ra(j) * (1. - Exp(-ext_coef(idp) *
189+
par = .5 * hru_ra(j) * (1. - Exp(-ext_coef(idp) *
190190
& (laiday(j) + .05)))
191191

192192
!! adjust radiation-use efficiency for CO2
193193
beadj = 0.
194194
if (co2(hru_sub(j)) > 330.) then
195-
beadj = 100. * co2(hru_sub(j)) / (co2(hru_sub(j)) +
196-
& Exp(wac21(idp) - co2(hru_sub(j)) * wac22(idp)))
195+
beadj = 100. * co2(hru_sub(j)) / (co2(hru_sub(j)) +
196+
& Exp(wac21(idp) - co2(hru_sub(j)) * wac22(idp)))
197197
else
198198
beadj = bio_e(idp)
199199
end if
@@ -207,8 +207,6 @@ subroutine grow
207207
beadj = Max(beadj, 0.27 * bio_e(idp))
208208
end if
209209

210-
beadj = bio_e(idp)
211-
212210
bioday = beadj * par
213211
if (bioday < 0.) bioday = 0.
214212

@@ -239,11 +237,11 @@ subroutine grow
239237
if (reg > 1.) reg = 1.
240238

241239
if (bio_targ(j) > 1.e-2) then
242-
bioday = bioday * (bio_targ(j) - bio_ms(j)) /
240+
bioday = bioday * (bio_targ(j) - bio_ms(j)) /
243241
& bio_targ(j)
244242
reg = 1.
245243
end if
246-
244+
247245
bio_ms(j) = bio_ms(j) + bioday * reg
248246
if (idc(idp) == 7 .and. igrotree(j) == 0) then
249247
if (mat_yrs(idp) > 0) then
@@ -263,14 +261,14 @@ subroutine grow
263261
NPPC_d(j) = NPPC_d(j) + bioday * reg* 0.42
264262
end if
265263
!!add by zhang
266-
!!============
267-
264+
!!============
265+
268266
!! calculate fraction of total biomass that is in the roots
269267
rwt(j) = rsr1(idp) -(rsr1(idp) - rsr2(idp)) * phuacc(j)
270268

271269
f = 0.
272270
ff = 0.
273-
f = phuacc(j) / (phuacc(j) + Exp(leaf1(idp)
271+
f = phuacc(j) / (phuacc(j) + Exp(leaf1(idp)
274272
& - leaf2(idp) * phuacc(j)))
275273
ff = f - laimxfr(j)
276274
laimxfr(j) = f
@@ -293,35 +291,35 @@ subroutine grow
293291
end if
294292

295293
if (laiday(j) > laimax) laiday(j) = laimax
296-
deltalai = ff * laimax * (1.0 - Exp(5.0 * (laiday(j) -
294+
deltalai = ff * laimax * (1.0 - Exp(5.0 * (laiday(j) -
297295
& laimax))) * Sqrt(reg)
298296
laiday(j) = laiday(j) + deltalai
299297
if (laiday(j) > laimax) laiday(j) = laimax
300298
olai(j) = laiday(j)
301299
if (laiday(j) > lai_yrmx(j)) lai_yrmx(j) = laiday(j)
302300
else
303-
laiday(j) = olai(j) * (1. - phuacc(j)) /
301+
laiday(j) = olai(j) * (1. - phuacc(j)) /
304302
& (1. - dlai(idp))
305303
end if
306304
if (laiday(j) < alai_min(idplt(j))) then !Sue White dormancy
307305
laiday(j) = alai_min(idplt(j))
308306
end if
309-
307+
310308
!! calculate plant ET values
311309
if (phuacc(j) > 0.5 .and. phuacc(j) < dlai(idp)) then
312310
plt_et(j) = plt_et(j) + ep_day + es_day
313311
plt_pet(j) = plt_pet(j) + pet_day
314312
end if
315313

316-
hvstiadj(j) = hvsti(idp) * 100. * phuacc(j)
314+
hvstiadj(j) = hvsti(idp) * 100. * phuacc(j)
317315
& / (100. * phuacc(j) + Exp(11.1 - 10. * phuacc(j)))
318316

319317
!! added per JGA for Srini by gsm 9/8/2011
320318
strsw_sum(j) = strsw_sum(j) + (1. - strsw(j))
321319
strstmp_sum(j) = strstmp_sum(j) + (1. - strstmp(j))
322320
strsn_sum(j) = strsn_sum(j) + (1. - strsn(j))
323-
strsp_sum(j) = strsp_sum(j) + (1. - strsp(j))
324-
strsa_sum(j) = strsa_sum(j) + (1. - strsa(j))
321+
strsp_sum(j) = strsp_sum(j) + (1. - strsp(j))
322+
strsa_sum(j) = strsa_sum(j) + (1. - strsa(j))
325323

326324
!! summary calculations
327325
if (curyr > nyskip) then
@@ -334,12 +332,12 @@ subroutine grow
334332
else !! Modified by Cibin to include DLAI>1
335333
if (dlai(idp) > 1.) then
336334
if (phuacc(j) > dlai(idp)) then
337-
laiday(j) = olai(j) * (1. - (phuacc(j) - dlai(idp)) / & !! Modified by Cibin to include DLAI>1
335+
laiday(j) = olai(j) * (1. - (phuacc(j) - dlai(idp)) / !! Modified by Cibin to include DLAI>1
338336
& (1.2 - dlai(idp))) !! Modified by Cibin to include DLAI>1
339337
endif
340338
endif
341339
if (laiday(j) < 0.) laiday(j) = 0. !! Modified by Cibin to include DLAI>1
342340
endif
343341

344342
return
345-
end
343+
end

0 commit comments

Comments
 (0)