@@ -131,16 +131,15 @@ function vertical_smagorinsky_lilly_tendency!(Yₜ, Y, p, t, ::SmagorinskyLilly)
131
131
ᶠgradᵥ = Operators. GradientC2F () # apply BCs to ᶜdivᵥ, which wraps ᶠgradᵥ
132
132
ᶜdivᵥ_uₕ = Operators. DivergenceF2C (
133
133
top = Operators. SetValue (C3 (FT (0 )) ⊗ C12 (FT (0 ), FT (0 ))),
134
- bottom = Operators. SetValue (ρ_flux_uₕ ),
134
+ bottom = Operators. SetValue (C3 ( FT ( 0 )) ⊗ C12 ( FT ( 0 ), FT ( 0 )) ),
135
135
)
136
136
ᶠdivᵥ = Operators. DivergenceC2F (
137
137
bottom = Operators. SetDivergence (FT (0 )),
138
138
top = Operators. SetDivergence (FT (0 )),
139
139
)
140
- top = Operators. SetValue (C3 (FT (0 )))
141
140
ᶜdivᵥ_ρe_tot = Operators. DivergenceF2C (;
142
- top,
143
- bottom = Operators. SetValue (ρ_flux_h_tot ),
141
+ top = Operators . SetValue ( C3 ( FT ( 0 ))) ,
142
+ bottom = Operators. SetValue (C3 ( FT ( 0 )) ),
144
143
)
145
144
146
145
# Apply to tendencies
@@ -156,14 +155,13 @@ function vertical_smagorinsky_lilly_tendency!(Yₜ, Y, p, t, ::SmagorinskyLilly)
156
155
@. Yₜ. c. ρe_tot -= ᶜdivᵥ_ρe_tot (- (ᶠρ * ᶠD_smag * ᶠgradᵥ (ᶜh_tot)))
157
156
158
157
# # Tracer diffusion and associated mass changes
159
- sfc_zero = @. sfc_temp_C3 = C3 (FT (0 ))
160
158
for (ᶜρχₜ, ᶜχ, χ_name) in CA. matching_subfields (Yₜ. c, ᶜspecific)
161
159
χ_name == :e_tot && continue
162
160
163
- bottom = Operators. SetValue (
164
- χ_name == :q_tot ? sfc_conditions. ρ_flux_q_tot : sfc_zero,
161
+ ᶜdivᵥ_ρχ = Operators. DivergenceF2C (;
162
+ top = Operators. SetValue (C3 (FT (0 ))),
163
+ bottom = Operators. SetValue (C3 (FT (0 ))),
165
164
)
166
- ᶜdivᵥ_ρχ = Operators. DivergenceF2C (; top, bottom)
167
165
168
166
ᶜ∇ᵥρD∇χₜ = @. ᶜtemp_scalar = ᶜdivᵥ_ρχ (- (ᶠρ * ᶠD_smag * ᶠgradᵥ (ᶜχ)))
169
167
@. ᶜρχₜ -= ᶜ∇ᵥρD∇χₜ
0 commit comments