Skip to content

Commit

Permalink
add missing r8 real kind specifiers
Browse files Browse the repository at this point in the history
	modified:   src/chemistry/aerosol/carma_aerosol_properties_mod.F90
	modified:   src/chemistry/carma_aero/carma_aero_gasaerexch.F90
	modified:   src/physics/carma/cam/carma_intr.F90
	modified:   src/physics/carma/models/trop_strat_soa1/carma_model_mod.F90
	modified:   src/physics/carma/models/trop_strat_soa5/carma_model_mod.F90
  • Loading branch information
fvitt committed Dec 16, 2024
1 parent 69fa095 commit 5765179
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion src/chemistry/aerosol/carma_aerosol_properties_mod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -716,7 +716,7 @@ function scav_diam(self, bin_ndx) result(diam)
end do

! specdens kg/m3 to g/cm3, convert from radius to diameter
diam = 2._r8*((0.75*mass / pi / (1.0e-3_r8*rho))**onethird)
diam = 2._r8*((0.75_r8*mass / pi / (1.0e-3_r8*rho))**onethird)

end function scav_diam

Expand Down
2 changes: 1 addition & 1 deletion src/chemistry/carma_aero/carma_aero_gasaerexch.F90
Original file line number Diff line number Diff line change
Expand Up @@ -777,7 +777,7 @@ subroutine gas_aer_uptkrates( ncol, loffset, &
gasspeed = 1.470e1_r8 * sqrt(t(i,k))
! freepathx2 = 2 * (h2so4 mean free path) (m)
freepathx2 = 6.0_r8*gasdiffus/gasspeed
dp = wetr(i,k,n) * 1.e-2 ! meters
dp = wetr(i,k,n) * 1.e-2_r8 ! meters
const = tworootpi * num_bin(i,k,n) * 2.0_r8 * dp
! gas_conden_rate(Dp) = const * gasdiffus * F(Kn,ac)
! knudsen number
Expand Down
4 changes: 2 additions & 2 deletions src/physics/carma/cam/carma_intr.F90
Original file line number Diff line number Diff line change
Expand Up @@ -3951,8 +3951,8 @@ subroutine carma_get_wet_radius(state, igroup, ibin, rwet, rhopwet, rc)
end do

! Convert rwet and rhopwet to mks units
rwet(:ncol,:) = rwet(:ncol,:) * 1.e-2 ! cm --> m
rhopwet(:ncol,:) = rhopwet(:ncol,:) * 1.e3 ! g/cm3 --> kg/m3
rwet(:ncol,:) = rwet(:ncol,:) * 1.e-2_r8 ! cm --> m
rhopwet(:ncol,:) = rhopwet(:ncol,:) * 1.e3_r8 ! g/cm3 --> kg/m3

if (rc/=RC_OK) then
call endrun('carma_get_wet_radius ERROR8: rc = ',rc)
Expand Down
10 changes: 5 additions & 5 deletions src/physics/carma/models/trop_strat_soa1/carma_model_mod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ module carma_model_mod
3.74323598e-08_f, 1.63841034e-09_f, 2.49434956e-09_f, 1.52413800e-08_f, &
3.35000010e-08_f, 3.43825518e-02_f /)


real(r8), parameter :: onethird = 1._r8/3._r8

contains

Expand Down Expand Up @@ -1657,11 +1657,11 @@ subroutine CARMAMODEL_CreateOpticsFile_MixedYu(carma, igroup, rc)
do iwave = 1, NWAVE

! For now just assume BC/OC constant 15%
! rcore = r(ibin)*(0.15**(1./3))
! rcore = r(ibin)*(0.15**onethird)
! Using Mie code, consider core/shell ratio
do icsr = 1, ncsr
if (ncsr > 1) then
rcore = r(ibin)*(coreshellratio(icsr)**(1./3))
rcore = r(ibin)*(coreshellratio(icsr)**onethird)
else
rcore = 0.0_f
endif
Expand Down Expand Up @@ -2109,11 +2109,11 @@ subroutine CARMAMODEL_CreateOpticsFile_MixedYuH2o(carma, igroup, rc)
do iwave = 1, NWAVE

! For now just assume BC/OC constant 15%
! rcore = r(ibin)*(0.15**(1./3))
! rcore = r(ibin)*(0.15**onethird)
! Using Mie code, consider core/shell ratio
do icsr = 1, ncsr
if (ncsr > 1) then
rcore = r(ibin)*(coreshellratio(icsr)**(1./3))
rcore = r(ibin)*(coreshellratio(icsr)**onethird)
else
rcore = 0.0_f
endif
Expand Down
10 changes: 5 additions & 5 deletions src/physics/carma/models/trop_strat_soa5/carma_model_mod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ module carma_model_mod
3.74323598e-08_f, 1.63841034e-09_f, 2.49434956e-09_f, 1.52413800e-08_f, &
3.35000010e-08_f, 3.43825518e-02_f /)


real(r8), parameter :: onethird = 1._r8/3._r8

contains

Expand Down Expand Up @@ -1859,11 +1859,11 @@ subroutine CARMAMODEL_CreateOpticsFile_MixedYu(carma, igroup, rc)
do iwave = 1, NWAVE

! For now just assume BC/OC constant 15%
! rcore = r(ibin)*(0.15**(1./3))
! rcore = r(ibin)*(0.15**onethird)
! Using Mie code, consider core/shell ratio
do icsr = 1, ncsr
if (ncsr > 1) then
rcore = r(ibin)*(coreshellratio(icsr)**(1./3))
rcore = r(ibin)*(coreshellratio(icsr)**onethird)
else
rcore = 0.0_f
endif
Expand Down Expand Up @@ -2311,11 +2311,11 @@ subroutine CARMAMODEL_CreateOpticsFile_MixedYuH2o(carma, igroup, rc)
do iwave = 1, NWAVE

! For now just assume BC/OC constant 15%
! rcore = r(ibin)*(0.15**(1./3))
! rcore = r(ibin)*(0.15**onethird)
! Using Mie code, consider core/shell ratio
do icsr = 1, ncsr
if (ncsr > 1) then
rcore = r(ibin)*(coreshellratio(icsr)**(1./3))
rcore = r(ibin)*(coreshellratio(icsr)**onethird)
else
rcore = 0.0_f
endif
Expand Down

0 comments on commit 5765179

Please sign in to comment.