SingleRunResult API Reference
geoloop.bin.SingleRunSim.SingleRunResult
Container class holding the results of a single BHE simulation run.
Stores time series, depth-dependent, and spatial thermal field output data.
__init__
__init__(
hours: ndarray,
Q_b: ndarray,
flowrate: ndarray,
qsign: ndarray,
T_fi: ndarray,
T_fo: ndarray,
T_bave: ndarray,
dploop: ndarray,
qloop: ndarray,
z: ndarray,
zseg: ndarray,
T_b: ndarray,
T_f: ndarray,
qzb: ndarray,
Re_in: ndarray,
Re_out: ndarray,
nPipes: int,
k_s: ndarray,
k_g: ndarray,
Tg: ndarray,
numerical_result: ndarray,
ag: object,
) -> None
Initialize simulation result container.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
hours
|
ndarray
|
Time values of the simulation results [h]. |
required |
Q_b
|
ndarray
|
Produced power over time [W]. |
required |
flowrate
|
ndarray
|
Mass flow rate over time [kg/s]. |
required |
qsign
|
ndarray
|
Sign of power production (1 = heat extraction, -1 = heat injection). |
required |
T_fi
|
ndarray
|
Inlet fluid temperature over time [°C]. |
required |
T_fo
|
ndarray
|
Outlet fluid temperature over time [°C]. |
required |
T_bave
|
ndarray
|
Average borehole wall temperature over time [°C]. |
required |
dploop
|
ndarray
|
Required pressure for loop pumping over time [bar]. |
required |
qloop
|
ndarray
|
Power required to drive loop pumping over time [W]. |
required |
z
|
ndarray
|
Node-based depth coordinates used for |
required |
zseg
|
ndarray
|
Segment-based depth coordinates used for |
required |
T_b
|
ndarray
|
Borehole wall temperature as function of time and depth [°C]. Shape: (n_time, n_depth_segments) |
required |
T_f
|
ndarray
|
Fluid temperature as function of time, depth and pipe index [°C]. Shape: (n_time, n_depth_nodes, nPipes) |
required |
qzb
|
ndarray
|
Distributed heat flux at borehole wall [W]. Shape: (n_time, n_depth_segments) |
required |
Re_in
|
ndarray
|
Reynolds number in inlet pipes over time [-]. |
required |
Re_out
|
ndarray
|
Reynolds number in outlet pipes over time [-]. |
required |
nPipes
|
int
|
Number of pipes considered in the simulation [-]. |
required |
k_s
|
ndarray
|
Depth-interpolated subsurface thermal conductivity [W/mK]. |
required |
k_g
|
ndarray
|
Depth-interpolated grout thermal conductivity [W/mK]. |
required |
Tg
|
ndarray
|
Depth-interpolated ground temperature [°C]. |
required |
numerical_result
|
ndarray
|
Full 4D temperature field output from a BHE simulation with the numerical finite volume model. Dimension order: (time, x, r, z) |
required |
ag
|
object
|
Axial grid object (grid properties for finite volume model). |
required |
save_T_field_FINVOL
Save the full 4D temperature field to an HDF5/NetCDF file.
The output quantity corresponds to the finite-volume radial
temperature field stored in self.numerical_result.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
outpath
|
str or Path
|
Base output file path (without |
required |
Returns:
| Type | Description |
|---|---|
None
|
|
get_n_pipes
getzseg
Return segment-based depth coordinates.
These correspond to the depth resolution used for results such as
borehole wall temperature (T_b) and borehole heat flux (qzb).
Returns:
| Type | Description |
|---|---|
ndarray
|
Depth values in meters, defined at segment mid-points. |
gethours
Return the simulation time coordinate.
Returns:
| Type | Description |
|---|---|
ndarray
|
Time values in hours. |
getz
Return node-based depth coordinates.
These correspond to the depth resolution used for pipe fluid
temperature (T_f) results.
Returns:
| Type | Description |
|---|---|
ndarray
|
Depth values in meters, defined at nodal locations. |
getResultAttributesTimeseriesScalar
Return a list of available scalar time-series result keys.
These correspond to simulation outputs varying only in time.
Returns:
| Type | Description |
|---|---|
list of str
|
Names of time-dependent scalar result variables. |
getResultAttributesTimeseriesDepthseg
Return time-series attributes defined on depth segments.
Returns:
| Type | Description |
|---|---|
list of str
|
Variable names indexed by (time, depth segment). |
getResultAttributesTimeserieDepth
Return time-series attributes defined on depth nodes.
Returns:
| Type | Description |
|---|---|
list of str
|
Variable names indexed by (time, depth node). |