Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug fix for izumi nag tests to pass (PR into b4b-dev) #2926

Merged
merged 1 commit into from
Jan 7, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions src/biogeochem/CNFUNMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -169,17 +169,17 @@ subroutine readParams ( ncid )
if ( .not. readv ) call endrun( msg=trim(errCode)//trim(tString)//errMsg(sourcefile, __LINE__))
params_inst%ndays_off=tempr

allocate(params_inst%nfix_tmin(mxpft))
allocate(params_inst%nfix_tmin(0:mxpft))
tString='nfix_tmin'
call ncd_io(trim(tString), params_inst%nfix_tmin(:), 'read', ncid, readvar=readv)
if ( .not. readv ) call endrun(msg=trim(errCode)//trim(tString)//errMsg(sourcefile, __LINE__))

allocate(params_inst%nfix_topt(mxpft))
allocate(params_inst%nfix_topt(0:mxpft))
tString='nfix_topt'
call ncd_io(trim(tString), params_inst%nfix_topt(:), 'read', ncid, readvar=readv)
if ( .not. readv ) call endrun(msg=trim(errCode)//trim(tString)//errMsg(sourcefile, __LINE__))

allocate(params_inst%nfix_tmax(mxpft))
allocate(params_inst%nfix_tmax(0:mxpft))
tString='nfix_tmax'
call ncd_io(trim(tString), params_inst%nfix_tmax(:), 'read', ncid, readvar=readv)
if ( .not. readv ) call endrun(msg=trim(errCode)//trim(tString)//errMsg(sourcefile, __LINE__))
Expand Down Expand Up @@ -535,7 +535,7 @@ subroutine CNFUN(bounds,num_soilc, filter_soilc,num_soilp&
real(r8) :: total_N_resistance ! C to of N for whole soil -leaf
! pathway
real(r8) :: free_RT_frac=0.0_r8 !fraction of N retranslocation which is automatic/free.
! SHould be made into a PFT parameter.
! Should be made into a PFT parameter.

real(r8) :: paid_for_n_retrans
real(r8) :: free_n_retrans
Expand Down Expand Up @@ -1136,13 +1136,13 @@ subroutine CNFUN(bounds,num_soilc, filter_soilc,num_soilp&

select case (nfix_method)
case ('Houlton')
costNit(j,icostFix) = fun_cost_fix(fixer,&
a_fix(ivt(p)),b_fix(ivt(p)),c_fix(ivt(p)),&
big_cost,crootfr(p,j),s_fix(ivt(p)),tc_soisno(c,j))
costNit(j,icostFix) = fun_cost_fix(fixer, &
a_fix(ivt(p)), b_fix(ivt(p)), c_fix(ivt(p)), &
big_cost, crootfr(p,j), s_fix(ivt(p)), tc_soisno(c,j))
case ('Bytnerowicz') ! no acclimation calculation
costNit(j,icostFix) = fun_cost_fix_Bytnerowicz_noAcc(fixer, &
params_inst%nfix_tmin(ivt(p)), params_inst%nfix_topt(ivt(p)), params_inst%nfix_tmax(ivt(p)), &
big_cost,crootfr(p,j),s_fix(ivt(p)),tc_soisno(c,j))
costNit(j,icostFix) = fun_cost_fix_Bytnerowicz_noAcc(fixer, &
params_inst%nfix_tmin(ivt(p)), params_inst%nfix_topt(ivt(p)), params_inst%nfix_tmax(ivt(p)), &
big_cost,crootfr(p,j), s_fix(ivt(p)), tc_soisno(c,j))
case default
errCode = ' ERROR: unknown nfix_method value: ' // nfix_method
call endrun( msg=trim(errCode) // errMsg(sourcefile, __LINE__))
Expand Down
Loading