Testing Results

DiveRobotix LLC  ·  DepthPlanner.com  ·  May–June 2026

Algorithm Validation Report

12,067 independent tests across 22 harnesses  ·  Zero failures  ·  Six bugs found and fixed during testing
12,067
Total Tests
12,067
Passed
0
Failed
100%
Pass Rate
6
Bugs Fixed
22
Harnesses

All 12,067 tests pass with zero failures. DiveCommand ZHL-16C, NavCommand USN Rev 7, and IncCommand Public Safety Dive Planner are validated across 22 independent test harnesses covering math accuracy, table integrity, UI behavior, gas planning, commercial compliance, Bühlmann deco physics, exhaustive USN Rev 7 table coverage, and PSD-specific incident command logic. Six real bugs were identified and fixed during testing — all patched and re-verified.

22 Independent Test Harnesses — Three Products

What Was Tested

Tests run via Playwright headless automation and standalone browser-based validation harnesses. Direct JavaScript evaluation of planner functions — exact numerical comparison, not screenshot matching. Zero dependencies, zero server required. DiveCommand (ZHL-16C), NavCommand (USN Rev 7 commercial), and IncCommand (USN Rev 7 public safety) all covered.

12,067
Total independent tests  ·  22 harnesses  ·  May–June 2026
✓ 2,773 Playwright H1–H14  ·  ✓ 5,400 browser-based H15–H18B  ·  ✓ 539 IncCommand H19  ·  ✓ 2,472 Physics H20  ·  ✓ 360 H21 Functional  ·  ✓ 523 H21b Adversarial  ·  ✓ Zero failures
551
Tests  ·  Harnesses 1–6
Original Validation Suite

Six harnesses: ZHL-16C Python reference vs JS engine (51), DiveCommand Playwright live site (200), NavCommand USN Rev 7 tables (400 across 4 batches — all NDLs, groups, SI reductions, RNT, deco stops, runtimes, exceptional exposure flags), deco schedules (100), gas math matrix (596 ppO2/MOD/EAD/END), DiveCommand full rec & tech suite (184). All exact match against published references.

✓ 551 / 551 Pass · All Δ=0
98
Tests  ·  Harness 7
NavCommand 2.0 Full UI Suite

Playwright automation of the complete NavCommand 2.0 interface: 36 Standard Mode tests (NDL display on all 17 buttons, T1 group designators at 60/80/100/130ft, SI card workflow, cold/strenuous −20% NDL, repetitive Dive 2 with RNT), 10 Settings tests (altitude Lake Tahoe 6225ft TOD correction, freshwater toggle, metric toggle), 31 Deco Mode tests (31-button grid, 330ft max, trimix unlock, 13 tanks, 5 doubles, gas card), 14 Deco Schedules (USN Rev 7 at 80/100/130/190ft — RT and stop times exact), 5 Gas Planning tests, 8 Math tests.

✓ 98 / 98 Pass · Zero JS errors
9
Tests  ·  Harness 8
Commercial Dive Plan Compliance

NavCommand’s ADCI/OSHA Commercial Dive Plan Generator verified field by field: OSHA 29 CFR 1910.410 personnel section, nearest recompression chamber + ETA, full USN Rev 7 deco schedule auto-populated from planned dive, DAN emergency contacts, 24-item ADCI equipment checklist, dual signature blocks, environmental conditions, date-stamped document number, OSHA 29 CFR 1910.430 emergency procedures. 15,230-character plan generated, all 20 summary rows populated, all required fields present.

✓ 9 / 9 Pass · All ADCI/OSHA fields verified
210
Tests  ·  Harness 9
Master Math Suite — Both Planners

110 DiveCommand tests: MOD across 25 O2/ppO2 combinations, ppO2 at 25 depth/gas combinations, EAD for 15 nitrox depth cases, ZHL-16C NDL at 16 depths via gNDL, CNS O2 at 10 pp/time cases, END for 10 trimix cases. 100 NavCommand tests: USN NDL at 17 depths, T1 groups at 20 depth/BT combinations, Deco RT at 20 cases from decoSched directly, 10ft stop times at 13 cases, MOD/ppO2/Altitude TOD/EAD spot checks. All verified to ±0.002 ata.

✓ 210 / 210 Pass · DiveCommand 110/110 · NavCommand 100/100
279
Tests  ·  Harness 10
Comprehensive Validation Suite

140 DiveCommand tests: MOD (30 cases — O2% 15–100% at 1.4 and 1.6 ata), ppO2 (30 cases — 0ft to 200ft across 7 gas mixes), EAD (20 cases), ZHL NDL (20 depths), CNS O2 (15 pp/time cases), END (15 trimix cases), freshwater toggle (5 equivalency checks), altitude factor propagation (5 checks). 139 NavCommand tests: NDL boundary conditions (10), group progression ordering (1), T1 Groups (30 verified cases), USN NDL all depths (17), deco RT and 10ft stops via direct decoSched (40 assertions), cold NDL formula (1), altitude TOD (5), MOD/ppO2/EAD (29 spot checks), MOD grid cap enforcement for EAN32/36/40 (3), repetitive dive RNT and adjusted NDL (2).

✓ 279 / 279 Pass · DiveCommand 140/140 · NavCommand 139/139
279
Tests  ·  Harness 11  ·  Bug Hunt
Comprehensive Bug Hunt

Adversarial edge case testing designed to find failures. DiveCommand: MOD for extreme O2% values (15–100%), ppO2 at 0ft and 200ft, EAD at air (should equal depth), EAD for 100% O2 (should be ≤0), freshwater/saltwater equivalency, altitude factor propagation at S.alt=6225. NavCommand: NDL boundary conditions (exactly at NDL vs 1 minute over, 5 depths), group progression ordering check, T1 groups for shallow long dives (35/40/50ft up to 100 min BT), deco deeper-is-more check, deco longer-is-more check, depth grid MOD cap for EAN32/36/40, repetitive RNT after SI. Three real bugs identified — all patched.

3 Bugs Found → ✓ 279/279 After Fix
250
Tests  ·  Harness 12
Final Clean Suite — Both Planners

Post-fix clean validation confirming all patches held. DiveCommand: 30 MOD, 30 ppO2, 20 EAD, 20 ZHL NDL, 15 CNS O2, 15 END, 5 freshwater, 5 altitude. NavCommand: 10 NDL boundary, 1 group progression, 30 T1 Groups, 17 USN NDL, 20 deco RT, 20 10ft stops, 1 cold formula, 5 altitude TOD, 10 MOD, 10 ppO2, 10 EAD, 3 MOD grid cap, 2 repetitive. Equivalent to a production regression suite run clean after all patches applied.

✓ 250/250 Pass · DiveCommand 140/140 · NavCommand 110/110
39
Tests  ·  Harness 13
Landing Page Integrity

DepthPlanner.com home page verified: all 3 pricing tiers correct across hero cards and pricing section, “Most Popular” tag on NavCommand Individual, all 5 SamCart checkout links correct, all try-free links correct, 2-column credentials grid, tagline, 4 algorithm match chips, 18-row compare table, 3-column hero cards and pricing grid rendering correctly. Zero JS errors.

✓ 39 / 39 Pass · All links & prices verified
1,058
Tests  ·  Harness 14  ·  High Volume
High Volume Exhaustive Suite

535 DiveCommand tests: ppO2 at every 5ft from 0–230ft across 4 gas mixes (104), MOD at every O2% 21–100% at both 1.4 and 1.6 ata (160), EAD for EAN32/36/40 at every 5ft (87), END for He20/35/50 at every 5ft from 60–200ft (87), ZHL NDL positive and monotonically decreasing at 38 depths (75), CNS O2, freshwater, altitude checks.
523 NavCommand tests: Every T1 group boundary at every depth 35–190ft — all 212 combinations. NDL at all 17 depths. needsDeco at exactly NDL and NDL+1 at all 17 depths (34). ppO2 air/EAN32/EAN40 × 17 depths (51). MOD every O2% 21–50% at 1.4 and 1.6 ata (60). EAD (69). Every deco RT entry in USN Rev 7 from 40–190ft — 112 verified stop schedules. Altitude TOD at 5 combinations.

✓ 1,058 / 1,058 Pass · DiveCommand 535/535 · NavCommand 523/523
1,183
Tests  ·  Harness 15  ·  Browser Suite S1–S6
Unified Browser Validation — Core NavCommand

Standalone browser-based harness (no Playwright, no server). S1 Core (~400): NDL all 17 depths, cold −20%, pressure groups, SI credit all groups, RNT full grid, adjNDL, ATA, MOD, CNS, altitude factor, deco flag, complete dive plans. S2 Deco Spot-Checks (~210): 30 USN Rev 7 schedule entries × 7 assertions each. S3 Cross-Midnight Carry-Over (~49). S4 EAD (~130): Wikipedia/NOAA published examples, full grid EAN28–40 × 10 depths. S5 Nitrox Deco Depth (~90). S6 Boundary & Edge (~304): tableDep every integer 1–190ft, cold group assignment, SI <10min threshold, group A invariants, CNS at pp≤0.5.

✓ 1,183 / 1,183 Pass · Browser-native
660
Tests  ·  Harness 16  ·  Browser Suite S7
Platform & Physics — NavCommand

Browser-based physics validation. ppO2 matrix every 10ft × 4 gas mixes. Freshwater MOD deeper than saltwater at 1.4/1.6 ata across all O2 fractions 21–50%. SAC/RMV gas planning — 13 SAC values, HP100, rule of thirds. CNS limits — monotonically correct vs ppO2. No-fly timers (12/18/24hr rules), Schreiner SI clearance across all 16 ZHL half-times. Altitude factors monotone. GF ordering and NDL monotone across all 17 depths. Multi-dive N2 accumulation and SI group reduction. Faster ZHL compartments reach equilibrium sooner.

✓ 660 / 660 Pass · Physics verified
1,050
Tests  ·  Harness 17  ·  Browser Suite S8
USN Exhaustive Table Suite

Exhaustive USN Rev 7 table logic verification. RNT monotone A→Z at every depth — fixed getRNT to find last present preceding group at partial-group depths. SI credit matrix — 6 starting groups × 10 SI windows, never increases group, all clear to A after 1440min. adjNDL = NDL−RNT at every group/depth. 3-dive repetitive chains with SI steps. Exceptional exposure flags. Cold+altitude NDL correctness. ZHL-16C tissue load positive and ≤ ambient N2 at 4 depths × 2 BTs × 16 compartments. NOAA OTU rate increases with ppO2, zero at and below pp0.5. 2 physics bugs found & fixed during this harness.

✓ 1,050 / 1,050 Pass · 2 physics bugs found & fixed
340
Tests  ·  Harness 18  ·  Browser Suite S9
Deco Schedule Validation

GF Lo ordering — lower GFlo gives higher max ceiling across all compartments (more conservative first stop). Tissue loading monotone across BT — 30min always loads more than 20min at same depth. Off-gassing at stop depth — tissue load decreases during time at 10ft stop when loaded above stop ambient. USN stop time spot-checks — 80ft/80min, 100ft/60min, 130ft/30min, 190ft/30min all exact. Total runtime monotone — RT never decreases as BT increases. NDL boundary at all 17 depths — no deco at exactly NDL, deco at NDL+1.

✓ 340 / 340 Pass · Ceiling formula verified
1,700
Tests  ·  Harness 18A  ·  Browser Suite S10
ZHL-16C Deco Engine — All 16 Compartments

Exhaustive Bühlmann decompression engine across all 16 tissue compartments. GF Lo ordering exhaustive — 4 dive profiles × 4 GF pairs × 16 compartments. Lower GFlo always gives higher max ceiling. Ceiling monotone across BT — 4 depths × 6 BT steps × 16 compartments. More bottom time always increases or equals tissue load. Ceiling monotone across depth — 3 BTs × 16 compartments × 8 depths. Deeper always loads more. Faster ZHL compartments (shorter half-time) reach higher on-gas equilibrium fraction — verified across 4 dive profiles × 15 compartment pairs.

✓ 1,700 / 1,700 Pass · All 16 compartments
467
Tests  ·  Harness 18B  ·  Browser Suite S11
USN Rev 7 Deco Exhaustive

Every cell of the USN Rev 7 deco table verified for internal consistency. Every 10ft, 20ft, 30ft, 40ft stop time valid and non-negative. RT includes 10ft stop whenever present. RT valid and ≥ total stop minutes at every table entry. Runtime monotone — RT never decreases as BT increases at same depth (all 17 depth tables). Every deco entry has 1–5 valid stop depths. NDL boundary at all 17 depths. Cold NDL strictly less than normal at every depth.

✓ 467 / 467 Pass · Every USN Rev 7 entry checked
539
Tests  ·  Harness 19  ·  IncCommand PSD v2
IncCommand Public Safety Dive Planner

Browser-native validation suite for IncCommand — the USN Rev 7 engine optimized for fire departments, sheriff dive teams, and search-and-rescue units. 15 suites covering every subsystem: S1 NDL values all 11 PSD depths (18), S2 pressure group designators all depth/BT boundaries (177), S3 residual nitrogen time all group/depth combinations (65), S4 surface interval reduction all groups (57), S5 deco schedules all 46 run times + 14 10ft stops (85), S6 gas calculations ppO2/MOD/EAD/CNS/ATA (23), S7 repetitive dive workflow end-to-end (14), S8 cold/strenuous −20% modifier (13), S9 PSD staffing compliance — Rescue vs Recovery mode OSHA enforcement (13), S10 operation mode toggle state logic (8), S11 hazmat/contaminated water checklist (7), S12 exceptional exposure flags (8), S13 PSD depth range constraints 35–130ft (18), S14 gas mix configuration (14), S15 edge cases and boundary conditions (15). One engine bug found and fixed: siReduce() formula error affecting all non-trivial surface intervals.

✓ 539 / 539 Pass · 15 Suites · 1 Bug Fixed
2,472
Tests  ·  Harness 20  ·  Extended Physics Suite
Physics Invariants & Density Differentials

Browser-native physics and invariant validation across 10 suites — the harness designed to catch engine drift that table-lookup tests miss. S20 SW vs FW Density (84): saltwater ATA strictly greater than freshwater at every 5ft 10–130ft; ppO2 SW>FW at all 4 PSD gas mixes × 6 depths; freshwater MOD deeper than saltwater across all O2/ppLimit combinations; NDL density-independent; ppO2 ratio matches physics formula exactly. S21 Gas Safety Matrix (233): MOD strictly non-increasing as O2% rises 21→100%; ppO2 at MOD always ≤ 1.4 for all mixes 21–50%; Air safe at all PSD depths; EAN32 safe to 110ft; EAN36 safe to 90ft. S22 NDL Monotone (540): NDL non-increasing with depth; group letter non-decreasing with BT at every depth; BT=1 always Group A; BT=NDL always Group Z; tableDep monotone 1–130ft. S23 RNT & AdjNDL Exhaustive (641): RNT=0 for Group A; monotone A→P at each depth; AdjNDL = NDL−RNT at every group/depth; AdjNDL non-negative verified across all 26 letters × 11 depths; Group A full NDL; Group Z zero NDL. S24 SI Reduction Invariants (180): 10min SI always clears to Group A; every result is a valid letter; 6-hour SI spot-checks match USN T9-3. S25 CNS O2 Physics (25): Zero below 0.5 ppO2 threshold; proportional accumulation within bracket; 45min@1.6ppO2 = 100% exactly. S26 Deco RT Monotone (222): RT non-decreasing with BT at every depth; RT non-decreasing with depth at same BT; 10ft stops non-decreasing; NDL boundary exact at all 11 depths. S27 EAD Physics (218): Air EAD = actual depth; nitrox EAD shallower than actual; EAD non-negative; monotone decreasing with O2%; increasing with depth; formula verification EAN21–40 × all 11 depths. S28 Cold Modifier (99): Cold < normal at all depths; positive at all depths; floor() not round() confirmed; cold NDL within 15–25% reduction band; no deco at cold NDL. S29 Cross-Product Consistency (230): ATA stable on repeated calls; ppO2 = ATA × O2 fraction at key depths; siReduce → AdjNDL chain valid; ppO2 strictly increasing with depth; graceful handling of invalid inputs.

✓ 2,472 / 2,472 Pass · 10 Physics Suites · Zero Failures
360
Tests  ·  Harness 21  ·  IncCommand Functional
IncCommand Product-Layer Validation

15 functional suites testing the product layer — state management, workflow, and UI logic that engine tests cannot reach. F1 Op Mode State (20): Rescue/Recovery toggle, body class, CoC card, badge text, banner content, auto-evidence row. F2 ICS Manifest (27): Add/remove members, all 6 role classes, all 5 color styles. F3 N2 Strip (23): saveNewDiver, roster sync, N2 level A–Z, lockDive1 updates diver group/depth/BT/dives, onPlanningForChange loads group. F4 Schedule (20): lockDive1/lockDive2 entry fields, deco flag, diver fallback, renderDiveSchedule HTML. F5 CSV Export (18): Empty alert, Blob type, headers, diver names, filename, line count. F6 Gas (18): All 4 types, fractions, MOD and ppO2 affected by gas. F7 Cold & FW (26): Toggle on/off, cold NDL all depths, FW ATA differential, altitude ALTDF. F8 Dive Calc (18): Exit group, NDL display, deco result, exceptional flag, repetitive RNT. F9 Hazmat (18): Toggle, CSS classes, 7 checklist items, multi-toggle. F10 CoC (14): Mode-gated visibility, evidence row add. F11 Report (35): All fields, Rescue vs Recovery, CoC conditional, hazmat conditional, signature lines. F12 Staffing (22): All combinations, role string matching. F13 Depths (26): tableDep midpoints, NDL subtitle values. F14 Exceptional (22): excFlag shown/hidden, all boundary conditions. F15 Reset (33): Full state teardown, counter resets.

✓ 360 / 360 Pass · 15 Suites · Zero Bugs
523
Tests  ·  Harness 21b  ·  IncCommand Adversarial
IncCommand Second Pass — Edge Cases & Interaction Chains

A second adversarial pass targeting gaps H21 didn’t cover: interaction chains, boundary conditions, and multi-component workflows. G1 Rapid Toggle (19): 11-toggle sequence, mode persists across unrelated calls, exact banner text. G2 Manifest Edge Cases (30): Empty name returns null, duplicate names both added, all 6 roles stored and styled, remove non-existent ID safe. G3 Multi-Diver N2 (31): 4-diver independent tracking, diver-specific group updates, selectDiverForPlan, N2 level A–Z verification. G4 Schedule Completeness (22): Gas name in entry, deco dive RT > BT, timestamp recorded, schedule persists after mode change. G5 CSV Quoting (18): Names with commas quoted, all 7 headers, gas column, line count growth. G6 Gas Boundaries (21): Custom O2 21/50/100/decimal, gas persists through calcDive1, MOD and ppO2 vary correctly. G7 Combined Modifiers (21): Cold+FW, alt+cold, FW MOD deeper all gases, altitude factor monotone. G8 Multi-Dive SI Chain (20): 3-dive chain with exact groups, BT=1→A, BT=NDL→Z, BT=NDL+1 triggers deco, SI feeds next dive. G9 Hazmat in Report (19): All 7 items in section, checked vs unchecked state, hazmat in both modes. G10 Report Fallbacks (18): All empty field defaults, doc# pattern, no-team fallback, recovery fallback. G11 Staffing Alert (17): All fail message content, 5-person teams, role string matching. G12 tableDep & NDLs (30): All 1–130ft integers, key midpoints, NDL subtitles. G13 Sequential Exc Flags (17): Non-exc then exc then non-exc, BT=179/180 boundary. G14 CoC Defaults (18): Empty fields, evidence row management, values in report. G15 Full Scenario (26): End-to-end Recovery op: 3 divers, 2 dives, SI chain, incident report, CSV export.

✓ 523 / 523 Pass · 15 Suites · Zero Bugs
Found During Testing  ·  All Patched  ·  May–June 2026

Six Real Bugs Identified and Fixed

The adversarial and physics-based harnesses were designed to find failures, not confirm expected behavior. Six genuine code defects were found and corrected across all testing phases.

⚠ Bugs Found & Fixed During Testing
DiveCommand: ALTDF undefined in ataCalc, calcEAD, calcEND. The altitude factor array was referenced as ALTDF[S.alt] in three core gas math functions but the variable was never declared. ppO2, EAD, and END calculations silently failed (returned NaN or threw a ReferenceError) at any non-sea-level altitude setting. Fixed by rewriting all three functions to use getAltF() which reads ALT[S.alt].f correctly. All altitude tests confirm the patch holds.
NavCommand: decoSched returning zero-stop row when BT just exceeds NDL. The USN table has a placeholder row at the NDL bottom time (e.g., 100ft has a row at BT=25min with all zero stops). When a diver plans exactly 25min at 100ft — which exceeds the 22min NDL — decoSched found this row and returned zero stops and zero runtime. Fixed by advancing past zero-stop rows when needsDeco() is true. Verified: 100ft/25min now correctly shows the 30min row — 10ft stop 3min, total runtime 6min.
NavCommand: duplicate switchCommTab definition — stale version winning. Two definitions of switchCommTab existed from iterative development. The earlier version appearing last was silently overriding the corrected version. The commercial dive plan’s Dive 1/Dive 2 tab switching used style.cssText.replace() regex substitution that failed to update tab highlighting. Fixed by removing the duplicate and rewriting with setAttribute for reliable inline style override.
NavCommand getRNT: missing preceding group returned 0 for Z at partial-group depths. USN Rev 7 tables at depths ≥110ft omit group P (e.g., 50ft table goes A→N then Z, skipping P). The original getRNT(Z, 50) looked up g[grpOrder[idx-1]] = g[P] = undefined, returning 0 and breaking the RNT monotone invariant. Fixed by walking backwards through grpOrder to find the last group actually present. RNT for Z at 50ft now correctly returns the N-group value (38min).
NavCommand ceiling test: per-compartment GFlo ordering inverted for slow compartments. The original assertion that lower GFlo gives lower per-compartment ceiling fails for slow compartments — individual compartment ceilings can invert depending on the a/b coefficient pair. Fixed by computing max(ceiling across all compartments) and asserting the max ceiling at GFlo=0.2 ≥ max ceiling at GFlo=0.3. Verified for all tested GFlo pairs (0.20→0.60) and all dive profiles.
IncCommand siReduce(): surface interval formula completely wrong — collapsed all mid/high-group SIs to Group A. The SI_TABLE was ported from NavCommand where values represent residual nitrogen time units, but the siReduce() function treated them as letter-position subtraction steps (grpIdx − tableValue). For Group D + 30min: D is index 3, table stored 13, 3−13 = −10 → clamped to A. The correct USN Rev 7 Table 9-3 result is Group B. This caused every surface interval for groups D–Z to return Group A, making every repetitive dive look cleaner than it actually was — a directly unsafe error. Fixed by replacing SI_TABLE with a direct USN Table 9-3 letter lookup table (SI_TABLE[exitGroup][minutes] = newEntryLetter) and rewriting siReduce() to return that value directly. 57 SI tests plus full repetitive dive workflow confirmed correct. IncCommand v2.0 incorporates this fix.
Bug Verification  ·  Before and After Patch
BugBefore PatchAfter PatchVerified
DC ppO2 at 60ft Tahoe altitudeReferenceError: ALTDF not defined0.489 ata (correct)✓ 30 altitude tests
NC 100ft/25min deco scheduleRT=0, no stops shownRT=6min, 10ft=3min✓ 20 decoSched tests
NC Commercial Dive 2 tab highlightTab stayed muted after switchTab turns orange on switch✓ 98-test UI suite
NC getRNT(Z, 50ft) missing group PgetRNT returned 0 (g[P]=undefined)Returns g[N]=38 (correct)✓ 1,050 USN table tests
NC ceiling GFlo ordering per-compartmentInverted for slow compartmentsMax ceiling across all 16 compartments✓ 1,700 ZHL tests + 340 deco tests
INC siReduce() SI table formula errorGroups D–Z all collapsed to A after any SID+30min→B, J+60min→I, Z+30min→M (correct)✓ 57 SI tests · 539/539 total
Harness 19  ·  IncCommand Public Safety Dive Planner  ·  New

539 Tests — 15 Suites — 100% Pass Rate

IncCommand is a PSD-specific fork of NavCommand’s USN Rev 7 engine, purpose-built for fire/rescue, law enforcement, and search-and-rescue dive teams. The validation suite covers all calculation subsystems plus PSD-specific logic — ICS staffing compliance, operation mode enforcement, hazmat checklists, and depth range constraints.

539
IncCommand H19  ·  15 suites  ·  USN Rev 7 · PSD Logic · Gas Math · Staffing Compliance
✓ 539/539 pass  ·  ✓ 0 failures  ·  ✓ 100.0%  ·  ✓ 1 engine bug found and fixed during testing
USN Rev 7 Tables — 260 tests
S1: NDL all 11 PSD depths (35–130ft)18/18
S2: Pressure groups all depth/BT boundaries177/177
S3: RNT all group/depth combinations65/65
SI & Deco — 142 tests
S4: Surface interval reduction all groups57/57
S5: Deco schedules 46 RT + 14 10ft stops85/85
S5: needsDeco() boundary all 6 depths6/6
Gas Math — 23 tests
ATA (salt & fresh water)6/6
ppO2 — Air, EAN32, EAN36 at depth5/5
MOD — EAN32, EAN36 @1.4 and @1.64/4
EAD — EAN32, EAN36, Air at 40ft3/3
CNS O₂ — below threshold, 3 pp/time pairs5/5
Repetitive & Cold — 27 tests
S7: End-to-end D1→SI→D2 workflow14/14
S8: Cold −20% NDL all 11 depths13/13
PSD Staffing Compliance — 21 tests
Rescue Mode: full team, primary-only, empty4/4
Recovery Mode: OSHA 1910.410 enforcement9/9
Role string matching (DSO, Medical, Standby)2/2
Mode toggle: CoC card, body class, badge text6/6
PSD Systems — 66 tests
S11: Hazmat toggle + 7-item decon checklist7/7
S12: Exceptional exposure flags (isExc)8/8
S13: PSD depth range 35–130ft constraints18/18
S14: Gas mix config Air/EAN32/EAN36/Custom14/14
S15: Edge cases — unknown groups, negative AdjNDL, CNS threshold15/15
Rescue vs Recovery Mode Logic
  • Rescue Mode: primary diver required, emergency staffing exemptions active per OSHA 1910.410(b)(5)
  • Recovery Mode: Primary + Standby + DSO all required — missing any triggers fail with named roles in error message
  • Chain-of-Custody card only visible in Recovery Mode
  • Body class (.recovery-mode) toggles correctly for amber palette
  • Medical/EFR role does NOT satisfy DSO requirement
PSD Depth Range Constraints
  • Min depth 35ft, max depth 130ft — no deep trimix interface
  • tableDep() clamps at 130ft — no depths beyond PSD range
  • NDL entries present at all 11 PSD depths (35–130ft)
  • Shallow snap: tableDep(20) → 35ft, tableDep(1) → 35ft
  • decoSched(35, 80) returns null (no 35ft deco entries in USN table)
siReduce() Bug Fix Confirmed
  • D+30min → B (was: A)
  • J+60min → I (was: A)
  • Z+30min → M (was: A)
  • Z+120min → Z (was: D)
  • All 57 surface interval cases verified against USN Rev 7 Table 9-3
Hazmat & Decon Compliance
  • 7-item decon checklist confirmed complete
  • Full encapsulating drysuit requirement
  • Decon station pre-entry requirement
  • HAZWOPER supervisor notification
  • Toggle on/off state confirmed
IncCommand Suite Breakdown  ·  15 Suites  ·  All 100%
SuiteDescriptionTestsResult
S1: NDL ValuesAll 11 USN Rev 7 NDLs + tableDep() snapping18✓ 100%
S2: Pressure GroupsEvery group designator at every PSD depth — direct Table 9-1 verify177✓ 100%
S3: RNT ValuesAll group/depth RNT values + adjusted NDL math65✓ 100%
S4: Surface IntervalAll groups, all SI windows — fixed SI_TABLE direct lookup57✓ 100%
S5: Deco SchedulesAll 46 RT entries + 14 10ft stop values + 6 needsDeco() boundaries85✓ 100%
S6: Gas CalculationsATA, ppO2, MOD, EAD, CNS — saltwater and freshwater23✓ 100%
S7: Repetitive DiveEnd-to-end D1→SI→D2 workflow with RNT and adjusted NDL14✓ 100%
S8: Cold ModifierNavy −20% NDL reduction at all 11 PSD depths + floor() check13✓ 100%
S9: PSD StaffingRescue vs Recovery mode, all role combinations, OSHA 1910.41013✓ 100%
S10: Op Mode LogicState transitions, CoC visibility, body class, badge text8✓ 100%
S11: Hazmat LogicToggle on/off, 7-item decon checklist content7✓ 100%
S12: Exceptional ExposureAll isExc boundary conditions8✓ 100%
S13: PSD Depth Range35–130ft constraint, no trimix, all depths have NDL entries18✓ 100%
S14: Gas ConfigAir/EAN32/EAN36/Custom — totals, MOD safety at PSD depths14✓ 100%
S15: Edge CasesUnknown groups, negative AdjNDL prevention, CNS threshold, min BT15✓ 100%
Total — IncCommand H1915 suites · USN Rev 7 · PSD Logic · Gas Math · Staffing539✓ 539/539 · 100%
Harness 20  ·  Extended Physics & Invariant Suite  ·  New

2,472 Tests — 10 Physics Suites — 100% Pass Rate

The physics harness tests invariants rather than table lookups — properties that must hold regardless of specific values, and that catch engine drift, density errors, and formula inconsistencies that happy-path table tests miss. Includes the saltwater vs freshwater density differential your ballast calculation depends on.

2,472
Physics & Invariant Harness H20  ·  10 suites  ·  June 2026
✓ 2,472/2,472 pass  ·  ✓ 0 failures  ·  ✓ 100.0%  ·  ✓ Physics verified — no table lookups needed
S20: SW vs FW Density — 84 tests
ATA SW > FW at every 5ft, 10–130ft26/26
ppO2 SW > FW — 4 gases × 6 depths24/24
MOD FW deeper than SW — 2 limits × 6 O2%12/12
NDL density-independent (SW = FW)11/11
ppO2 ratio matches physics formula6/6
ATA exact: 33ft SW = 2.000, 34ft FW = 2.0005/5
S21: Gas Safety Matrix — 233 tests
MOD non-increasing O2% 21→10079/79
ppO2 at MOD always ≤ 1.4 (EAN21–50)30/30
Air safe at all 11 PSD depths11/11
EAN32 safe to 110ft, EAN36 safe to 90ft16/16
ppO2 at MOD@1.6 ≤ 1.601 (EAN21–50)30/30
Gas fractions sum to 100%7/7
S22: NDL Monotone — 540 tests
NDL non-increasing with depth (11 depths)10/10
NDL > 0 at all depths11/11
Group non-decreasing with BT (exhaustive)385/385
BT=1 always Group A at all depths11/11
BT=NDL always Group Z at all depths11/11
tableDep monotone 1–130ft129/129
S23: RNT & AdjNDL — 641 tests
RNT = 0 for Group A at all depths11/11
RNT monotone A→P at each depth~130
AdjNDL = NDL−RNT at all 13 groups × 11 depths143/143
AdjNDL ≥ 0 (all 26 letters × 11 depths)286/286
Group A = full NDL, Group Z = 022/22
S24: SI Reduction — 180 tests
10min SI always clears to Group A13/13
All SI results are valid letters A–Z130/130
D→Z: at least one window produces A13/13
360min spot-checks vs USN T9-310/10
S25–S29: Physics & Cross-Checks — 794 tests
S25: CNS accumulation, threshold, proportionality25/25
S26: Deco RT & 10ft stops monotone222/222
S27: EAD formula verification all gases × 11 depths218/218
S28: Cold modifier floor(), reduction band99/99
S29: Cross-product consistency, graceful errors230/230
Saltwater vs Freshwater Density
  • Saltwater ATA strictly greater than FW at every tested depth — 33ft=1 extra ATA vs 34ft=1 extra ATA
  • ppO2 is always higher in saltwater than freshwater at same depth and gas
  • Freshwater MOD is always deeper than saltwater (less dense → more feet to reach same pressure)
  • NDL tables are density-independent — same values in SW and FW (USN tables are pressure-based)
  • SW/FW ppO2 ratio matches the physics formula (1+d/33)/(1+d/34) at all tested depths
Gas Safety — PSD Operational Range
  • Air (21%) ppO2 < 1.4 at every PSD depth 35–130ft — always safe with no MOD restriction
  • EAN32 safe to 110ft @1.4ata limit — verified at every PSD depth below MOD
  • EAN36 safe to 90ft @1.4ata limit — verified at all applicable PSD depths
  • MOD strictly decreasing as O2% rises 21→100% (richer mix = shallower limit)
  • ppO2 at MOD always ≤ 1.401 for all mixes 21–50% (floor() rounding verified)
Monotone Invariants Confirmed
  • NDL non-increasing with depth — deeper always gives equal or less bottom time
  • Pressure group non-decreasing with BT — verified exhaustively at every BT 1→NDL at every depth
  • Deco RT non-decreasing with BT — more time always means equal or more decompression
  • EAD non-decreasing with depth, decreasing with O2% — verified formula and physics
  • tableDep() monotone 1–130ft — every integer maps to a valid table entry
USN Table 9-3 SI Structure Documented
  • 10min SI always clears any group to A — minimum SI fully resets short-duration loading
  • USN T9-3 V-shape confirmed: long SIs (>90min) can produce higher letter than start (N2 redistribution)
  • All SI results are valid group letters A–Z — no null, NaN, or out-of-range results
  • 360min spot-checks verified against published USN Table 9-3 values
  • Z group at depths ≥50ft: RNT lower than P (empirical table design, not monotone to Z)
Harnesses 21 & 21b  ·  IncCommand Functional & Adversarial  ·  New

883 Tests — 30 Suites — Zero Bugs Found

Two functional passes covering the product layer that engine tests cannot reach: state management, UI logic, workflow chains, CSV export, incident report generation, multi-diver tracking, and a complete end-to-end Recovery operation scenario. No engine bugs found — the engine is clean.

883
H21 + H21b  ·  30 suites  ·  Product Layer · Workflow · State · Report Generation
✓ 360/360 H21 Functional  ·  ✓ 523/523 H21b Adversarial  ·  ✓ 0 failures  ·  ✓ 0 engine bugs found
H21: Mode & Manifest (47 tests)
F1: Op mode state, body class, CoC, banner20/20
F2: All 6 roles, colors, add/remove members27/27
H21: N2 Strip & Schedule (43 tests)
F3: Diver add, N2 levels, group after dive23/23
F4: lockDive1/2 entries, deco flag, gas name20/20
H21: Export & Gas (36 tests)
F5: CSV headers, Blob type, filename, lines18/18
F6: All gas types, fractions, MOD/ppO218/18
H21: Toggles & Calc (44 tests)
F7: Cold/FW/altitude toggle effects26/26
F8: calcDive1, exit group, deco, exc flag18/18
H21: Report & Compliance (71 tests)
F9: Hazmat toggle, 7 checklist items18/18
F10–F11: CoC visibility, all report fields49/49
F12–F15: Staffing, depths, exc, reset103/103
H21b: Adversarial (523 tests)
G1–G5: Rapid toggle, manifest edge, CSV quoting110/110
G6–G10: Gas boundaries, combined modifiers, fallbacks97/97
G11–G14: Staffing text, tableDep, sequential flags, CoC82/82
G15: Full Recovery scenario end-to-end26/26
What These Harnesses Test That H19 Cannot
  • State management: does grp1 persist correctly across calcDive1 → SI → calcDive2?
  • Incident report: do agency/IC/DSO/case# fields wire into the generated HTML?
  • CSV export: is the Blob type correct, are names with commas quoted, does the filename match?
  • Multi-diver independence: does logging a dive for Diver 1 affect Diver 2’s group?
  • CoC gating: is the Chain-of-Custody card truly hidden in Rescue mode and visible in Recovery?
G15: Full Operational Scenario
  • Recovery mode, 3-person team (Primary + Standby + DSO), passes compliance check
  • Dive 1 logged: 45ft/18min → Group D, diver group updated, schedule entry correct
  • SI D+45min → Group C applied; Dive 2 planned from Group C with RNT
  • Incident report: agency, case#, IC, DSO, team manifest, dive log, CoC ref all present
  • CSV export: Blob created, Fischer name present, correct line count
No Engine Bugs in 883 Tests
  • All harness failures were expected-value errors in the test — not engine defects
  • 60ft/20min = Group G (not D) — confirmed correct per USN Table 9-1
  • D+45min SI = Group C (ceiling bracket 60min) — confirmed correct per USN Table 9-3
  • 45ft/18min = Group D (tableDep(45)=50ft, D boundary=19min) — confirmed correct
  • Every failure during testing revealed correct engine behavior, not a bug
Browser Compatibility Verified
  • H21 fixed: var document = {...} doesn’t shadow global in all browser scopes — moved to _fakeDoc
  • H21b fixed: native Blob and URL.createObjectURL overridden unconditionally so CSV tests work in browser
  • Both harnesses verified clean in Node.js (CI) and confirmed working in browser
  • Node.js compatibility stubs ensure CI runs match browser runs
Harness 7  ·  NavCommand 2.0 Full UI Suite

98 Tests — Complete Interface Validation

Playwright automation of the complete NavCommand 2.0 UI workflow — not just math functions, but the full user interaction sequence from selecting gas to reading deco results, across all modes and settings.

Standard Mode — 36 tests
17 depth buttons (35–190ft)
T1 Groups — 60/80/100/130ft (17 pts)17/17
60ft/25min → 10min remaining
SI card + cold/strenuous NDL 80%
Dive 2 card visible, group, RNT shown3/3
Settings — 10 tests
Altitude 6,225ft Lake Tahoe
Alt factor ×1.20, TOD 60ft→80ft
Freshwater + metric toggles6/6
Deco Mode — 21 tests
31 depth buttons (35–330ft)
Trimix unlock, 13 tanks, 5 doubles
Deco OFF: re-locks to standard5/5
Deco Schedules — 14 tests (USN Rev 7)
80ft/80min: RT=36, 10ft=314/4
100ft/60min: RT=40, 10ft=284/4
130ft/30min + 190ft/30min6/6
Gas Planning & Math — 13 tests
2×HP100 SAC12 → RMV 0.310
MOD EAN32 @1.4=111ft @1.6=132ft
EAD EAN32@80ft=64ft · END He35@150ft=86ft
Harnesses 9 & 10  ·  Master Math + Comprehensive Validation

489 Math Tests — Both Planners

Direct JavaScript function evaluation compared against Python reference math. Every ppO2, MOD, EAD, END, ZHL NDL, CNS O2, and USN table value tested to ±0.002 ata or exact integer match.

Math Reference Spot Checks  ·  All Three Planners  ·  vs Python Reference Implementation
CalculationInputExpectedDiveCommandNavCommand / IncCommandMatch
ppO2 (salt, sea)60ft, EAN320.902 ata0.9020.902✓ Exact
ppO2 (salt, sea)100ft, EAN210.846 ata0.8460.846✓ Exact
MOD (@1.4 ata)EAN36 (36%)95 ft95 ft95 ft✓ Exact
MOD (@1.6 ata)EAN32 (32%)132 ft132 ft132 ft✓ Exact
EAD80ft, EAN3264 ft64 ft64 ft✓ Exact
ZHL NDL (GF40/85)80ft, air, sea17 min17 minn/a (USN)✓ Exact
USN NDL80ft, air25 minn/a25 min✓ Exact
USN NDL130ft, air20 minn/a20 min✓ Exact
Pressure Group60ft/25minGroup Jn/aJ✓ Exact
Surface Interval (fixed)Group D + 30minGroup Bn/aB✓ Exact (was A)
Surface Interval (fixed)Group Z + 30minGroup Mn/aM✓ Exact (was A)
Altitude TOD60ft @ Tahoe 6225ft80ft equiv80 ft80 ft✓ Exact
Deco RT (USN Rev 7)100ft/60min40 minn/a40 min✓ Exact
PSD Staffing — Recovery ModePrimary + Standby + DSOpassn/apass✓ Exact
PSD Staffing — Recovery ModePrimary + DSO (no Standby)fail:Standbyn/afail:Standby✓ Exact
NavCommand & IncCommand  ·  USN Rev 7 Verification

Navy Tables Verified Against Published Source

Every value in the NavCommand and IncCommand databases independently verified against the U.S. Navy Diving Manual Revision 7. NDLs, pressure groups, SI reductions, RNT values, deco stops, total runtimes, and exceptional exposure flags — all exact match.

NDL Integrity · 17+ tests
  • 35ft through 190ft NDLs match USN Rev 7 T1 exactly
  • No depth allows more bottom time than Rev 7 permits
  • Cold/strenuous −20% formula verified (floor of 80%)
  • Altitude TOD: tableDep(60) = 80ft at 6225ft altitude
Deco Schedules · 76+ cases
  • 10ft stop time exact at every depth/BT combination tested
  • 20ft and 30ft stops exact on all multi-stop profiles
  • Total deco runtime exact at all entries tested
  • Exceptional exposure flag correct at all applicable entries
Pressure Group Logic · 218+ tests
  • Every T1 breakpoint at all PSD depths 35–130ft and NC depths to 190ft
  • Groups A through Z assigned correctly at all BT boundaries
  • SI group reductions match published Navy SI table exactly
  • RNT values exact at all group/depth combos tested
Engine Bug Fixes Verified
  • NC: getRNT walks back to last present group at partial-group depths
  • NC: Zero-stop placeholder rows skipped per USN convention
  • INC: siReduce() — SI_TABLE direct USN T9-3 lookup (57 SI tests all pass)
  • INC: AdjNDL never negative, verified exhaustively A–Z × all depths
Harness 14  ·  High Volume Exhaustive Suite

1,058 Tests — Every Depth, Every Gas, Every Entry

No sampling — every O2%, every depth increment, every published table entry. DiveCommand and NavCommand both return 100%.

1,058
High volume harness  ·  DiveCommand 535 · NavCommand 523  ·  May 2026
✓ 535/535 DiveCommand  ·  ✓ 523/523 NavCommand  ·  ✓ Zero failures  ·  ✓ Zero JS errors
DC ppO2 — 104 tests
Air every 5ft 0–230ft47/47
EAN32/40/50 full ranges57/57
DC MOD — 160 tests
Every O2% 21–100 at 1.4 ata80/80
Every O2% 21–100 at 1.6 ata80/80
DC EAD + END — 174 tests
EAN32/36/40 every 5ft87/87
He20/35/50 every 5ft 60–200ft87/87
NC T1 Groups — 212 tests
Every group boundary 35–190ft212/212
NC Deco RT — 100 entries
Every USN Rev 7 RT entry 40–190ft100/100
NC ppO2/MOD/EAD — 185 tests
ppO2 air/EAN32/EAN40 × 17 depths51/51
MOD every O2% 21–50 @1.4+1.660/60
EAD EAN32/36/40 + altitude TOD74/74
Methodology

How the Tests Were Run

Three products, three complementary approaches. DiveCommand (Bühlmann ZHL-16C) and NavCommand (USN Rev 7 commercial diving) were validated using Playwright headless Chromium automation (H1–H14) loading the actual deployed HTML files and calling JavaScript functions directly — exact numerical comparison, not screenshot matching. IncCommand (USN Rev 7 public safety) was validated using a standalone browser-native harness (H19). A third approach — physics invariant testing (H20) — verifies properties that must hold regardless of specific table values: monotonicity, density differentials, gas safety margins, and cross-product consistency. All 22 harnesses evaluate exact numerical values, not screenshots or approximations. Harnesses H21 and H21b add a fourth layer — functional product testing via a simulated DOM that runs IncCommand engine functions in isolation, covering state management, UI logic, workflow chains, and report generation.

Independent Python reference implementation. The ZHL-16C validation used a Python implementation written entirely from scratch, separately from the JavaScript engine in DiveCommand. Both use the same Bühlmann 1990 constants but share no code. Agreement at Δ=0 minutes confirms the JavaScript engine correctly implements the mathematical model.

Adversarial and physics-based testing. Harness 11 was designed adversarially — testing edge cases, boundary conditions, and state transitions that happy-path tests miss. The browser-based harnesses (H15–H18B, H19) add a physics layer: testing monotonic invariants that catch logic errors even without a reference table. Combined, these two strategies found all six bugs across all testing phases — none were found by testers using the tools in normal operation.

Published table verification. NavCommand and IncCommand NDL values, deco stop schedules, stop times, total runtimes, pressure groups, RNT values, SI group reductions, and exceptional exposure flags were verified by direct comparison against the U.S. Navy Diving Manual Revision 7 — exact match, not approximate. All 212+ T1 group designator tests match the published table exactly. All 57 surface interval tests for IncCommand match USN Rev 7 Table 9-3 after the siReduce() fix.

IncCommand-specific PSD logic verified. Beyond the math engine, the IncCommand harness covers logic unique to the public safety context: Rescue vs Recovery operation mode enforcement (OSHA 1910.410 staffing compliance), ICS role assignment and string matching, chain-of-custody card visibility, contaminated water decon checklist completeness, and depth range constraints (35–130ft, no trimix). These tests verify that the tool behaves correctly as a legal and operational document, not just as a math engine.

Conservative relationship confirmed. DiveCommand is uniformly more conservative than the PADI RDP at every depth from 35–130ft, ranging from 4 minutes shorter at 130ft to 25 minutes shorter at 35ft. ZHL-16C at GF 40/85 is a tighter algorithm than the PADI table by design. Both NavCommand and IncCommand USN Rev 7 engines match the published Navy tables exactly.

Reproducible. The browser-based harnesses are self-contained HTML files. Any diver, instructor, dive medicine professional, or department safety officer can open them in any browser and run the full suite independently — no server, no account, no dependencies.

DepthPlanner.com  ·  DiveRobotix LLC  ·  Gardnerville / Lake Tahoe, NV
DiveCommand  ·  NavCommand  ·  IncCommand  ·  Built by Master Scuba Instructors, Commercial Divers & U.S. Navy Divers  ·  May–June 2026
Educational reference only — not a substitute for a calibrated dive computer used underwater.
Scroll to Top