|
STAR
Cal STAR — firmware, DAQ server, and engine design
|
Variables | |
| float | PSI = 6894.757293168361 |
| int | N = 4 |
| list | T = [-0.1, 0.0, 0.05, 0.10] |
| list | FIRING = [False, False, True, True] |
| dict | REG_PARAMS |
| float | ATM_PSIA = 101325.0 / PSI |
| float | PC0 = 400.0 * PSI |
| dict | C_FLOW = {"ox": 1.9 / math.sqrt(170.0 * PSI), "fuel": 1.25 / math.sqrt(160.0 * PSI)} |
| float | K_THRUST = 2300.0 |
Feed diagnostics (engine/layerx/diag: ladder, regulator, solenoids, pressurant, saturation, cavitation, injector, thrust shape, ledger) against hand calculations, CoolProp and ``fluids``. Most tests run on a synthetic result with a contract-shaped ``network`` (DATA-CONTRACT 2), whose numbers are chosen so each answer can be worked by hand in the test. One test burns the LE4 helium drawing and is skipped unless ``LAYERX_GOLDEN=1`` and lib/feedtwin records the network.
|
protected |
Definition at line 418 of file test_layerx_feeddiag.py.
Referenced by test_cavitation_number_by_hand_and_flip_risk(), test_injector_velocities_momentum_ratio_and_tilt_by_hand(), test_ledger_rows_design_from_forward_delivered_from_the_burn(), and test_ledger_with_the_erosion_replay_off_reads_the_twins_chamber().
|
protected |
mdot = c sqrt(p_line - Pc0), F = k (mdot_O + mdot_F): closed-form, so the feed solve has one.
Definition at line 573 of file test_layerx_feeddiag.py.
References max.
Referenced by _thrust_result().
|
protected |
What the diagnostics read off a prepared model: branch bores, node fluids, species.
Definition at line 402 of file test_layerx_feeddiag.py.
Referenced by test_a_dead_leg_held_at_atmosphere_is_not_graded(), test_cavitation_number_by_hand_and_flip_risk(), test_diagnostics_on_the_recorder_shape(), and test_saturation_margin_total_and_static_by_hand().
|
protected |
Closed form of mdot = c sqrt(p_out - K mdot^2 - Pc0).
Definition at line 580 of file test_layerx_feeddiag.py.
Referenced by _thrust_result(), test_thrust_breakdown_acceleration_head_when_flown(), and test_thrust_breakdown_by_closed_form().
|
protected |
|
protected |
dT along the isenthalp by integrating CoolProp's own Joule-Thomson coefficient (dT/dp)_h, RK4 in pressure: a different path through the equation of state than the (p, h) flash.
Definition at line 303 of file test_layerx_feeddiag.py.
Referenced by test_joule_thomson_sign_and_magnitude().
|
protected |
Definition at line 35 of file test_layerx_feeddiag.py.
Referenced by _synthetic().
|
protected |
lib/feedtwin's NetworkTrace puts ``<tank>.head`` (kind tank_head) on each path and calls a drawn SOL main valve a solenoid. Reshape the synthetic stand the same way.
Definition at line 775 of file test_layerx_feeddiag.py.
Referenced by test_diagnostics_on_the_recorder_shape().
|
protected |
Definition at line 247 of file test_layerx_feeddiag.py.
Referenced by test_regulator_law_split_and_wide_open_by_hand().
|
protected |
Definition at line 39 of file test_layerx_feeddiag.py.
Referenced by test_a_dead_leg_held_at_atmosphere_is_not_graded(), test_cavitation_number_by_hand_and_flip_risk(), test_diagnostics_on_the_recorder_shape(), test_injector_velocities_momentum_ratio_and_tilt_by_hand(), test_ladder_elements_sum_to_end_to_end_and_head_is_a_gain(), test_ladder_reports_a_recorder_that_does_not_telescope(), test_ladder_without_network_is_unavailable_not_a_raise(), test_ledger_rows_design_from_forward_delivered_from_the_burn(), test_ledger_with_the_erosion_replay_off_reads_the_twins_chamber(), test_pressurant_budget_and_floor_by_hand(), test_regulator_law_split_and_wide_open_by_hand(), test_saturation_margin_total_and_static_by_hand(), and test_solenoid_share_of_regulator_to_tank_by_hand().
|
protected |
Definition at line 586 of file test_layerx_feeddiag.py.
References _fake_engine(), and _fed().
Referenced by test_thrust_breakdown_acceleration_head_when_flown(), and test_thrust_breakdown_by_closed_form().
| test_layerx_feeddiag.test_a_dead_leg_held_at_atmosphere_is_not_graded | ( | ) |
LE4 (3)'s capped LOX fill QD and its dump valve's outlet sit at 14.696 psia with no flow, LOX at 90.19 K on its own saturation line: -0.003 psi, amber on every LOX burn. A node no branch carries flow through while firing is skipped and listed; the feed's own nodes are graded as before.
Definition at line 469 of file test_layerx_feeddiag.py.
References _fake_prep(), and _synthetic().
| test_layerx_feeddiag.test_cavitation_number_by_hand_and_flip_risk | ( | ) |
Definition at line 494 of file test_layerx_feeddiag.py.
References _fake_config(), _fake_prep(), and _synthetic().
| test_layerx_feeddiag.test_diagnostics_on_the_recorder_shape | ( | ) |
Definition at line 795 of file test_layerx_feeddiag.py.
References _fake_prep(), _recorder_style(), and _synthetic().
| test_layerx_feeddiag.test_feed_diagnostics_on_the_le4_helium_burn | ( | monkeypatch | ) |
The baseline design on copv_study_he, pad, at AUDIT 9.6's 578 psia lockup and otherwise default settings, with lib/feedtwin's network recorder on, against the hand checks of AUDIT 9.6-9.7 and the baseline (section 8). Re-baselined 2026-10-07. The AUDIT's figures are the 2026-10-02 twin: adiabatic lines, the 578 psia lockup the default was then. Three things have moved them since, each deliberate: * 2026-10-03 (night), line walls on (Layer X CHANGELOG): the press path's metal warms the gas the bottle's expansion cooled, so each ullage litre takes less helium. He used 0.0906 -> 0.0818 kg; the bottle ends ~220 psi fuller, so the regulator's supply effect (17 psi/1000 psi of inlet fall) is ~3.8 psi smaller and its outlet rise 47.1 -> 43.86 psi; the press flow at 0.5 s is 0.01105 kg/s of 304 K gas, not 0.01121 of 298 K, so the solenoid drops are 1.704 / 1.393 psi (hand, Cv law at the twin's state: 1.7045 / 1.3935) and the regulator's peak use 14.3 %, not the AUDIT's 17.8 %. * 2026-10-06, the ullage storage closure (a35563ce, ``Session._ullage_storage``): the momentum ratio's range 1.0283-1.0312 -> 1.0285-1.0315 (the press flow no longer held at the start-of-step tank pressure); with the closure stubbed out it returns, as does SV-LOX-PRESS's 0.1 % (1.7060 -> 1.7045). The supply datum (35b98bf2) moves nothing here. * 2026-10-07, the dome dial defaults to the drawn dome (b67edc93): 564.7 psia on this drawing. At that lockup every figure here moves (SV-LOX-PRESS 1.609 psi: 4.0 % less helium, 2.4 % thinner, dp ~ mdot^2/rho), and thrust never comes within 2 % of 7.2 kN. The lockup is stated below so the hand checks stay at the point they were made.
Definition at line 820 of file test_layerx_feeddiag.py.
| test_layerx_feeddiag.test_iec_capacity_by_hand_and_against_fluids | ( | p2_psia, | |
| choked ) |
Definition at line 191 of file test_layerx_feeddiag.py.
| test_layerx_feeddiag.test_iec_solenoid_drop_matches_the_audit_hand_check | ( | ) |
Definition at line 212 of file test_layerx_feeddiag.py.
References _he().
| test_layerx_feeddiag.test_injector_velocities_momentum_ratio_and_tilt_by_hand | ( | ) |
Definition at line 533 of file test_layerx_feeddiag.py.
References _fake_config(), and _synthetic().
| test_layerx_feeddiag.test_joule_thomson_sign_and_magnitude | ( | fluid, | |
| sign ) |
Definition at line 324 of file test_layerx_feeddiag.py.
References _jt_by_integration().
| test_layerx_feeddiag.test_ladder_elements_sum_to_end_to_end_and_head_is_a_gain | ( | ) |
Definition at line 125 of file test_layerx_feeddiag.py.
References _synthetic().
| test_layerx_feeddiag.test_ladder_reports_a_recorder_that_does_not_telescope | ( | ) |
Definition at line 157 of file test_layerx_feeddiag.py.
References _synthetic().
| test_layerx_feeddiag.test_ladder_without_network_is_unavailable_not_a_raise | ( | ) |
Definition at line 168 of file test_layerx_feeddiag.py.
References _synthetic().
| test_layerx_feeddiag.test_ledger_rows_design_from_forward_delivered_from_the_burn | ( | ) |
Definition at line 678 of file test_layerx_feeddiag.py.
References _fake_config(), _synthetic(), and max.
| test_layerx_feeddiag.test_ledger_with_the_erosion_replay_off_reads_the_twins_chamber | ( | ) |
Nozzle erosion off (run 20261102-123645-807b98): no replay, no ``delivered``. The burn still fired, on the twin's chamber; Pc, O/F, thrust, Isp and the flows read '—' in the Overview ledger. They come from ``series.chamber`` and the sides' flows; what only the replay computes says why.
Definition at line 740 of file test_layerx_feeddiag.py.
References _fake_config(), and _synthetic().
| test_layerx_feeddiag.test_pressurant_budget_and_floor_by_hand | ( | ) |
Definition at line 338 of file test_layerx_feeddiag.py.
References _synthetic().
| test_layerx_feeddiag.test_regulator_law_split_and_wide_open_by_hand | ( | ) |
Definition at line 251 of file test_layerx_feeddiag.py.
References _he(), _reg_target(), and _synthetic().
| test_layerx_feeddiag.test_saturation_margin_total_and_static_by_hand | ( | ) |
Definition at line 432 of file test_layerx_feeddiag.py.
References _fake_prep(), _synthetic(), and min.
| test_layerx_feeddiag.test_solenoid_share_of_regulator_to_tank_by_hand | ( | ) |
Definition at line 284 of file test_layerx_feeddiag.py.
References _he(), and _synthetic().
| test_layerx_feeddiag.test_thrust_breakdown_acceleration_head_when_flown | ( | ) |
Definition at line 652 of file test_layerx_feeddiag.py.
References _fed(), and _thrust_result().
| test_layerx_feeddiag.test_thrust_breakdown_by_closed_form | ( | ) |
Definition at line 614 of file test_layerx_feeddiag.py.
References _fed(), _thrust_result(), and max.
| float test_layerx_feeddiag.ATM_PSIA = 101325.0 / PSI |
Definition at line 244 of file test_layerx_feeddiag.py.
| dict test_layerx_feeddiag.C_FLOW = {"ox": 1.9 / math.sqrt(170.0 * PSI), "fuel": 1.25 / math.sqrt(160.0 * PSI)} |
Definition at line 569 of file test_layerx_feeddiag.py.
| list test_layerx_feeddiag.FIRING = [False, False, True, True] |
Definition at line 32 of file test_layerx_feeddiag.py.
| float test_layerx_feeddiag.K_THRUST = 2300.0 |
Definition at line 570 of file test_layerx_feeddiag.py.
| int test_layerx_feeddiag.N = 4 |
Definition at line 30 of file test_layerx_feeddiag.py.
| float test_layerx_feeddiag.PC0 = 400.0 * PSI |
Definition at line 568 of file test_layerx_feeddiag.py.
| float test_layerx_feeddiag.PSI = 6894.757293168361 |
Definition at line 20 of file test_layerx_feeddiag.py.
| dict test_layerx_feeddiag.REG_PARAMS |
Definition at line 232 of file test_layerx_feeddiag.py.
| list test_layerx_feeddiag.T = [-0.1, 0.0, 0.05, 0.10] |
Definition at line 31 of file test_layerx_feeddiag.py.