OGS
ProcessLib::HeatTransportBHE::BHE::BHE_CXC Class Referencefinal

Detailed Description

The BHE_CXC class is the realization of Coaxial pipe with Centred type of the Borehole Heate Exchanger. In this class, the pipe heat capacity, pipe heat conduction, pipe advection vectors are initialized according to the geometry of CXC type of BHE. For CXC type of BHE, 3 primary unknowns are assigned on the 1D BHE elements. They are the temperature in inflow pipe T_in, temperature in outflow pipe T_out, temperature of the grout zone surrounding the outflow pipe T_g. These primary variables are solved according to heat convection and conduction equations on the pipes and also in the grout zone. The interaction of the CXC 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 36 of file BHE_CXC.h.

#include <BHE_CXC.h>

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

Public Member Functions

 BHE_CXC (BoreholeGeometry const &borehole, RefrigerantProperties const &refrigerant, GroutParameters const &grout, FlowAndTemperatureControl const &flowAndTemperatureControl, PipeConfigurationCoaxial const &pipes, bool const use_python_bcs)
 
std::array< double, number_of_unknownscrossSectionAreas () const
 
- Public Member Functions inherited from ProcessLib::HeatTransportBHE::BHE::BHECommonCoaxial
 BHECommonCoaxial (BoreholeGeometry const &borehole, RefrigerantProperties const &refrigerant, GroutParameters const &grout, FlowAndTemperatureControl const &flowAndTemperatureControl, PipeConfigurationCoaxial const &pipes, bool const use_python_bcs)
 
double thermalResistance (int const unknown_index) const
 
double updateFlowRateAndTemperature (double T_out, double current_time)
 
std::array< double, number_of_unknownscalcThermalResistances (double const Nu_inner_pipe, double const Nu_annulus_pipe) const
 
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
 
void updateHeatTransferCoefficients (double const flow_rate)
 
- 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 Public Member Functions inherited from ProcessLib::HeatTransportBHE::BHE::BHECommonCoaxial
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)
 

Private Member Functions

std::array< double, 2 > velocities () const override
 
std::array< double, number_of_unknownsgetThermalResistances (double const &R_gs, double const &R_ff, double const &R_fg) const override
 

Additional Inherited Members

- Public Attributes inherited from ProcessLib::HeatTransportBHE::BHE::BHECommonCoaxial
double cross_section_area_inner_pipe
 
double cross_section_area_annulus
 
double cross_section_area_grout
 
- 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
 
- Static Public Attributes inherited from ProcessLib::HeatTransportBHE::BHE::BHECommonCoaxial
static constexpr int number_of_unknowns = 3
 
static constexpr int number_of_grout_zones = 1
 
static constexpr std::pair< int, int > inflow_outflow_bc_component_ids []
 
- Protected Member Functions inherited from ProcessLib::HeatTransportBHE::BHE::BHECommonCoaxial
- Protected Attributes inherited from ProcessLib::HeatTransportBHE::BHE::BHECommonCoaxial
PipeConfigurationCoaxial const _pipes
 
std::array< double, number_of_unknowns_thermal_resistances
 
double _flow_velocity_inner = std::numeric_limits<double>::quiet_NaN()
 Flow velocity inside the pipes and annulus. Depends on the flow_rate.
 
double _flow_velocity_annulus = std::numeric_limits<double>::quiet_NaN()
 

Constructor & Destructor Documentation

◆ BHE_CXC()

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

Definition at line 39 of file BHE_CXC.h.

45 : BHECommonCoaxial{borehole, refrigerant,
47 pipes, use_python_bcs}
48 {
49 // Initialize thermal resistances.
50 auto values = visit(
51 [&](auto const& control) {
53 0. /* initial time */);
54 },
56 updateHeatTransferCoefficients(values.flow_rate);
57 }
BHECommonCoaxial(BoreholeGeometry const &borehole, RefrigerantProperties const &refrigerant, GroutParameters const &grout, FlowAndTemperatureControl const &flowAndTemperatureControl, PipeConfigurationCoaxial const &pipes, bool const use_python_bcs)
RefrigerantProperties const refrigerant
Definition BHECommon.h:42
FlowAndTemperatureControl const flowAndTemperatureControl
Definition BHECommon.h:44

References ProcessLib::HeatTransportBHE::BHE::BHECommon::flowAndTemperatureControl, ProcessLib::HeatTransportBHE::BHE::RefrigerantProperties::reference_temperature, ProcessLib::HeatTransportBHE::BHE::BHECommon::refrigerant, and ProcessLib::HeatTransportBHE::BHE::BHECommonCoaxial::updateHeatTransferCoefficients().

Member Function Documentation

◆ assembleRMatrices()

template<int NPoints, typename SingleUnknownMatrixType , typename RMatrixType , typename RPiSMatrixType , typename RSMatrixType >
static void ProcessLib::HeatTransportBHE::BHE::BHE_CXC::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 62 of file BHE_CXC.h.

68 {
69 switch (idx_bhe_unknowns)
70 {
71 case 0: // PHI_ff
72 R_matrix.block(0, NPoints, NPoints, NPoints) +=
73 -1.0 * matBHE_loc_R;
74 R_matrix.block(NPoints, 0, NPoints, NPoints) +=
75 -1.0 * matBHE_loc_R;
76
77 R_matrix.block(0, 0, NPoints,
78 NPoints) += 1.0 * matBHE_loc_R; // K_i
79 R_matrix.block(NPoints, NPoints, NPoints, NPoints) +=
80 1.0 * matBHE_loc_R; // K_o
81 return;
82 case 1: // PHI_fog
83 R_matrix.block(NPoints, 2 * NPoints, NPoints, NPoints) +=
84 -1.0 * matBHE_loc_R;
85 R_matrix.block(2 * NPoints, NPoints, NPoints, NPoints) +=
86 -1.0 * matBHE_loc_R;
87
88 R_matrix.block(NPoints, NPoints, NPoints, NPoints) +=
89 1.0 * matBHE_loc_R; // K_o
90 R_matrix.block(2 * NPoints,
91 2 * NPoints,
92 NPoints,
93 NPoints) += 1.0 * matBHE_loc_R; // K_og
94 return;
95 case 2: // PHI_gs
96 R_s_matrix += matBHE_loc_R;
97
98 R_pi_s_matrix.block(2 * NPoints, 0, NPoints, NPoints) +=
99 -1.0 * matBHE_loc_R;
100
101 R_matrix.block(2 * NPoints, 2 * NPoints, NPoints,
102 NPoints) += matBHE_loc_R; // K_og
103 return;
104 default:
105 OGS_FATAL(
106 "Error!!! In the function BHE_CXC::assembleRMatrices, "
107 "the index of bhe unknowns is out of range! ");
108 }
109 }
#define OGS_FATAL(...)
Definition Error.h:26

References OGS_FATAL.

◆ crossSectionAreas()

◆ getThermalResistances()

std::array< double, number_of_unknowns > ProcessLib::HeatTransportBHE::BHE::BHE_CXC::getThermalResistances ( double const & R_gs,
double const & R_ff,
double const & R_fg ) const
inlineoverrideprivatevirtual

Implements ProcessLib::HeatTransportBHE::BHE::BHECommonCoaxial.

Definition at line 123 of file BHE_CXC.h.

126 {
127 return {R_ff, R_fg, R_gs};
128 }

◆ velocities()

std::array< double, 2 > ProcessLib::HeatTransportBHE::BHE::BHE_CXC::velocities ( ) const
inlineoverrideprivatevirtual

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