|
STAR
Cal STAR — firmware, DAQ server, and engine design
|
Public Member Functions | |
| None | __init__ (self, Sequence[float] p, Sequence[float] T, Mapping[str, Any] values, *, str source, str name="measured") |
| str | name (self) |
| bool | supports (self, str prop) |
| None | update (self, StatePair pair, float v1, float v2) |
| float | value (self, str prop) |
| Phase | phase (self) |
| float|None | quality (self) |
Public Attributes | |
| source = source | |
Protected Attributes | |
| _p = np.asarray(p, dtype=float) | |
| _T = np.asarray(T, dtype=float) | |
| str | _name = name |
| dict | _interp = {} |
| _cursor = threading.local() | |
Properties read from a measured grid over pressure and temperature.
Args:
p: Strictly increasing pressures [Pa].
T: Strictly increasing temperatures [K].
values: Property name to a ``(len(p), len(T))`` array of values, in the
SI units :data:`feedtwin.props.state.PROPERTIES` declares.
source: Where the numbers came from -- a test campaign, a datasheet
revision. Carried into every :class:`ThermoState` this produces, so
a result can always be traced to the measurement behind it.
name: Backend identifier; defaults to ``"measured"``.
Only ``StatePair.PT`` is addressable. Any other pair raises
:class:`OutOfRange`, which the chain answers by trying the next backend --
the same path as a state point outside the grid.
Definition at line 41 of file tabulated.py.
| None feedtwin.props.backends.tabulated.TabulatedProperties.__init__ | ( | self, | |
| Sequence[float] | p, | ||
| Sequence[float] | T, | ||
| Mapping[str, Any] | values, | ||
| * | , | ||
| str | source, | ||
| str | name = "measured" ) |
Definition at line 59 of file tabulated.py.
| str feedtwin.props.backends.tabulated.TabulatedProperties.name | ( | self | ) |
Definition at line 108 of file tabulated.py.
References feedtwin.props.backends.coolprop.CoolPropBackend._name, and _name.
| Phase feedtwin.props.backends.tabulated.TabulatedProperties.phase | ( | self | ) |
Unknown: a measured grid does not carry phase information. Reported honestly rather than guessed. A caller that needs the phase gets it from an equation-of-state backend, which is what the chain is for.
Definition at line 144 of file tabulated.py.
| float | None feedtwin.props.backends.tabulated.TabulatedProperties.quality | ( | self | ) |
Definition at line 153 of file tabulated.py.
| bool feedtwin.props.backends.tabulated.TabulatedProperties.supports | ( | self, | |
| str | prop ) |
Definition at line 111 of file tabulated.py.
References _interp.
| None feedtwin.props.backends.tabulated.TabulatedProperties.update | ( | self, | |
| StatePair | pair, | ||
| float | v1, | ||
| float | v2 ) |
Definition at line 114 of file tabulated.py.
References _cursor, feedtwin.props.backends.coolprop.CoolPropBackend._name, _name, _p, and _T.
Referenced by combined_gui.PressureBarWidget.set_global_line_ys(), combined_gui.PressureBarWidget.set_limits(), and combined_gui.PressureBarWidget.set_value().
| float feedtwin.props.backends.tabulated.TabulatedProperties.value | ( | self, | |
| str | prop ) |
Definition at line 131 of file tabulated.py.
References _cursor, _interp, feedtwin.props.backends.coolprop.CoolPropBackend._name, and _name.
Referenced by feedtwin.model.param.Uncertainty.__post_init__(), and feedtwin.model.param.Uncertainty.bounds().
|
protected |
Definition at line 105 of file tabulated.py.
|
protected |
Definition at line 85 of file tabulated.py.
Referenced by feedtwin.vessels.geometry.TabulatedGeometry.cross_section(), supports(), value(), feedtwin.vessels.geometry.TabulatedGeometry.volume_below(), and feedtwin.vessels.geometry.TabulatedGeometry.wetted_area().
|
protected |
Definition at line 70 of file tabulated.py.
|
protected |
Definition at line 68 of file tabulated.py.
Referenced by update().
|
protected |
Definition at line 69 of file tabulated.py.
Referenced by update().
| feedtwin.props.backends.tabulated.TabulatedProperties.source = source |
Definition at line 71 of file tabulated.py.