OGS
ProcessLib::HeatTransportBHE::BHE::BHE_2U Class Referencefinal

Detailed Description

The BHE_2U class is the realization of 2U type of Borehole Heate Exchanger. In this class, the pipe heat capacity, pipe heat conductiion, pipe advection vectors are initialized according to the geometry of 2U type of BHE. For 2U type of BHE, 8 primary unknowns are assigned on the 1D BHE elements. They are the temperature in inflow pipe T_i1 and T_i2, temperature in outflow pipe T_o1 and T_o2, temperature of the four grout zones surrounding the inflow and outflow pipe T_g1, T_g2, T_g3 and T_g4. These primary variables are solved according to heat convection and conduction equations on the pipes and also in the grout zones. The interaction of the 2U type of BHE and the surrounding soil is regulated through the thermal resistance values, which are calculated specifically during the initialization of the class.

Definition at line 34 of file BHE_2U.h.

#include <BHE_2U.h>

Inheritance diagram for ProcessLib::HeatTransportBHE::BHE::BHE_2U:
[legend]
Collaboration diagram for ProcessLib::HeatTransportBHE::BHE::BHE_2U:
[legend]

Public Member Functions

 BHE_2U (BoreholeGeometry const &borehole, RefrigerantProperties const &refrigerant, GroutParameters const &grout, FlowAndTemperatureControl const &flowAndTemperatureControl, PipeConfigurationUType const &pipes, bool const use_python_bcs)
std::array< double, number_of_unknownspipeHeatCapacities () const
std::array< double, number_of_unknownspipeHeatConductions () const
std::array< Eigen::Vector3d, number_of_unknownspipeAdvectionVectors (Eigen::Vector3d const &) const
double updateFlowRateAndTemperature (double T_out, double current_time)
 Return the inflow temperature for the boundary condition.
double thermalResistance (int const unknown_index) const
std::array< double, number_of_unknownscrossSectionAreas () const
void updateHeatTransferCoefficients (double const flow_rate)
Public Member Functions inherited from ProcessLib::HeatTransportBHE::BHE::BHECommonUType
 BHECommonUType (BoreholeGeometry const &borehole, RefrigerantProperties const &refrigerant, GroutParameters const &grout, FlowAndTemperatureControl const &flowAndTemperatureControl, PipeConfigurationUType const &pipes, bool const use_python_bcs)
Public Member Functions inherited from ProcessLib::HeatTransportBHE::BHE::BHECommon
constexpr bool isPowerBC () const

Static Public Member Functions

template<int NPoints, typename SingleUnknownMatrixType, typename RMatrixType, typename RPiSMatrixType, typename RSMatrixType>
static void assembleRMatrices (int const idx_bhe_unknowns, Eigen::MatrixBase< SingleUnknownMatrixType > const &matBHE_loc_R, Eigen::MatrixBase< RMatrixType > &R_matrix, Eigen::MatrixBase< RPiSMatrixType > &R_pi_s_matrix, Eigen::MatrixBase< RSMatrixType > &R_s_matrix)
static std::array< std::pair< std::size_t, int >, 2 > getBHEInflowDirichletBCNodesAndComponents (std::size_t const top_node_id, std::size_t const, int const in_component_id)
static std::optional< std::array< std::pair< std::size_t, int >, 2 > > getBHEBottomDirichletBCNodesAndComponents (std::size_t const bottom_node_id, int const in_component_id, int const out_component_id)

Static Public Attributes

static constexpr int number_of_unknowns = 8
static constexpr int number_of_grout_zones = 4
static constexpr std::pair< int, int > inflow_outflow_bc_component_ids []

Private Member Functions

std::array< double, number_of_unknownscalcThermalResistances (double const Nu)
 Nu is the Nusselt number.

Private Attributes

std::array< double, number_of_unknowns_thermal_resistances

Additional Inherited Members

Public Attributes inherited from ProcessLib::HeatTransportBHE::BHE::BHECommon
BoreholeGeometry const borehole_geometry
RefrigerantProperties const refrigerant
GroutParameters const grout
FlowAndTemperatureControl const flowAndTemperatureControl
bool const use_python_bcs
Protected Attributes inherited from ProcessLib::HeatTransportBHE::BHE::BHECommonUType
PipeConfigurationUType const _pipes
double _flow_velocity = std::numeric_limits<double>::quiet_NaN()
 Flow velocity inside the pipes. Depends on the flow_rate.

Constructor & Destructor Documentation

◆ BHE_2U()

ProcessLib::HeatTransportBHE::BHE::BHE_2U::BHE_2U ( BoreholeGeometry const & borehole,
RefrigerantProperties const & refrigerant,
GroutParameters const & grout,
FlowAndTemperatureControl const & flowAndTemperatureControl,
PipeConfigurationUType const & pipes,
bool const use_python_bcs )

Definition at line 18 of file BHE_2U.cpp.

25 pipes, use_python_bcs}
26{
27 _thermal_resistances.fill(std::numeric_limits<double>::quiet_NaN());
28
29 // Initialize thermal resistances.
30 auto values = visit(
31 [&](auto const& control) {
32 return control(refrigerant.reference_temperature,
33 0. /* initial time */);
34 },
36 updateHeatTransferCoefficients(values.flow_rate);
37}
BHECommonUType(BoreholeGeometry const &borehole, RefrigerantProperties const &refrigerant, GroutParameters const &grout, FlowAndTemperatureControl const &flowAndTemperatureControl, PipeConfigurationUType const &pipes, bool const use_python_bcs)
void updateHeatTransferCoefficients(double const flow_rate)
Definition BHE_2U.cpp:174
std::array< double, number_of_unknowns > _thermal_resistances
Definition BHE_2U.h:224
RefrigerantProperties const refrigerant
Definition BHECommon.h:36
FlowAndTemperatureControl const flowAndTemperatureControl
Definition BHECommon.h:38

References ProcessLib::HeatTransportBHE::BHE::BHECommonUType::BHECommonUType(), _thermal_resistances, ProcessLib::HeatTransportBHE::BHE::BHECommon::flowAndTemperatureControl, ProcessLib::HeatTransportBHE::BHE::BHECommon::grout, ProcessLib::HeatTransportBHE::BHE::BHECommon::refrigerant, updateHeatTransferCoefficients(), and ProcessLib::HeatTransportBHE::BHE::BHECommon::use_python_bcs.

Member Function Documentation

◆ assembleRMatrices()

template<int NPoints, typename SingleUnknownMatrixType, typename RMatrixType, typename RPiSMatrixType, typename RSMatrixType>
void ProcessLib::HeatTransportBHE::BHE::BHE_2U::assembleRMatrices ( int const idx_bhe_unknowns,
Eigen::MatrixBase< SingleUnknownMatrixType > const & matBHE_loc_R,
Eigen::MatrixBase< RMatrixType > & R_matrix,
Eigen::MatrixBase< RPiSMatrixType > & R_pi_s_matrix,
Eigen::MatrixBase< RSMatrixType > & R_s_matrix )
inlinestatic

Definition at line 59 of file BHE_2U.h.

65 {
66 switch (idx_bhe_unknowns)
67 {
68 case 0: // PHI_fig
69 R_matrix.block(0, 4 * NPoints, NPoints, NPoints) +=
70 -1.0 * matBHE_loc_R;
71 R_matrix.block(4 * NPoints, 0, NPoints, NPoints) +=
72 -1.0 * matBHE_loc_R; // R_i1
73
74 R_matrix.block(2, 5 * NPoints, NPoints, NPoints) +=
75 -1.0 * matBHE_loc_R;
76 R_matrix.block(5 * NPoints, 2, NPoints, NPoints) +=
77 -1.0 * matBHE_loc_R; // R_i2
78
79 R_matrix.block(0, 0, NPoints, NPoints) +=
80 1.0 * matBHE_loc_R; // K_i1
81 R_matrix.block(NPoints, NPoints, NPoints, NPoints) +=
82 1.0 * matBHE_loc_R; // K_i2
83 R_matrix.block(4 * NPoints, 4 * NPoints, NPoints, NPoints) +=
84 1.0 * matBHE_loc_R;
85 R_matrix.block(5 * NPoints, 5 * NPoints, NPoints, NPoints) +=
86 1.0 * matBHE_loc_R; // K_ig
87 return;
88 case 1: // PHI_fog
89 R_matrix.block(2 * NPoints, 6 * NPoints, NPoints, NPoints) +=
90 -1.0 * matBHE_loc_R;
91 R_matrix.block(6 * NPoints, 2 * NPoints, NPoints, NPoints) +=
92 -1.0 * matBHE_loc_R; // R_o1
93 R_matrix.block(3 * NPoints, 7 * NPoints, NPoints, NPoints) +=
94 -1.0 * matBHE_loc_R;
95 R_matrix.block(7 * NPoints, 3 * NPoints, NPoints, NPoints) +=
96 -1.0 * matBHE_loc_R; // R_o2
97
98 R_matrix.block(2 * NPoints, 2 * NPoints, NPoints, NPoints) +=
99 1.0 * matBHE_loc_R; // K_o1
100 R_matrix.block(3 * NPoints, 3 * NPoints, NPoints, NPoints) +=
101 1.0 * matBHE_loc_R; // K_o2
102 R_matrix.block(6 * NPoints, 6 * NPoints, NPoints, NPoints) +=
103 1.0 * matBHE_loc_R;
104 R_matrix.block(7 * NPoints, 7 * NPoints, NPoints, NPoints) +=
105 1.0 * matBHE_loc_R; // K_og
106 return;
107 case 2: // PHI_gg_1
108 R_matrix.block(4 * NPoints, 6 * NPoints, NPoints, NPoints) +=
109 -1.0 * matBHE_loc_R;
110 R_matrix.block(6 * NPoints, 4 * NPoints, NPoints, NPoints) +=
111 -1.0 * matBHE_loc_R;
112 R_matrix.block(4 * NPoints, 7 * NPoints, NPoints, NPoints) +=
113 -1.0 * matBHE_loc_R;
114 R_matrix.block(7 * NPoints, 4 * NPoints, NPoints, NPoints) +=
115 -1.0 * matBHE_loc_R;
116 R_matrix.block(5 * NPoints, 6 * NPoints, NPoints, NPoints) +=
117 -1.0 * matBHE_loc_R;
118 R_matrix.block(6 * NPoints, 5 * NPoints, NPoints, NPoints) +=
119 -1.0 * matBHE_loc_R;
120 R_matrix.block(5 * NPoints, 7 * NPoints, NPoints, NPoints) +=
121 -1.0 * matBHE_loc_R;
122 R_matrix.block(7 * NPoints, 5 * NPoints, NPoints, NPoints) +=
123 -1.0 * matBHE_loc_R; // R_g1
124
125 R_matrix.block(4 * NPoints, 4 * NPoints, NPoints, NPoints) +=
126 2.0 * matBHE_loc_R;
127 R_matrix.block(5 * NPoints, 5 * NPoints, NPoints, NPoints) +=
128 2.0 * matBHE_loc_R; // K_ig // notice we have two
129 // PHI_gg_1 term here.
130 R_matrix.block(6 * NPoints, 6 * NPoints, NPoints, NPoints) +=
131 2.0 * matBHE_loc_R;
132 R_matrix.block(7 * NPoints, 7 * NPoints, NPoints, NPoints) +=
133 2.0 * matBHE_loc_R; // K_og // see Diersch 2013 FEFLOW
134 // book page 954 Table M.2
135 return;
136 case 3: // PHI_gg_2
137 R_matrix.block(4 * NPoints, 5 * NPoints, NPoints, NPoints) +=
138 -1.0 * matBHE_loc_R;
139 R_matrix.block(5 * NPoints, 4 * NPoints, NPoints, NPoints) +=
140 -1.0 * matBHE_loc_R;
141 R_matrix.block(6 * NPoints, 7 * NPoints, NPoints, NPoints) +=
142 -1.0 * matBHE_loc_R;
143 R_matrix.block(7 * NPoints, 6 * NPoints, NPoints, NPoints) +=
144 -1.0 * matBHE_loc_R; // R_g2
145
146 R_matrix.block(4 * NPoints, 4 * NPoints, NPoints, NPoints) +=
147 1.0 * matBHE_loc_R;
148 R_matrix.block(5 * NPoints, 5 * NPoints, NPoints, NPoints) +=
149 1.0 * matBHE_loc_R; // K_ig // notice we only have
150 // 1 PHI_gg term here.
151 R_matrix.block(6 * NPoints, 6 * NPoints, NPoints, NPoints) +=
152 1.0 * matBHE_loc_R;
153 R_matrix.block(7 * NPoints, 7 * NPoints, NPoints, NPoints) +=
154 1.0 * matBHE_loc_R; // K_og // see Diersch 2013 FEFLOW
155 // book page 954 Table M.2
156 return;
157 case 4: // PHI_gs
158 R_s_matrix.template block<NPoints, NPoints>(0, 0).noalias() +=
159 1.0 * matBHE_loc_R;
160
161 R_pi_s_matrix.block(4 * NPoints, 0, NPoints, NPoints) +=
162 -1.0 * matBHE_loc_R;
163 R_pi_s_matrix.block(5 * NPoints, 0, NPoints, NPoints) +=
164 -1.0 * matBHE_loc_R;
165 R_pi_s_matrix.block(6 * NPoints, 0, NPoints, NPoints) +=
166 -1.0 * matBHE_loc_R;
167 R_pi_s_matrix.block(7 * NPoints, 0, NPoints, NPoints) +=
168 -1.0 * matBHE_loc_R;
169 R_matrix.block(4 * NPoints, 4 * NPoints, NPoints, NPoints) +=
170 1.0 * matBHE_loc_R;
171 R_matrix.block(5 * NPoints, 5 * NPoints, NPoints, NPoints) +=
172 1.0 * matBHE_loc_R; // K_ig
173 R_matrix.block(6 * NPoints, 6 * NPoints, NPoints, NPoints) +=
174 1.0 * matBHE_loc_R;
175 R_matrix.block(7 * NPoints, 7 * NPoints, NPoints, NPoints) +=
176 1.0 * matBHE_loc_R; // K_og
177 return;
178 default:
179 OGS_FATAL(
180 "Error!!! In the function BHE_2U::assembleRMatrices, "
181 "the index of bhe unknowns is out of range! ");
182 }
183 }
#define OGS_FATAL(...)
Definition Error.h:19

References OGS_FATAL.

◆ calcThermalResistances()

std::array< double, BHE_2U::number_of_unknowns > ProcessLib::HeatTransportBHE::BHE::BHE_2U::calcThermalResistances ( double const Nu)
private

Nu is the Nusselt number.

Definition at line 186 of file BHE_2U.cpp.

188{
189 constexpr double pi = std::numbers::pi;
190
191 double const lambda_r = refrigerant.thermal_conductivity;
192 double const lambda_g = grout.lambda_g;
193 double const lambda_p = _pipes.inlet.wall_thermal_conductivity;
194
195 // thermal resistances due to advective flow of refrigerant in the _pipes
196 // Eq. 36 in Diersch_2011_CG
197 double const R_adv_i = 1.0 / (Nu * lambda_r * pi);
198 double const R_adv_o = 1.0 / (Nu * lambda_r * pi);
199
200 // thermal resistance due to thermal conductivity of the pipe wall material
201 // Eq. 49
202 double const R_con_a =
203 std::log(_pipes.inlet.outsideDiameter() / _pipes.inlet.diameter) /
204 (2.0 * pi * lambda_p);
205
206 // the average outer diameter of the _pipes
207 double const d0 = _pipes.outlet.outsideDiameter();
208 double const D = borehole_geometry.diameter;
209 // Eq. 38
210 double const chi =
211 std::log(std::sqrt(D * D + 4 * d0 * d0) / 2 / std::sqrt(2) / d0) /
212 std::log(D / 2 / d0);
213 // Eq. 39
214 // thermal resistances of the grout
215 double const R_g =
216 std::acosh((D * D + d0 * d0 - 2 * _pipes.distance * _pipes.distance) /
217 (2 * D * d0)) /
218 (2 * pi * lambda_g) *
219 (3.098 - 4.432 * std::sqrt(2) * _pipes.distance / D +
220 2.364 * 2 * _pipes.distance * _pipes.distance / D / D);
221
222 // thermal resistance due to inter-grout exchange
223 double const R_ar_1 =
224 std::acosh((2.0 * _pipes.distance * _pipes.distance - d0 * d0) / d0 /
225 d0) /
226 (2.0 * pi * lambda_g);
227
228 double const R_ar_2 =
229 std::acosh((2.0 * 2.0 * _pipes.distance * _pipes.distance - d0 * d0) /
230 d0 / d0) /
231 (2.0 * pi * lambda_g);
232
233 auto const [chi_new, R_gg_1, R_gg_2, R_gs] =
234 thermalResistancesGroutSoil2U(chi, R_ar_1, R_ar_2, R_g);
235
236 // thermal resistance due to the grout transition.
237 double const R_con_b = chi_new * R_g;
238
239 // Eq. 29 and 30
240 double const R_fig = R_adv_i + R_con_a + R_con_b;
241 double const R_fog = R_adv_o + R_con_a + R_con_b;
242
243 return {{R_fig, R_fog, R_gg_1, R_gg_2, R_gs}};
244
245 // keep the following lines------------------------------------------------
246 // when debugging the code, printing the R and phi values are needed--------
247 // std::cout << "Rfig =" << R_fig << " Rfog =" << R_fog << " Rgg =" <<
248 // R_gg << " Rgs =" << R_gs << "\n"; double phi_fig = 1.0 / (R_fig *
249 // S_i); double phi_fog = 1.0 / (R_fog * S_o); double phi_gg = 1.0 / (R_gg
250 // * S_g1); double phi_gs = 1.0 / (R_gs * S_gs); std::cout << "phi_fig ="
251 // << phi_fig << " phi_fog =" << phi_fog << " phi_gg =" << phi_gg << "
252 // phi_gs =" << phi_gs << "\n";
253 // -------------------------------------------------------------------------
254}
std::array< double, 4 > thermalResistancesGroutSoil2U(double const chi, double const R_ar_1, double const R_ar_2, double const R_g)
Definition BHE_2U.cpp:139

References ProcessLib::HeatTransportBHE::BHE::BHECommonUType::_pipes, ProcessLib::HeatTransportBHE::BHE::BHECommon::borehole_geometry, ProcessLib::HeatTransportBHE::BHE::BHECommon::grout, ProcessLib::HeatTransportBHE::BHE::BHECommon::refrigerant, and ProcessLib::HeatTransportBHE::BHE::thermalResistancesGroutSoil2U().

Referenced by updateHeatTransferCoefficients().

◆ crossSectionAreas()

std::array< double, BHE_2U::number_of_unknowns > ProcessLib::HeatTransportBHE::BHE::BHE_2U::crossSectionAreas ( ) const

Definition at line 277 of file BHE_2U.cpp.

278{
279 return {{
280 _pipes.inlet.area(),
281 _pipes.inlet.area(),
282 _pipes.outlet.area(),
283 _pipes.outlet.area(),
284 borehole_geometry.area() / 4 - _pipes.inlet.outsideArea(),
285 borehole_geometry.area() / 4 - _pipes.inlet.outsideArea(),
286 borehole_geometry.area() / 4 - _pipes.outlet.outsideArea(),
287 borehole_geometry.area() / 4 - _pipes.outlet.outsideArea(),
288 }};
289}

References ProcessLib::HeatTransportBHE::BHE::BHECommonUType::_pipes, and ProcessLib::HeatTransportBHE::BHE::BHECommon::borehole_geometry.

◆ getBHEBottomDirichletBCNodesAndComponents()

std::optional< std::array< std::pair< std::size_t, int >, 2 > > ProcessLib::HeatTransportBHE::BHE::BHE_2U::getBHEBottomDirichletBCNodesAndComponents ( std::size_t const bottom_node_id,
int const in_component_id,
int const out_component_id )
static

Definition at line 268 of file BHE_2U.cpp.

272{
273 return {{std::make_pair(bottom_node_id, in_component_id),
274 std::make_pair(bottom_node_id, out_component_id)}};
275}

◆ getBHEInflowDirichletBCNodesAndComponents()

std::array< std::pair< std::size_t, int >, 2 > ProcessLib::HeatTransportBHE::BHE::BHE_2U::getBHEInflowDirichletBCNodesAndComponents ( std::size_t const top_node_id,
std::size_t const ,
int const in_component_id )
static

Definition at line 257 of file BHE_2U.cpp.

261{
262 return {std::make_pair(top_node_id, in_component_id),
263 std::make_pair(top_node_id, in_component_id + 2)};
264}

◆ pipeAdvectionVectors()

std::array< Eigen::Vector3d, BHE_2U::number_of_unknowns > ProcessLib::HeatTransportBHE::BHE::BHE_2U::pipeAdvectionVectors ( Eigen::Vector3d const & ) const

Definition at line 91 of file BHE_2U.cpp.

92{
93 double const rho_r = refrigerant.density;
94 double const Cp_r = refrigerant.specific_heat_capacity;
95
96 return {{// pipe i1
97 {0, 0, -rho_r * Cp_r * _flow_velocity},
98 // pipe i2
99 {0, 0, -rho_r * Cp_r * _flow_velocity},
100 // pipe o1
101 {0, 0, rho_r * Cp_r * _flow_velocity},
102 // pipe o2
103 {0, 0, rho_r * Cp_r * _flow_velocity},
104 // grout g1
105 {0, 0, 0},
106 // grout g2
107 {0, 0, 0},
108 // grout g3
109 {0, 0, 0},
110 // grout g4
111 {0, 0, 0}}};
112}
double _flow_velocity
Flow velocity inside the pipes. Depends on the flow_rate.

References ProcessLib::HeatTransportBHE::BHE::BHECommonUType::_flow_velocity, and ProcessLib::HeatTransportBHE::BHE::BHECommon::refrigerant.

◆ pipeHeatCapacities()

std::array< double, BHE_2U::number_of_unknowns > ProcessLib::HeatTransportBHE::BHE::BHE_2U::pipeHeatCapacities ( ) const

Definition at line 39 of file BHE_2U.cpp.

41{
42 double const rho_r = refrigerant.density;
43 double const specific_heat_capacity = refrigerant.specific_heat_capacity;
44 double const rho_g = grout.rho_g;
45 double const porosity_g = grout.porosity_g;
46 double const heat_cap_g = grout.heat_cap_g;
47
48 return {{/*i1*/ rho_r * specific_heat_capacity,
49 /*i2*/ rho_r * specific_heat_capacity,
50 /*o1*/ rho_r * specific_heat_capacity,
51 /*o2*/ rho_r * specific_heat_capacity,
52 /*g1*/ (1.0 - porosity_g) * rho_g * heat_cap_g,
53 /*g2*/ (1.0 - porosity_g) * rho_g * heat_cap_g,
54 /*g3*/ (1.0 - porosity_g) * rho_g * heat_cap_g,
55 /*g4*/ (1.0 - porosity_g) * rho_g * heat_cap_g}};
56}

References ProcessLib::HeatTransportBHE::BHE::BHECommon::grout, and ProcessLib::HeatTransportBHE::BHE::BHECommon::refrigerant.

◆ pipeHeatConductions()

std::array< double, BHE_2U::number_of_unknowns > ProcessLib::HeatTransportBHE::BHE::BHE_2U::pipeHeatConductions ( ) const

Definition at line 58 of file BHE_2U.cpp.

60{
61 double const lambda_r = refrigerant.thermal_conductivity;
62 double const rho_r = refrigerant.density;
63 double const Cp_r = refrigerant.specific_heat_capacity;
64 double const alpha_L = _pipes.longitudinal_dispersion_length;
65 double const porosity_g = grout.porosity_g;
66 double const lambda_g = grout.lambda_g;
67
68 // Here we calculate the laplace coefficients in the governing
69 // equations of BHE. These governing equations can be found in
70 // 1) Diersch (2013) FEFLOW book on page 952, M.120-122, or
71 // 2) Diersch (2011) Comp & Geosci 37:1122-1135, Eq. 19-22.
72 return {{// pipe i1
73 (lambda_r + rho_r * Cp_r * alpha_L * _flow_velocity),
74 // pipe i2
75 (lambda_r + rho_r * Cp_r * alpha_L * _flow_velocity),
76 // pipe o1
77 (lambda_r + rho_r * Cp_r * alpha_L * _flow_velocity),
78 // pipe o2
79 (lambda_r + rho_r * Cp_r * alpha_L * _flow_velocity),
80 // pipe g1
81 (1.0 - porosity_g) * lambda_g,
82 // pipe g2
83 (1.0 - porosity_g) * lambda_g,
84 // pipe g3
85 (1.0 - porosity_g) * lambda_g,
86 // pipe g4
87 (1.0 - porosity_g) * lambda_g}};
88}

References ProcessLib::HeatTransportBHE::BHE::BHECommonUType::_flow_velocity, ProcessLib::HeatTransportBHE::BHE::BHECommonUType::_pipes, ProcessLib::HeatTransportBHE::BHE::BHECommon::grout, and ProcessLib::HeatTransportBHE::BHE::BHECommon::refrigerant.

◆ thermalResistance()

double ProcessLib::HeatTransportBHE::BHE::BHE_2U::thermalResistance ( int const unknown_index) const
inline

Definition at line 188 of file BHE_2U.h.

189 {
190 return _thermal_resistances[unknown_index];
191 }

References _thermal_resistances.

◆ updateFlowRateAndTemperature()

double ProcessLib::HeatTransportBHE::BHE::BHE_2U::updateFlowRateAndTemperature ( double T_out,
double current_time )

Return the inflow temperature for the boundary condition.

Definition at line 291 of file BHE_2U.cpp.

293{
294 auto values =
295 visit([&](auto const& control) { return control(T_out, current_time); },
297 updateHeatTransferCoefficients(values.flow_rate);
298 return values.temperature;
299}

References ProcessLib::HeatTransportBHE::BHE::BHECommon::flowAndTemperatureControl, and updateHeatTransferCoefficients().

◆ updateHeatTransferCoefficients()

void ProcessLib::HeatTransportBHE::BHE::BHE_2U::updateHeatTransferCoefficients ( double const flow_rate)

Definition at line 174 of file BHE_2U.cpp.

176{
177 auto const tm_flow_properties = calculateThermoMechanicalFlowPropertiesPipe(
178 _pipes.inlet, borehole_geometry.length, refrigerant, flow_rate);
179
180 _flow_velocity = tm_flow_properties.velocity;
182 calcThermalResistances(tm_flow_properties.nusselt_number);
183}
std::array< double, number_of_unknowns > calcThermalResistances(double const Nu)
Nu is the Nusselt number.
Definition BHE_2U.cpp:186
ThermoMechanicalFlowProperties calculateThermoMechanicalFlowPropertiesPipe(Pipe const &pipe, double const length, RefrigerantProperties const &fluid, double const flow_rate)

References ProcessLib::HeatTransportBHE::BHE::BHECommonUType::_flow_velocity, ProcessLib::HeatTransportBHE::BHE::BHECommonUType::_pipes, _thermal_resistances, ProcessLib::HeatTransportBHE::BHE::BHECommon::borehole_geometry, calcThermalResistances(), ProcessLib::HeatTransportBHE::BHE::calculateThermoMechanicalFlowPropertiesPipe(), and ProcessLib::HeatTransportBHE::BHE::BHECommon::refrigerant.

Referenced by BHE_2U(), and updateFlowRateAndTemperature().

Member Data Documentation

◆ _thermal_resistances

std::array<double, number_of_unknowns> ProcessLib::HeatTransportBHE::BHE::BHE_2U::_thermal_resistances
private

PHI_fig, PHI_fog, PHI_gg, PHI_gs; Here we store the thermal resistances needed for computation of the heat exchange coefficients in the governing equations of BHE. These governing equations can be found in 1) Diersch (2013) FEFLOW book on page 958, M.3, or 2) Diersch (2011) Comp & Geosci 37:1122-1135, Eq. 90-97.

Definition at line 224 of file BHE_2U.h.

Referenced by BHE_2U(), thermalResistance(), and updateHeatTransferCoefficients().

◆ inflow_outflow_bc_component_ids

std::pair<int, int> ProcessLib::HeatTransportBHE::BHE::BHE_2U::inflow_outflow_bc_component_ids[]
staticconstexpr
Initial value:
= {
{0, 2}, {1, 3}}

Definition at line 193 of file BHE_2U.h.

193 {
194 {0, 2}, {1, 3}};

◆ number_of_grout_zones

int ProcessLib::HeatTransportBHE::BHE::BHE_2U::number_of_grout_zones = 4
staticconstexpr

Definition at line 45 of file BHE_2U.h.

◆ number_of_unknowns

int ProcessLib::HeatTransportBHE::BHE::BHE_2U::number_of_unknowns = 8
staticconstexpr

Definition at line 44 of file BHE_2U.h.


The documentation for this class was generated from the following files: