Nuclear
Qualify PWR and SMR primary-secondary thermal-hydraulics, Class 1E Division I/II 4.16 kV safety buses, and emergency diesel generator load sequencing with bit-exact deterministic repeatability and complete 10 CFR 50 Appendix B traceability.
Primary coolant loop, secondary feedwater, and Class 1E safety power
Inside containment, the reactor vessel, pressuriser, reactor coolant pump, and steam generator U-tubes couple directly to the secondary turbine and auxiliary feedwater train—while independent Class 1E Division I and Division II 4.16 kV safety buses and EDGs execute on zero-allocation lockstep scans with zero garbage-collection stalls.
LOOP coupled thermal-hydraulic and electrical verification
Safety-classified Class 1E reactor trip, EDG start, and Auxiliary Feedwater (AFW) actuation execute on deterministic 2-out-of-4 (2oo4) safety-grade protection voting with strict Division I and Division II independence—never gated behind supervisory shadow checks. Loss of Offsite Power (LOOP) with turbine trip reduces secondary heat removal and drives pressuriser pressure upward from its 155 bar nominal operating pressure (actuating pressuriser spray around 157 bar and lifting PORVs around 161–162 bar) before reactor trip and AFW decay-heat removal restore primary inventory; TwinScript drives pre-outage qualification suites across 1x HIL benches and 100x+ virtual runs alongside non-safety post-trip condensate makeup and LOTO switching orders governed by guardrail::plan_mutation, twin::shadow_qualify, and guardrail::apply.
// Class 1E reactor trip, EDG start, and AFW actuation run on deterministic 2oo4 safety voting
// with strict Division I/II independence—never gated by supervisory shadow_qualify.
// TwinScript monitors LOOP transients and governs non-safety condensate makeup orders.
script PwrLoopSupervisoryResponse {
requires capability::ReadTelemetry;
requires capability::ShadowSimulate;
requires capability::ProposeWrite(scope: "supervisory.post_trip.*");
fn required_condensate_makeup(core_decay_kw: Quantity<kW>, sg_level: Quantity<m>) -> Quantity<L/s> {
let base_makeup = 28.0 L/s;
if sg_level < 8.5 m {
return base_makeup + (core_decay_kw / 1000.0 kW) * 0.65 L/s;
}
return base_makeup;
}
on change(twin::point<"class1e.div1.trip_load_latched">) every >= 50ms (fuel: 280) {
let div1_trip_latched = twin::point<"class1e.div1.trip_load_latched">.read();
let offsite_pu = twin::point<"offsite.4160v_bus_pu">.read();
let pzr_press = twin::point<"primary.pressuriser_pressure">.read();
let sg_level = twin::point<"secondary.sg1_narrow_level">.read();
let decay_kw = twin::point<"primary.core_decay_heat">.read();
// LOOP + turbine trip drives pressuriser pressure upward from 155 bar nominal:
// pressuriser spray actuates around 157 bar and PORVs lift around 161–162 bar.
if div1_trip_latched && offsite_pu < 0.72 && pzr_press > 157.0 bar {
let makeup_sp = required_condensate_makeup(decay_kw, sg_level);
twin::event::emit("nuclear.loop.pressure_surge_observed", pzr_press);
// Non-safety condensate makeup flow setpoint (distinct from Class 1E AFW)
let plan = guardrail::plan_mutation(
"supervisory.post_trip.condensate_makeup_flow_sp",
makeup_sp,
"Post-trip non-safety condensate makeup staging after Class 1E trip load latch"
);
if twin::shadow_qualify(plan, 180s) {
guardrail::apply(plan);
twin::event::emit("nuclear.loop.condensate_makeup_staged", "verified");
}
}
}
on tick(500ms) (fuel: 90) {
let hot_leg = twin::point<"primary.hot_leg_temp">.read();
let cold_leg = twin::point<"primary.cold_leg_temp">.read();
if (hot_leg - cold_leg) > 36.0 degC {
twin::event::emit("nuclear.primary.delta_t_guard", "alert");
}
}
}# Execute deterministic LOOP & Class 1E separation suite at 100x+ virtual fast-forward
twinctl test ./safety/pwr_loop_div1_div2.tws \
--twin ./pwr_unit1.twinproj \
--fault ./transients/loss_of_offsite_power_and_rcp_coastdown.twinspec \
--rate 100x \
--verify-bit-exact
[hil/virtual] 1x HIL parity hash == 100x virtual hash (0x9f4a21c8e7b0)
[separation] Class 1E Div I <-> Div II cross-bus fault injection: isolated
[margin] Pressuriser peak 161.2 bar <= 171.0 bar limit PASS
[dossier] Signed IEC 61513 / IEEE 603 / 10 CFR 50 App B bundle exportedClass 1E separation, ISA-101 operations, and protocol-coupled digital LOTO
Model physical and electrical separation between Class 1E Division I and Division II 4.16 kV buses, DC battery systems, and emergency diesel generators beside primary pressure and steam generator inventory equations—verifying single-failure tolerance before hardware benches are wired. In live control rooms, ISA-101 displays surface physics-residual deviations without alarm flooding while protocol-coupled digital LOTO enforces division-specific write-inhibit boundaries and four-eyes PE sign-off through the fail-closed mutation guardrail.
- IEC 61513
- IEEE 603
- IEEE 308
- 10 CFR 50 App B
- IEC 61131-3
- ISA-101
Safety classification, traceability, and assurance standards
| Standard or regulation | Qualification scope | TwinControl assurance mechanism |
|---|---|---|
| IEC 61513 & IEEE 603 | Nuclear safety I&C system architecture, defence-in-depth, and single-failure criteria | Verify deterministic 2oo4 safety actuation logic across independent Division I and Division II trains with bit-exact 1x HIL and 100x+ virtual parity. |
| IEEE 308 | Class 1E power systems, 4.16 kV safety buses, battery trains, and EDG load-sequencing | Simulate LOOP undervoltage shedding, EDG start/synchronisation, and step-load voltage dips against primary-loop heat removal. |
| 10 CFR 50 Appendix B | Quality assurance, configuration traceability, and independent verification and validation | Link every requirement, IEC 61131-3 function block, test waveform, and PE four-eyes approval into an immutable audit bundle. |
| Digital Tagout LOTO & ISA-101 | Division-isolated maintenance boundaries and main control room human factors | Enforce protocol-coupled write-inhibit locks per safety train alongside zero-rebuild ISA-101 operator displays. |

