STAR
Cal STAR — firmware, DAQ server, and engine design
Loading...
Searching...
No Matches
feedtwin.engine.component Namespace Reference

Classes

class  InjectorLeg

Functions

tuple[InjectorLeg, InjectorLeg] injector_legs (EngineDesign design)
ChamberResult fold_injectors (ChamberResult chamber, Network network, Mapping[str, str] ports, Mapping[str, float] flows, Mapping[str, float] pressures)

Detailed Description

The injector as a network branch, and the engine as a network boundary.

Two objects, and the split matters.

An **injector leg** is an ordinary hydraulic component: an orifice of known area
and discharge coefficient, one per propellant, sitting at the downstream end of
each feed line. Nothing about it is special except that its area came out of a
Layer-1 optimisation rather than off a drawing.

The **engine** is not a component at all. It is a boundary condition, and a
circular one: chamber pressure depends on the flows, and the flows depend on
chamber pressure through the injector's pressure difference. The session closes
that loop each coupling step (``Session._close_chamber``), root-finding the
chamber pressure the network and the engine agree on -- the same coupled
injector-to-chamber solve EngineDesign performs, done here around a whole feed
system instead of around two pressures.

Why the loop is worth having
----------------------------
It is the reason a pressure-fed engine is stable in the large. Raise tank
pressure and flow rises, so chamber pressure rises, so the injector's pressure
difference rises by *less* than the tank did -- the engine absorbs part of every
upstream change. That is also why injector stiffness is a design rule rather
than a preference: as the injector's share of the total pressure drop falls, the
loop gain rises, and below roughly 20% the engine starts responding to its own
chamber more than to its tanks.

Function Documentation

◆ fold_injectors()

ChamberResult feedtwin.engine.component.fold_injectors ( ChamberResult chamber,
Network network,
Mapping[str, str] ports,
Mapping[str, float] flows,
Mapping[str, float] pressures )
The chamber's answer, flagged extrapolated if either injector leg's card
lookup was off its hull.

A step's ``extrapolated`` flag is the chamber's, which only ever asked the
chamber table; an injector card read below its sampled inlet pressures (a
vent-down, a low-pressure firing) was clamped and never counted. The flag
means "outside what the card knows", so the injectors fold into it.

Definition at line 185 of file component.py.

◆ injector_legs()

tuple[InjectorLeg, InjectorLeg] feedtwin.engine.component.injector_legs ( EngineDesign design)
Build the two injector branches from an imported engine design.

Returns ``(oxidiser, fuel)``. The component ids are derived from the design
name so a report can trace a branch back to the config it came from.

Definition at line 153 of file component.py.