|
STAR
Cal STAR — firmware, DAQ server, and engine design
|
Public Member Functions | |
| float | set_pressure (self) |
| float | reseat_pressure (self) |
| float | full_lift_pressure (self) |
| tuple[float, bool] | lift_for (self, float dp_actuating, bool was_open) |
| bool | isolates (self, Mapping[str, float]|None signals=None) |
| float | pressure_drop (self, float mdot, FlowConditions flow) |
| float|None | flow_ceiling (self, FlowConditions flow) |
| float|None | rated_capacity (self, FlowConditions flow) |
| dict[str, float] | diagnostics (self, float mdot, FlowConditions flow) |
| list[Violation] | check (self) |
| dict[str, Any] | model (self) |
| Public Member Functions inherited from feedtwin.comps.elements.Valve | |
| float | effective_cv (self, float position) |
| bool | is_choked (self, float dp_available, FlowConditions flow) |
| float|None | choked_dp (self, FlowConditions flow) |
| Public Member Functions inherited from feedtwin.comps.base.HydraulicComponent | |
| None | __init__ (self, ComponentInstance instance) |
| str | id (self) |
| str | type (self) |
| float | static_head (self, FlowConditions flow) |
| float | total_dp (self, float mdot, FlowConditions flow) |
| float | signal (self, FlowConditions flow, str name, float default=1.0) |
| float|None | pinned_flow (self, float dp_available, FlowConditions flow) |
| int | n_residuals (self) |
| Sequence[float] | residuals (self, EvalContext ctx) |
| Mapping[str, float] | outputs (self, EvalContext ctx) |
| FlowConditions | conditions (self, PortState port, Mapping[str, float] signals) |
| str | __repr__ (self) |
Protected Member Functions | |
| float | _lift (self, Mapping[str, float] signals) |
| GasCv|None | _gas (self, FlowConditions flow) |
| tuple[float, float]|None | _gas_choke (self, FlowConditions flow) |
| Protected Member Functions inherited from feedtwin.comps.elements.Valve | |
| float|None | _legacy_liquid_ceiling (self, FlowConditions flow) |
Additional Inherited Members | |
| Public Attributes inherited from feedtwin.comps.base.HydraulicComponent | |
| instance = instance | |
| p = instance.si_params() | |
| opt = dict(instance.options) | |
| Static Public Attributes inherited from feedtwin.comps.base.HydraulicComponent | |
| str | inlet_port = "inlet" |
| str | outlet_port = "outlet" |
| bool | symmetric = False |
| conditions_provider = None | |
|
protected |
This valve as IEC 60534 sees a gas, or None on a liquid.
Reimplemented from feedtwin.comps.elements.Valve.
Definition at line 140 of file relief.py.
References _lift(), feedtwin.comps.elements.Valve.effective_cv(), p, and feedtwin.comps.base.HydraulicComponent.p.
|
protected |
``(x_critical, F_gamma)`` for this fluid, or None if it is not a gas. ``x`` is IEC 60534's pressure-drop ratio ``dp/p1``; choking begins at ``F_gamma * xT``. ``F_gamma = gamma / 1.40`` carries the ideal-gas specific-heat ratio relative to air, which is what makes helium (1.667) choke at a different ratio from nitrogen (1.40).
Reimplemented from feedtwin.comps.elements.Valve.
Definition at line 154 of file relief.py.
References p, and feedtwin.comps.base.HydraulicComponent.p.
|
protected |
Definition at line 131 of file relief.py.
Referenced by _gas(), diagnostics(), isolates(), and pressure_drop().
| list[Violation] feedtwin.comps.relief.ReliefValve.check | ( | self | ) |
Design limits this component's configuration breaks. Configuration only -- nothing here depends on the operating point, so it can be run the moment a network is loaded and long before it is solved. Bend radius is the case that motivated it: a line bent tighter than its tube allows is a fabrication problem, and finding out at the bender is expensive.
Reimplemented from feedtwin.comps.base.HydraulicComponent.
Definition at line 197 of file relief.py.
References set_pressure().
| dict[str, float] feedtwin.comps.relief.ReliefValve.diagnostics | ( | self, | |
| float | mdot, | ||
| FlowConditions | flow ) |
Derived quantities worth reporting: velocity, Reynolds number, K. Never consumed by a solver. This is what a frame and a report show, and what makes a result inspectable rather than just a number.
Reimplemented from feedtwin.comps.elements.Valve.
Definition at line 182 of file relief.py.
References _lift(), feedtwin.comps.elements.Valve.effective_cv(), feedtwin.comps.base.HydraulicComponent.flow_ceiling(), full_lift_pressure(), feedtwin.comps.base.HydraulicComponent.pressure_drop(), reseat_pressure(), and set_pressure().
| float | None feedtwin.comps.relief.ReliefValve.flow_ceiling | ( | self, | |
| FlowConditions | flow ) |
Choked mass flow through the valve [kg/s], or None for a liquid. IEC 60534-2-1 at the critical ratio ``x = F_gamma . xT``, where the expansion factor is exactly ``2/3`` and the flow stops responding to downstream pressure. A liquid should have no such ceiling, and still has the old one (:func:`_legacy_liquid_ceiling`; deferred, R037).
Reimplemented from feedtwin.comps.elements.Valve.
Definition at line 161 of file relief.py.
References feedtwin.comps.elements.Valve._gas().
| float feedtwin.comps.relief.ReliefValve.full_lift_pressure | ( | self | ) |
Differential at which it reaches rated lift [Pa].
Definition at line 106 of file relief.py.
References p, feedtwin.comps.base.HydraulicComponent.p, and set_pressure().
Referenced by diagnostics(), and lift_for().
| bool feedtwin.comps.relief.ReliefValve.isolates | ( | self, | |
| Mapping[str, float] | None | signals = None ) |
Commanded shut, so the branch is an open circuit this solve. The threshold is on *travel*, not on the resulting Cv: a valve at 0.5% open is shut as far as any stand is concerned, and leaving it in the network buys a row Newton cannot move.
Reimplemented from feedtwin.comps.elements.Valve.
Definition at line 137 of file relief.py.
References _lift().
| tuple[float, bool] feedtwin.comps.relief.ReliefValve.lift_for | ( | self, | |
| float | dp_actuating, | ||
| bool | was_open ) |
``(lift, open)`` for the pressure across the valve, given its history. Shut, it opens once ``dp_actuating`` reaches the set pressure; open, it stays open until ``dp_actuating`` falls below the reseating pressure. The lift is proportional between the reseating pressure and full lift.
Definition at line 110 of file relief.py.
References full_lift_pressure(), max, min, reseat_pressure(), and set_pressure().
| dict[str, Any] feedtwin.comps.relief.ReliefValve.model | ( | self | ) |
The run record's ``model`` block for this valve.
Definition at line 229 of file relief.py.
References feedtwin.comps.base.HydraulicComponent.instance.
Referenced by feedtwin.model.component.ComponentInstance.to_dict().
| float feedtwin.comps.relief.ReliefValve.pressure_drop | ( | self, | |
| float | mdot, | ||
| FlowConditions | flow ) |
Flow-dependent pressure loss [Pa]. Always non-negative. A *loss*: it opposes the flow, so it lowers the downstream pressure whichever way the fluid is going. Reverse flow is each component's own business -- symmetric for a pipe, very much not for a check valve. Anything that does **not** depend on the direction of flow belongs in :meth:`static_head`, not here. See that method for why the distinction is load-bearing rather than tidy.
Reimplemented from feedtwin.comps.elements.Valve.
Definition at line 146 of file relief.py.
References feedtwin.comps.elements.Valve._gas(), _lift(), feedtwin.comps.elements.Valve.effective_cv(), p, and feedtwin.comps.base.HydraulicComponent.p.
| float | None feedtwin.comps.relief.ReliefValve.rated_capacity | ( | self, | |
| FlowConditions | flow ) |
Choked gas flow at full lift [kg/s] for the inlet state ``flow``. Pass the conditions at the relieving pressure, ``full_lift_pressure`` plus the outlet's, for the valve's rated capacity. ``None`` for a liquid.
Definition at line 167 of file relief.py.
References p, and feedtwin.comps.base.HydraulicComponent.p.
| float feedtwin.comps.relief.ReliefValve.reseat_pressure | ( | self | ) |
Differential below which an open valve shuts [Pa].
Definition at line 101 of file relief.py.
References p, feedtwin.comps.base.HydraulicComponent.p, and set_pressure().
Referenced by diagnostics(), and lift_for().
| float feedtwin.comps.relief.ReliefValve.set_pressure | ( | self | ) |
Differential at which it begins to open [Pa].
Definition at line 96 of file relief.py.
References p, and feedtwin.comps.base.HydraulicComponent.p.
Referenced by check(), diagnostics(), full_lift_pressure(), lift_for(), and reseat_pressure().