From 1b1b3c8e3cb60fb5356faeb9dad5679e185e2edd Mon Sep 17 00:00:00 2001 From: nhartney Date: Thu, 7 Aug 2025 15:22:42 +0100 Subject: [PATCH] potential issue in equivalent buoyancy formulation of the thermal SW solver --- gusto/solvers/linear_solvers.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gusto/solvers/linear_solvers.py b/gusto/solvers/linear_solvers.py index 213d09df2..12f651a79 100644 --- a/gusto/solvers/linear_solvers.py +++ b/gusto/solvers/linear_solvers.py @@ -658,6 +658,7 @@ def _setup_solver(self): # compute q_v using q_sat to partition q_t into q_v and q_c self.q_sat_func = Function(VD) self.qvbar = Function(VD) + self.q_v = Function(VD) qtbar = split(equation.X_ref)[3] # set up interpolators that use the X_ref values for D and b_e @@ -669,6 +670,9 @@ def _setup_solver(self): # bbar was be_bar and here we correct to become bbar bbar += equation.parameters.beta2 * self.qvbar + # Should we also be doing the same for b? + # (ie: b was b_e and here we correct it to become b?) + b += equation.parameters.beta2 * self.q_v n = FacetNormal(equation.domain.mesh)