From 8b31bfbc3470b38ee19fb1fbb785e42ff160e0fd Mon Sep 17 00:00:00 2001 From: Haipeng Lin Date: Mon, 18 Apr 2022 23:00:07 -0400 Subject: [PATCH] Fix critical regression bug with AR_thr and threshold --- KPP/fullchem/gckpp_Integrator.F90 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/KPP/fullchem/gckpp_Integrator.F90 b/KPP/fullchem/gckpp_Integrator.F90 index ed8a5c952..1f885d717 100644 --- a/KPP/fullchem/gckpp_Integrator.F90 +++ b/KPP/fullchem/gckpp_Integrator.F90 @@ -878,7 +878,7 @@ SUBROUTINE ros_yIntegrator (Y, Tstart, Tend, T, & DO i=1,NVAR ! Short-circuiting using SKIP is very important here. if (.not. keepSpcActive(i) .and. & - abs(LossY(i)).lt.threshold .and. abs(Prod(i)).lt.threshold) then ! per Shen et al., 2020 + abs(LossY(i)).lt.AR_thr .and. abs(Prod(i)).lt.AR_thr) then ! per Shen et al., 2020 NRMV=NRMV+1 ! RMV(NRMV) = i ! not needed unless in append version. DO_SLV(i) = .false. @@ -894,7 +894,7 @@ SUBROUTINE ros_yIntegrator (Y, Tstart, Tend, T, & IF (.not. keepActive) THEN DO i=1,NVAR ! Short-circuiting using SKIP is very important here. - if (abs(LossY(i)).lt.threshold .and. abs(Prod(i)).lt.threshold) then ! per Shen et al., 2020 + if (abs(LossY(i)).lt.AR_thr .and. abs(Prod(i)).lt.AR_thr) then ! per Shen et al., 2020 NRMV=NRMV+1 ! RMV(NRMV) = i ! not needed unless in append version. DO_SLV(i) = .false. @@ -1329,7 +1329,7 @@ SUBROUTINE ros_yIntegratorA (Y, Tstart, Tend, T, & DO i=1,NVAR ! Short-circuiting using SKIP is very important here. if (.not. keepSpcActive(i) .and. & - abs(LossY(i)).lt.threshold .and. abs(Prod(i)).lt.threshold) then ! per Shen et al., 2020 + abs(LossY(i)).lt.AR_thr .and. abs(Prod(i)).lt.AR_thr) then ! per Shen et al., 2020 NRMV=NRMV+1 RMV(NRMV) = i DO_SLV(i) = .false. @@ -1345,7 +1345,7 @@ SUBROUTINE ros_yIntegratorA (Y, Tstart, Tend, T, & IF (.not. keepActive) THEN DO i=1,NVAR ! Short-circuiting using SKIP is very important here. - if (abs(LossY(i)).lt.threshold .and. abs(Prod(i)).lt.threshold) then ! per Shen et al., 2020 + if (abs(LossY(i)).lt.AR_thr .and. abs(Prod(i)).lt.AR_thr) then ! per Shen et al., 2020 NRMV=NRMV+1 RMV(NRMV) = i DO_SLV(i) = .false.