LCOV - code coverage report
Current view: top level - physics/carma/base - growp.F90 (source / functions) Hit Total Coverage
Test: coverage.info Lines: 8 8 100.0 %
Date: 2025-03-14 01:30:37 Functions: 1 1 100.0 %

          Line data    Source code
       1             : ! Include shortname defintions, so that the F77 code does not have to be modified to
       2             : ! reference the CARMA structure.
       3             : #include "carma_globaer.h"
       4             : 
       5             : !! This routine calculates particle source terms due to growth <growpe>
       6             : !! for one particle size bin at one spatial grid point per call.
       7             : !!
       8             : !! @author Andy Ackerman
       9             : !! @version Dec-1995
      10 46919733960 : subroutine growp(carma, cstate, iz, ibin, ielem, rc)
      11             : 
      12             :         ! types
      13             :   use carma_precision_mod
      14             :   use carma_enums_mod
      15             :   use carma_constants_mod
      16             :   use carma_types_mod
      17             :   use carmastate_mod
      18             :   use carma_mod
      19             : 
      20             :         implicit none
      21             : 
      22             :   type(carma_type), intent(in)         :: carma   !! the carma object
      23             :   type(carmastate_type), intent(inout) :: cstate  !! the carma state object
      24             :   integer, intent(in)                  :: iz      !! z index
      25             :   integer, intent(in)                  :: ibin    !! bin index
      26             :   integer, intent(in)                  :: ielem   !! element index
      27             :   integer, intent(inout)               :: rc      !! return code, negative indicates failure
      28             : 
      29             :   ! Local declarations
      30             :   integer                              :: igroup  ! group index
      31             :   integer                              :: iepart
      32             :   
      33             : 
      34             :   ! Define group & particle # concentration indices for current element
      35 46919733960 :   igroup = igelem(ielem)      ! target particle group 
      36 46919733960 :   iepart = ienconc(igroup)        ! target particle number concentration element
      37             : 
      38             :   ! Calculate production terms due to condensational growth <growpe>
      39             :   ! only if group to which element belongs grows.
      40 46919733960 :   if( igrowgas(iepart) .ne. 0 .and. ibin .ne. 1 )then
      41             : 
      42             :     ! Bypass calculation if few droplets are present 
      43 44573747262 :     if( pconmax(iz,igroup) .gt. FEW_PC )then
      44 44297859643 :       growpe(ibin,ielem) = pc(iz,ibin-1,ielem) * growlg(ibin-1,igroup) 
      45             :     endif
      46             :   endif
      47             : 
      48             :   ! Return to caller with growth production terms evaluated.
      49 46919733960 :   return
      50 46919733960 : end

Generated by: LCOV version 1.14