Skip to content

B2G_ana API Reference

geoloop.geoloopcore.b2g_ana.B2G_ana

Class for analytical / semi-analytical borehole-to-ground simulation.

This class uses pygfunction's g-function and a load aggregation scheme (Claesson-Javed) to compute borehole wall temperatures and then obtains fluid/pipe temperatures from CustomPipe methods.

Attributes:

Name Type Description
custom_pipe CustomPipe

Depth-dependent borehole configuration and properties.

soil_props SoilProperties

Depth-dependent soil parameters (conductivity and temperature).

sim_params SimulationParameters

Simulation parameters (time, flow, power, temperature).

Notes

The simulation can be run for input power or input temperature and calls the appropriate function. runsimulation_power is called for power simulations runsimulation_temperature is called for temperature simulations

__init__

__init__(
    custom_pipe: CustomPipe,
    soil_properties: SoilProperties,
    simulation_parameters: SimulationParameters,
) -> None

Initialize the analytical BHE model wrapper.

Parameters:

Name Type Description Default
custom_pipe CustomPipe

Pipe/borehole configuration object.

required
soil_properties SoilProperties

Soil properties provider.

required
simulation_parameters SimulationParameters

Operational and simulation parameters.

required

runsimulation

runsimulation()

Run the simulation of the borehole to ground heat exchanger.

Returns:

Type Description
tuple

(hours, Q_b, flowrate, qsign, T_fi, T_fo, T_bave, z, zseg, T_b, T_ftimes, qbzseg, h_fpipes)

runsimulation_temperature

runsimulation_temperature() -> tuple

Run the simulation of the borehole to ground heat exchanger for an input inlet temperature.

The method: - computes the segment-wise g-function scaling, - uses load-aggregation to obtain borehole wall temperature response, - calls CustomPipe methods to compute fluid temperatures for each time step.

Returns:

Type Description
tuple

(hours, Q_b, flowrate, qsign, T_fi, T_fo, T_bave, z, zseg, T_b, T_ftimes, qbzseg, h_fpipes)

runsimulation_power

runsimulation_power() -> tuple

Run the simulation of the borehole to ground heat exchanger for an input heat demand.

Returns:

Type Description
tuple

(hours, Q_b, flowrate, qsign, T_fi, T_fo, T_bave, z, zseg, T_b, T_ftimes, qbzseg, h_fpipes)