A collection of antenna models written in cocoaNEC's NC scripting language. The focus is exploring antenna designs — dipoles, magnetic loops, Moxons — and fractal geometries (Koch, Dragon Curve) as a way to learn NC scripting and NEC antenna modelling. Inspired by discussions at the Burnaby Amateur Radio Club.
This is a flat collection of .nc model scripts — there is no build, each file is
opened and run directly in cocoaNEC. Grouped by kind:
- Reference / wire antennas —
Dipole.nc,80m_Centre_Fed_Dipole.nc,offCenterFed.nc,g5rv.nc,Catenary.nc,biconical.nc - Moxon beams —
Moxon.nc,Moxon_80m.nc - Magnetic loops —
2m_magloop.nc,HUGE_magloop.nc,largeLoop.nc - Fractals —
BoringFractal.nc(first NC-recursion experiment),KochFractal.nc,DragonCurve.nc
Open Dipole.nc first as the simplest reference; BoringFractal.nc is the gentlest
introduction to the recursive NC patterns the fractal models build on.
- IDE: cocoaNEC 2.0 (macOS) — http://www.w7ay.net/site/Applications/cocoaNEC/
- Language: NC scripting (cocoaNEC's modelling language)
- Build system: none — models are interpreted by cocoaNEC at run time
- Key dependencies: macOS; cocoaNEC 2.0
There is nothing to compile. To run a model:
- Open the
.ncfile in cocoaNEC. - Run the model.
- Inspect the output (geometry, impedance, SWR, radiation pattern) in cocoaNEC.
"Verification" here is reading the NEC output — check the geometry renders as intended and the impedance / pattern is physically plausible for the band. There is no automated test harness.
- No comments unless the why is non-obvious
- No speculative code — only implement what is needed right now
- Commit messages: short, descriptive, imperative tense ("add 80m Moxon variant" not "added" or "adding")
- One antenna design per
.ncfile; name the file for the antenna and band where it matters (e.g.Moxon_80m.nc) - Keep dimensions in the units cocoaNEC expects and note the design frequency near the top of each model
- Reference dipole and a spread of wire antennas (centre-fed, off-centre-fed, G5RV, catenary, biconical)
- Moxon beams for 80m and the base design
- Magnetic loop models (2m, large, "HUGE")
- Working fractal models: Koch, Dragon Curve, plus the
BoringFractalrecursion test
- Nothing in flight
- Add a one-line description (band, type, intended use) per
.ncfile - Note which cocoaNEC version each model has been validated against
- None
- Nothing off limits at this time.
- Driver writes all code — navigator (Claude) does not write code unless explicitly asked
- Navigator provides: direction, design decisions, code review, and course corrections
- One step at a time — navigator waits for driver to confirm before moving to the next
- Navigator confirms tests pass before suggesting the next step
- Navigation is terse — no lengthy explanations unless explicitly asked
- If navigator disagrees with an approach, say so once then follow the driver's lead
All rules apply to every task unless explicitly overridden.
State assumptions explicitly. If uncertain, ask rather than guess. Present multiple interpretations when ambiguity exists. Push back when a simpler approach exists. Stop when confused. Name what's unclear.
Minimum code that solves the problem. Nothing speculative. No features beyond what was asked. No abstractions for single-use code. Test: would a senior engineer say this is overcomplicated? If yes, simplify.
The driver should touch only what is necessary to make the current test pass. Don't "improve" adjacent code, comments, or formatting. Don't refactor what isn't broken. Match existing style. Navigator warns the driver if this rule is being broken.
Before implementing anything, both driver and navigator should agree on what done looks like. A failing test is the preferred success criterion. Don't start until done is defined.
Original rule was written for agentic coding and does not apply to this pair programming model.
If the session is getting long or context feels stale, checkpoint before continuing. Summarise what's done, what's verified, what's next. Update CLAUDE.md to reflect current state, then commit before ending the session. A fresh session with good context beats a stale one with accumulated confusion.
If two patterns contradict, pick one (more recent / more tested). Explain why. Flag the other for cleanup. Don't blend conflicting patterns.
Before adding code, read exports, immediate callers, shared utilities. "Looks orthogonal" is dangerous. If unsure why code is structured a way, ask.
Tests verify what the code does from the outside, not how it does it internally. Tests must encode WHY the behaviour matters, not just WHAT it does. A test that can't fail when business logic changes is wrong.
Summarize what was done, what's verified, what's left. Don't continue from a state you can't describe back. If you lose track, stop and restate.
Conformance > taste inside the codebase. If you genuinely think a convention is harmful, surface it. Don't fork silently.
"Completed" is wrong if anything was skipped silently. "Tests pass" is wrong if any were skipped. Default to surfacing uncertainty, not hiding it.