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

Classes

class  Case
class  Factor

Functions

Any _get (Any obj, str path)
Tuple[List[Factor], List[str]] factors (Any prep, Any config)
Any _perturbed_config (Any config, Dict[str, Any] engine)
Dict[str, Optional[float]] _metrics (Dict[str, Any] summary)
Dict[str, Any] _burn_case (Tuple[Any, Any, Any, List[Any], Dict[str, Any]] args)
str _trip_words (Dict[str, Any] trip)
Dict[str, Any] run_sweep (Any config, Any drawing, Any settings, List[Any] overrides, *, Optional[Callable[[str, float], None]] progress=None, Callable[[], bool] cancelled=lambda:False, Optional[int] workers=None)

Variables

 SPARE_PSI = float(_LIMITS["copv_headroom_psi"]["value"])
 STIFFNESS_FLOOR = float(_LIMITS["stiffness_floor"]["value"])
 RESIDUAL_KG = float(_LIMITS["residual_kg"]["value"])
dict METRICS
dict _SEED = {}

Detailed Description

Phase 5: which unmeasured input moves the burn, and by how much.

A burn rests on inputs nobody has measured yet. Each is varied on its own, from the low end
of its plausible range to the high end, with everything else held at nominal. This is a
tornado. It answers two questions:

* how wide the answer is: the band on impulse, burn time, thrust and margins, as the
  root-sum-square of the one-at-a-time swings;
* which measurement narrows it most: the factors ranked by how far they move the burn.

A one-at-a-time sweep assumes the effects are roughly independent and linear over their
ranges, which is what the RSS assumes too. It costs 2N burns rather than the hundreds a Monte
Carlo needs, and it says *which* input, which a Monte Carlo cloud does not.

The factors, and where their ranges come from
----------------------------------------------
Feed, from the drawing:

* **Dome regulator supply-pressure effect, ×0.5–1.5.** One GN2 back-fit plus the vendor's sheet.
* **Dome regulator droop, ×0.5–1.5.** Same basis.
* **Ullage collapse, off → on.** A model choice. The collapse model is a stated lower bound.

Engine, through EngineDesign's own measurement fields, so the engine card is rebuilt by
EngineDesign under each perturbation rather than scaled by a guessed sensitivity:

* **LOX and fuel orifice Cd, ±3 %.** The scatter of the Lichtarowicz correlation the plate is
  sized with. Replace it with a cold-flow Cd.
* **Rupe mixing E_m_opt, 0.70 / 0.85.** The literature range the spray report uses
  (engine/core/injectors/spray_report.py). On the 6.5 kN engine that range is 6242–6601 N.
* **Nozzle efficiency, ±0.02 about the config's value.** Assumed.

A factor that has been measured uses its stated uncertainty instead. A measured value with
no uncertainty is treated as exact and dropped from the sweep, which the result says.

Burns run without the erosion replay. The replay moves every case the same way, and the
question here is the difference between cases. They run in parallel worker processes, each
seeded with the nominal engine card, so only the engine perturbations pay for a new card.

Function Documentation

◆ _burn_case()

Dict[str, Any] engine.layerx.uncertainty._burn_case ( Tuple[Any, Any, Any, List[Any], Dict[str, Any]] args)
protected
One case, start to finish, in whatever process runs it.

Definition at line 327 of file uncertainty.py.

References _metrics(), _perturbed_config(), and _trip_words().

◆ _get()

Any engine.layerx.uncertainty._get ( Any obj,
str path )
protected

Definition at line 99 of file uncertainty.py.

◆ _metrics()

Dict[str, Optional[float]] engine.layerx.uncertainty._metrics ( Dict[str, Any] summary)
protected

Definition at line 308 of file uncertainty.py.

Referenced by _burn_case().

◆ _perturbed_config()

Any engine.layerx.uncertainty._perturbed_config ( Any config,
Dict[str, Any] engine )
protected

Definition at line 288 of file uncertainty.py.

References split().

Referenced by _burn_case().

◆ _trip_words()

str engine.layerx.uncertainty._trip_words ( Dict[str, Any] trip)
protected
A tripped case, in the words a crossing lists it with.

Definition at line 368 of file uncertainty.py.

Referenced by _burn_case().

◆ factors()

Tuple[List[Factor], List[str]] engine.layerx.uncertainty.factors ( Any prep,
Any config )
The factors for this burn, each with its low and high cases, and notes about any dropped.

Definition at line 105 of file uncertainty.py.

References max, and min.

Referenced by run_sweep().

◆ run_sweep()

Dict[str, Any] engine.layerx.uncertainty.run_sweep ( Any config,
Any drawing,
Any settings,
List[Any] overrides,
* ,
Optional[Callable[[str, float], None]] progress = None,
Callable[[], bool] cancelled = lambda: False,
Optional[int] workers = None )
The nominal burn and every factor's cases, in parallel; the tornado and the band.

Definition at line 377 of file uncertainty.py.

References factors(), max, and min.

Variable Documentation

◆ _SEED

dict engine.layerx.uncertainty._SEED = {}
protected

Definition at line 320 of file uncertainty.py.

◆ METRICS

dict engine.layerx.uncertainty.METRICS
Initial value:
1= {
2 "total_impulse_Ns": ("total_impulse_Ns",),
3 "burn_time_s": ("burn_time_s",),
4 "mean_thrust_N": ("mean_thrust_N",),
5 "pc_mean_psia": ("pc_mean_psia",),
6 "of_mean": ("of_mean",),
7 "ox_min_psia": ("ox", "min_psia"),
8 "fuel_min_psia": ("fuel", "min_psia"),
9 "ox_stiffness_min": ("ox", "stiffness_min"),
10 "fuel_stiffness_min": ("fuel", "stiffness_min"),
11 "copv_end_psia": ("copv_end_psia",),
12}

Definition at line 60 of file uncertainty.py.

◆ RESIDUAL_KG

engine.layerx.uncertainty.RESIDUAL_KG = float(_LIMITS["residual_kg"]["value"])

Definition at line 57 of file uncertainty.py.

◆ SPARE_PSI

engine.layerx.uncertainty.SPARE_PSI = float(_LIMITS["copv_headroom_psi"]["value"])

Definition at line 51 of file uncertainty.py.

◆ STIFFNESS_FLOOR

engine.layerx.uncertainty.STIFFNESS_FLOOR = float(_LIMITS["stiffness_floor"]["value"])

Definition at line 53 of file uncertainty.py.