Appendix E: Component Reference
The PHS framework is object‑oriented. Key classes:
- Port – effort, flow, connections. For fluid ports, effort = pressure, flow = mass flow rate.
- Connection – binds two ports: effort equality, flow sum zero. Resolved at assembly time.
- Component – abstract base with ports, state, energy computation.
- Pipe1DNonlinear – staggered Euler pipe. Primary state arrays:
double[] m (mass), p_mom (momentum), E_tot (total energy) per cell. Geometry: cellArea, faceArea, dx. TVD flux limiter, boundary ports. Contains internal physical dissipation (friction, heat transfer) via source terms and R matrix.
- Volume0D – mass + internal energy, ideal gas.
- Cylinder – extends Volume0D, adds piston kinematics, Wiebe combustion, valve orifices, knock.
- Orifice – static resistive element implementing the compressible orifice flow model (valve). Stores no state; dissipates energy.
- JunctionT, JunctionX, JunctionH – 0‑junctions (common pressure) enforcing pressure equality and mass flow conservation via Lagrange multipliers.
- EffortSource – prescribed pressure (e.g., atmosphere). Equation: \(p - p_{\text{prescribed}} = 0\).
- FlowSource – prescribed mass flow (e.g., forced induction). Equation: \(\dot{m} - \dot{m}_{\text{prescribed}} = 0\).
- FfowcsWilliamsHawkings – receives exit flow/force, outputs radiated pressure.
- OutdoorReverb – ground echo + FDN.
- PHSWorld – assembles system, solves implicit midpoint via Newton‑Krylov.