Skip to content

Commit

Permalink
Add explicit lower bound for cumulative optical thickness in 2-stream…
Browse files Browse the repository at this point in the history
… shortwave solver
  • Loading branch information
sriharshakandala committed Feb 15, 2024
1 parent 5b80e71 commit e6a24ac
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/rte/shortwave2stream.jl
Original file line number Diff line number Diff line change
Expand Up @@ -358,6 +358,7 @@ function rte_sw_2stream!(
# radiation emitted at bottom of layer,
# transmitted through the layer and reflected from layers below (Tdiff*src*albedo)
τ_cum -= τ_ilev
τ_cum = max(τ_cum, FT(0))
flux_dn_dir_ilevplus1 = flux_dn_dir_top * exp(-τ_cum / μ₀)
src_up_ilev = Rdir * flux_dn_dir_ilevplus1 #flux_dn_dir[ilev + 1]
src_dn_ilev = Tdir * flux_dn_dir_ilevplus1 #flux_dn_dir[ilev + 1]
Expand Down

0 comments on commit e6a24ac

Please sign in to comment.