Skip to content

feat(rf): Smith chart matches complex loads; accessible Radio tools and SVGs (to main) - #16

Merged
leavesofgrass merged 3 commits into
mainfrom
claude/sleepy-edison-2492mm
Sep 25, 2026
Merged

leavesofgrass merged 3 commits into
mainfrom
claude/sleepy-edison-2492mm

Conversation

@leavesofgrass

Copy link
Copy Markdown
Owner

This PR carries the work from #15 to main.

Why a second PR

#15 was merged into claude/sleepy-edison-2492mm, but #13, that branch's PR to main, had already been merged about 30 minutes earlier. So #15's commits landed on a branch that nothing further merges into main. This PR brings exactly those commits over:

main already has the circuit math (#13) and the RF exposure work (#14), so the diff here is only the Smith chart and accessibility change set.

What's in it

The full description is on #15. In short:

  • Fix: the Smith chart's L-network ignored the load's reactance. It now matches complex loads, each solution is verified numerically, and the chosen network's path is drawn on the chart.
  • Formulas: VSWR, REFLCOEF, RETURNLOSS, MISMATCHLOSS and VSWRG accept complex strings such as "75+25j".
  • Accessible SVG exports: role="img", <title>, and a generated <desc>.
  • Accessibility audit of all 9 Radio dialogs, through Qt's accessibility layer:

Verification

On #15's head f526a27, every check passed, including all Windows, macOS and Linux jobs, coverage, benchmarks and the science extras. This PR's CI will re-run against main.

🤖 Generated with Claude Code

https://claude.ai/code/session_0157FDmhHjtSvT3pWABUTvmX


Generated by Claude Code

claude and others added 3 commits September 25, 2026 04:15
…nd SVGs

- fix: the Smith chart's L-network matched only the load's resistance,
  so its components were wrong for any reactive load. rf.l_match_complex
  now returns every lossless L-network (shunt-at-load and series-at-load)
  for R + jX, each verified numerically (Zin == Z0); rf.match_path traces
  each network across the chart.
- Smith chart dialog: all solutions listed, the chosen one drawn along its
  constant-R / constant-G circles, constant-VSWR circle, mismatch loss,
  theme colours, text labels on every mark, keyboard focus, and a live
  screen-reader description.
- VSWR, REFLCOEF, RETURNLOSS, MISMATCHLOSS and VSWRG accept Excel complex
  strings; numeric behaviour is unchanged.
- core.science.svgaccess.make_accessible adds role="img", <title> and
  <desc>; the Smith, antenna-pattern (linear or dB-aware) and I/Q exports
  use it.
- Accessible names for the RF toolkit results, RF reference filter and
  tables, activation-log fields and table, and satellite TLE and passes;
  the antenna pattern plot is focusable and self-describing.
- tests/test_gui_radio_accessibility.py checks every Radio dialog through
  Qt's accessibility layer (fails on the pre-fix tree: 7 of 9 dialogs).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0157FDmhHjtSvT3pWABUTvmX
…h it on Linux

Windows CI failed test_radio_dialog_is_accessible[HamLogDialog]: the
ruleset QComboBox had no accessible name. Its "Ruleset:" label sat beside
it but was not its buddy, so Windows screen readers (NVDA, JAWS, Narrator)
announced an unlabelled combo box.

The test passed on Linux and macOS because Qt's accessibility layer reports
a combo box's *name* as its current value on Unix platforms (labels travel
as relations there), so the name was never empty. The audit now requires a
combo box to have an explicit accessible name or a buddy label, which is
what Windows needs, so the same gap fails on every platform. Verified: with
the dialog fix reverted, the hardened test fails on Linux.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0157FDmhHjtSvT3pWABUTvmX
…-smith

feat(rf): Smith chart matches complex loads; accessible Radio tools and SVGs
@leavesofgrass
leavesofgrass merged commit 192200c into main Sep 25, 2026
33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants