diff --git a/Documentation/ProjectFile/prj/processes/process/HEAT_TRANSPORT_BHE/borehole_heat_exchangers/borehole_heat_exchanger/flow_and_temperature_control/TemperatureCurveFlowCurve/c_TemperatureCurveFlowCurve.md b/Documentation/ProjectFile/prj/processes/process/HEAT_TRANSPORT_BHE/borehole_heat_exchangers/borehole_heat_exchanger/flow_and_temperature_control/TemperatureCurveFlowCurve/c_TemperatureCurveFlowCurve.md new file mode 100644 index 0000000000000000000000000000000000000000..b1b8343fb4d8d6f68611361b5b45c3f4690de151 --- /dev/null +++ b/Documentation/ProjectFile/prj/processes/process/HEAT_TRANSPORT_BHE/borehole_heat_exchangers/borehole_heat_exchanger/flow_and_temperature_control/TemperatureCurveFlowCurve/c_TemperatureCurveFlowCurve.md @@ -0,0 +1 @@ +This is another type of controlling temperature difference with specific inflow temperature curve and flow rate curve. diff --git a/Documentation/ProjectFile/prj/processes/process/HEAT_TRANSPORT_BHE/borehole_heat_exchangers/borehole_heat_exchanger/flow_and_temperature_control/TemperatureCurveFlowCurve/t_flow_rate_curve.md b/Documentation/ProjectFile/prj/processes/process/HEAT_TRANSPORT_BHE/borehole_heat_exchangers/borehole_heat_exchanger/flow_and_temperature_control/TemperatureCurveFlowCurve/t_flow_rate_curve.md new file mode 100644 index 0000000000000000000000000000000000000000..aaa7cb2dc906548b9a55224f8d3a3f2e84286414 --- /dev/null +++ b/Documentation/ProjectFile/prj/processes/process/HEAT_TRANSPORT_BHE/borehole_heat_exchangers/borehole_heat_exchanger/flow_and_temperature_control/TemperatureCurveFlowCurve/t_flow_rate_curve.md @@ -0,0 +1 @@ +It means the flow rate in the pipes varying with time. the flow rate curve should be presented and set as input data. The Flow rate in the curve needs to be offered by using m3/s as its unit. diff --git a/Documentation/ProjectFile/prj/processes/process/HEAT_TRANSPORT_BHE/borehole_heat_exchangers/borehole_heat_exchanger/flow_and_temperature_control/TemperatureCurveFlowCurve/t_temperature_curve.md b/Documentation/ProjectFile/prj/processes/process/HEAT_TRANSPORT_BHE/borehole_heat_exchangers/borehole_heat_exchanger/flow_and_temperature_control/TemperatureCurveFlowCurve/t_temperature_curve.md new file mode 100644 index 0000000000000000000000000000000000000000..6481161a9fe5244714df0fd27158028ca0f1f8af --- /dev/null +++ b/Documentation/ProjectFile/prj/processes/process/HEAT_TRANSPORT_BHE/borehole_heat_exchangers/borehole_heat_exchanger/flow_and_temperature_control/TemperatureCurveFlowCurve/t_temperature_curve.md @@ -0,0 +1 @@ +It means the inflow temperature curve varying with time. diff --git a/ProcessLib/HeatTransportBHE/BHE/CreateFlowAndTemperatureControl.cpp b/ProcessLib/HeatTransportBHE/BHE/CreateFlowAndTemperatureControl.cpp index 888cc97e53ddb3a90ff7146a31daf9b93a678fd7..9b33122341edd7203ea1d351cd4b6acd52f93b57 100644 --- a/ProcessLib/HeatTransportBHE/BHE/CreateFlowAndTemperatureControl.cpp +++ b/ProcessLib/HeatTransportBHE/BHE/CreateFlowAndTemperatureControl.cpp @@ -44,6 +44,22 @@ FlowAndTemperatureControl createFlowAndTemperatureControl( return TemperatureCurveConstantFlow{flow_rate, temperature_curve}; } + if (type == "TemperatureCurveFlowCurve") + { + auto const& flow_rate_curve = *BaseLib::getOrError( + curves, + //! \ogs_file_param{prj__processes__process__HEAT_TRANSPORT_BHE__borehole_heat_exchangers__borehole_heat_exchanger__flow_and_temperature_control__TemperatureCurveFlowCurve__flow_rate_curve} + config.getConfigParameter<std::string>("flow_rate_curve"), + "Required flow curve not found."); + + auto const& temperature_curve = *BaseLib::getOrError( + curves, + //! \ogs_file_param{prj__processes__process__HEAT_TRANSPORT_BHE__borehole_heat_exchangers__borehole_heat_exchanger__flow_and_temperature_control__TemperatureCurveFlowCurve__temperature_curve} + config.getConfigParameter<std::string>("temperature_curve"), + "Required temperature curve not found."); + + return TemperatureCurveFlowCurve{flow_rate_curve, temperature_curve}; + } if (type == "FixedPowerConstantFlow") { //! \ogs_file_param{prj__processes__process__HEAT_TRANSPORT_BHE__borehole_heat_exchangers__borehole_heat_exchanger__flow_and_temperature_control__FixedPowerConstantFlow__power} diff --git a/ProcessLib/HeatTransportBHE/BHE/FlowAndTemperatureControl.h b/ProcessLib/HeatTransportBHE/BHE/FlowAndTemperatureControl.h index a718751a9733075986dd81bddd679885eeaf4f44..6c83f56e644d532935afef27c5b50bc5f9a41b4a 100644 --- a/ProcessLib/HeatTransportBHE/BHE/FlowAndTemperatureControl.h +++ b/ProcessLib/HeatTransportBHE/BHE/FlowAndTemperatureControl.h @@ -37,6 +37,18 @@ struct TemperatureCurveConstantFlow MathLib::PiecewiseLinearInterpolation const& temperature_curve; }; +struct TemperatureCurveFlowCurve +{ + FlowAndTemperature operator()(double const /*T_out*/, + double const time) const + { + return {flow_rate_curve.getValue(time), + temperature_curve.getValue(time)}; + } + MathLib::PiecewiseLinearInterpolation const& flow_rate_curve; + MathLib::PiecewiseLinearInterpolation const& temperature_curve; +}; + struct FixedPowerConstantFlow { FlowAndTemperature operator()(double const T_out, @@ -106,6 +118,7 @@ struct BuildingPowerCurveConstantFlow }; using FlowAndTemperatureControl = std::variant<TemperatureCurveConstantFlow, + TemperatureCurveFlowCurve, FixedPowerConstantFlow, FixedPowerFlowCurve, PowerCurveConstantFlow, diff --git a/web/content/docs/userguide/process-dependent-configuration/Heat_Transport_BHE.md b/web/content/docs/userguide/process-dependent-configuration/Heat_Transport_BHE.md index d35720e5fe9b173288b5817528ad07ecae1a293d..63b0c935ddd8c24b892a6bc2b045318a387ef34c 100644 --- a/web/content/docs/userguide/process-dependent-configuration/Heat_Transport_BHE.md +++ b/web/content/docs/userguide/process-dependent-configuration/Heat_Transport_BHE.md @@ -121,6 +121,8 @@ Four type of flow and temperature control patterns are provided in OGS. The key word < flow_rate > applies here, along with the curve defined in the < curves >. * TemperatureCurveConstantFlow:\ It means BHE has a constant < flow_rate > while the inflow temperature following the values defined in the < curves >. +* TemperatureCurveFlowCurve:\ + It means both the BHE inflow rate and temperature values are following the corresponding curves. The unit of < power > is in $\mathrm{W}$ and < flow_rate > is in $\mathrm{m^{3}/s}$. For heating applications, thermal energy is extracted from the subsurface, then a negative power value should be given. It is vice versa for cooling applications.