Skip to content

Custom chemistry reaction rates to support T6 mechanism - #1712

Draft
fvitt wants to merge 1 commit into
ESCOMP:cam_developmentfrom
fvitt:emmons_rxts
Draft

fvitt wants to merge 1 commit into
ESCOMP:cam_developmentfrom
fvitt:emmons_rxts

Conversation

@fvitt

@fvitt fvitt commented Oct 8, 2026

Copy link
Copy Markdown
Collaborator

Custom (user defined) reaction rates needed for T6 chemistry mechanism development.

	modified:   src/chemistry/mozart/mo_usrrxt.F90
@fvitt
fvitt requested a review from lkemmons October 8, 2026 17:59
@fvitt fvitt self-assigned this Oct 8, 2026
@fvitt fvitt added the BFB bit for bit tag label Oct 8, 2026
@cacraigucar

Copy link
Copy Markdown
Collaborator

@fvitt, @tilmes, @lkemmons - Are these mods needed for the runs that @cecilehannay will be making? @briandobbins

@fvitt

fvitt commented Oct 12, 2026

Copy link
Copy Markdown
Collaborator Author

@fvitt, @tilmes, @lkemmons - Are these mods needed for the runs that @cecilehannay will be making? @briandobbins

No. This is lower priority.

@jimmielin jimmielin left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @fvitt. A minor comment and a suggestion to avoid repetition.

When discussing this PR with @cacraigucar we were not sure if this was intended to go in standalone, or if a T6 mechanism input file was intended be included as well?

scale_a = 1._r8 ! We assume there's no difference between prim/sec/tert radicals
scale_b = 1._r8 ! 1 for alkyl peroxy
fac_Ro(:) = ( fac_A(:) / (1._r8 + fac_A(:)/fac_B(:)) )*fac_F**fac_z(:)
RONO2_yield(:) = scale_a * scale_b * ( fac_Ro(:) / (1 + fac_Ro(:)) )

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this be

Suggested change
RONO2_yield(:) = scale_a * scale_b * ( fac_Ro(:) / (1 + fac_Ro(:)) )
RONO2_yield(:) = scale_a * scale_b * ( fac_Ro(:) / (1._r8 + fac_Ro(:)) )

Comment on lines +2016 to +2029
!-----------------------------------------------------------------
! ... C2H5O2_NOa Temp/Pressure Dependent Nitrate Yield
!-----------------------------------------------------------------
if( usr_C2H5O2_NOn_ndx > 0 ) then
nCON = 2.0_r8
exp_nCON = exp( nCON )
fac_A(:) = 2.0e-22_r8 * exp_nCON * m(:,k)
fac_B(:) = 0.43_r8 * ( 300._r8 * tinv(:) )**8._r8
fac_F = 0.41_r8
fac_z(:) = 1._r8 / ( 1._r8 + log10( fac_A(:) / fac_B(:) )**2._r8 )
scale_a = 1._r8 ! We assume there's no difference between prim/sec/tert radicals
scale_b = 1._r8 ! 1 for alkyl peroxy
fac_Ro(:) = ( fac_A(:) / (1._r8 + fac_A(:)/fac_B(:)) )*fac_F**fac_z(:)
RONO2_yield(:) = scale_a * scale_b * ( fac_Ro(:) / (1 + fac_Ro(:)) )

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here and below for RONO2_yield there is a lot of duplication, I wonder if something like

pure function rono2_yield( nCON, m, tinv ) result( yield )

    real(r8), intent(in) :: nCON     ! number of C, O and N atoms in R, excluding the peroxy group
    real(r8), intent(in) :: m(:)     ! total atm density (/cm^3)
    real(r8), intent(in) :: tinv(:)  ! 1/T (1/K)
    real(r8) :: yield(size(m))

    real(r8), parameter :: alpha = 2.0e-22_r8  ! low-pressure yield coefficient
    real(r8), parameter :: y_inf = 0.43_r8     ! high-pressure limit yield at 300 K
    real(r8), parameter :: m_inf = 8._r8       ! temperature exponent of the high-pressure limit
    real(r8), parameter :: fac_F = 0.41_r8     ! falloff broadening factor

    real(r8) :: fac_A(size(m)), fac_B(size(m)), fac_z(size(m)), fac_Ro(size(m))

    fac_A(:)  = alpha * exp( nCON ) * m(:)
    fac_B(:)  = y_inf * ( 300._r8 * tinv(:) )**m_inf
    fac_z(:)  = 1._r8 / ( 1._r8 + log10( fac_A(:) / fac_B(:) )**2 )
    fac_Ro(:) = ( fac_A(:) / ( 1._r8 + fac_A(:) / fac_B(:) ) ) * fac_F**fac_z(:)
    yield(:)  = fac_Ro(:) / ( 1._r8 + fac_Ro(:) )

  end function rono2_yield

so the blocks could be simplified as

!-----------------------------------------------------------------
!       ... C2H5O2 + NO, temperature/pressure dependent nitrate yield
!-----------------------------------------------------------------
       if( usr_C2H5O2_NOn_ndx > 0 ) then
          RONO2_yield(:) = rono2_yield( 2._r8, m(:,k), tinv(:) )
          call comp_exp( exp_fac, 365._r8*tinv, ncol )
          rxt(:,k,usr_C2H5O2_NOn_ndx) = 2.6e-12_r8 * exp_fac(:) * RONO2_yield(:)
          rxt(:,k,usr_C2H5O2_NOa_ndx) = 2.6e-12_r8 * exp_fac(:) * ( 1._r8 - RONO2_yield(:) )
       end if

@fvitt
fvitt marked this pull request as draft October 19, 2026 17:16
@fvitt

fvitt commented Oct 20, 2026

Copy link
Copy Markdown
Collaborator Author

@lkemmons
Does this need to be part of the CESM3.0 release?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

BFB bit for bit tag

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

4 participants