Files
Entropyk/apps/web/public/docs/components/bphx.md
sepehr 3358b74342 Add diagram workbench UI with Modelica DoF coaching and ISO glyphs.
Ship the Next.js cycle editor with CAD chrome, technical HX symbols, Fixed/Free boundary guidance, and secondary water/air pressure drop support in the solver stack.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-17 22:46:46 +02:00

120 lines
3.7 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# BphxEvaporator / BphxCondenser (Brazed Plate HX)
Config types: `"BphxEvaporator"`, `"BphxCondenser"`
Source: `crates/components/src/heat_exchanger/bphx_evaporator.rs`, `bphx_condenser.rs`, shared geometry/correlation helpers
---
## EN
### Purpose & model
Brazed-plate HX with **geometry + two-phase correlation → h → UA estimate**, then runtime solve on an **inner ε-NTU** residual model.
#### Correlations (selectable)
Default **Longo 2004**. Also **Shah 1979**, **Shah 2021**.
Full registry (also Kandlikar, GungorWinterton, Gnielinski, DittusBoelter, Ko 2021, Friedel ΔP): see [correlations-and-maps.md](./correlations-and-maps.md).
Equivalent Reynolds construction (schematic):
```
Re_l = G · d_h / μ_l
Re_eq = Re_l · (1 x + x · √(ρ_l / ρ_v))
```
Longo-style Nu (illustrative forms used in the implementation path):
```
Evaporation: Nu ~ f(Re_eq, Pr_l) (e.g. 0.05 · Re_eq^0.8 · Pr_l^0.33)
Condensation: Nu ~ f(Re_eq, Pr_l, ρ*) (e.g. 1.875 · Re_eq^0.35 · Pr_l^0.33 · …)
h = Nu · k_l / d_h
UA_est = h · A · z_ua
```
Pressure drop (schematic):
```
ΔP = z_dp · 2 · f · L · G² / (ρ · d_h)
```
**Important:** the **Newton system residuals** for the component are the **inner ε-NTU** residual set (`n_equations` of the inner model, typically 2 for the base HX path). The correlation updates **UA** (when `update_ua_from_htc` / geometry path is engaged); it is **not** a full multi-zone moving-boundary residual stack.
### Modes / targets
| Type | Mode | Notes |
|------|------|--------|
| `BphxEvaporator` | **DX only** | Outlet is superheated vapor. `target_superheat_k` (default 5 K) is diagnostic/target storage — not a flooded shell model. For flooded shell-and-tube use `FloodedEvaporator`. |
| `BphxCondenser` | Subcooling target | `target_subcooling_k` (default 3 K) |
### Ports
4-port Modelica-style naming in the system graph when wired:
| Port | Role |
|------|------|
| `inlet` / `outlet` | Refrigerant |
| `secondary_inlet` / `secondary_outlet` | Secondary fluid |
Geometry fields: plate length/width, thickness, chevron, channel spacing, optional `dh_m` / `area_m2` overrides.
### Calibration
| Key | Meaning | Default |
|-----|---------|---------|
| `z_ua` / `Z_UA` | UA scale | **1.0** |
| `z_dp` / `Z_dpc` | ΔP scale | **1.0** |
| `ua` explicit | sets `z_ua = ua / UA_nom` | |
Legacy `f_ua` / `f_dp` accepted in JSON.
### JSON parameters (main)
| Key | Meaning | Default |
|-----|---------|---------|
| `n_plates` | plate count | 20 |
| `plate_length_m` / `plate_width_m` | geometry | |
| `chevron_angle_deg` | chevron | 60 |
| `correlation` | Longo2004 / Shah1979 / Shah2021 | Longo2004 |
| `target_superheat_k` | DX target (evap) | 5 K |
| `target_subcooling_k` | SC target (cond) | 3 K |
| `refrigerant` / `secondary_fluid` | fluids | |
| `z_ua`, `z_dp` | calib | 1.0 |
### DoF / system usage
Prefer live secondary wiring for closed loops. Pair `z_ua` free + measured SST/SDT for inverse calibration (same Fixed/Free discipline as other HX).
---
## FR
### But & modèle
Échangeurs **à plaques brasées** : géométrie + **corrélation biphasique** (Longo 2004 / Shah) → coefficient h → UA, puis solveur sur modèle **ε-NTU interne**.
Formes types :
```
Re_eq = Re_l · (1 x + x · √(ρ_l/ρ_v))
Nu = f(Re_eq, Pr, …) # Longo / Shah selon `correlation`
h = Nu · k / d_h
UA = h · A · z_ua
```
Le **Newton** ne résout pas la corrélation plaque par plaque : il résout le **HX ε-NTU** ; la corrélation **calibre/estime UA**.
### Modes
- **BphxEvaporator** : DX uniquement (pas un flooded shell).
- **BphxCondenser** : cible de sous-refroidissement.
### Calibration
`z_ua = 1`, `z_dp = 1` par défaut. Alias BOLT `Z_UA`, `Z_dpc`.
### Ports / JSON
Voir tableaux EN.