sunpeek.core_methods.dcam_lite_collective.fluid_adapter#
Adapter utilities for using SunPeek fluid objects in D-CAM auxiliary models.
Design rule#
SunPeek’s component/plant fluid object is the primary source of truth.
This module converts a SunPeek fluid object, for example array.fluid_solar, into the numerical SI properties required by standalone auxiliary models such as:
pipe model
future HEX model
Fluid-property policy#
- Strict mode:
All required properties must come from the SunPeek fluid object.
- Fallback-bank mode:
rho and cp must still come from SunPeek. Missing k and/or mu may be supplied from an explicit transport-property bank.
- This is useful because many SunPeek fluid objects provide:
density rho
heat capacity cp
- but may not yet provide:
thermal conductivity k
dynamic viscosity mu
Important
k and mu cannot be uniquely derived from rho and cp alone. A fallback bank is an engineering approximation, not a true derivation.
Architecture#
main.py should not choose glycol/water or fallback policy.
The intended production path is:
- main.py
-> passes the relevant SunPeek fluid object to pipe_adapter.py
- pipe_adapter.py
-> reads PipeCfg.fluid_transport_policy and PipeCfg.fluid_fallback_bank -> calls this module
- fluid_adapter.py
- -> gets rho/cp/k/mu from SunPeek or, only when explicitly configured,
fills missing k/mu from the selected fallback bank
Functions
Return a timestamp-aligned fluid property Series from a SunPeek fluid object. |