PWR-HYBRID-3/journal/journal.tex
Dane Sabo fbbaebff9f julia migration: port MATLAB to Julia, delete MATLAB, rename julia-port -> code
Full toolchain port. Numerical equivalence verified against MATLAB:
- main_mode_sweep.jl: every mode's final state matches MATLAB to 3-4 dp
- reach_operation.jl: per-halfspace margins match MATLAB exactly
- barrier_lyapunov.jl: per-halfspace bounds match (best Qbar from sweep
  yields max|dT_c| = 33.228 K either side)
- barrier_compare_OL_CL.jl: OL gamma 1.038e13, CL gamma 1.848e4
  matching the MATLAB result; LQR helps by ~20,000x on every halfspace.

Phase summary:
  Phase 1: pke_solver.jl, plot_pke_results.jl (Plots.jl), main_mode_sweep.jl
  Phase 2: reach_linear.jl, reach_operation.jl, barrier_lyapunov.jl,
           barrier_compare_OL_CL.jl, load_predicates.jl
  Phase 3 (this commit): delete plant-model/ entirely, delete reach
           code from reachability/ keeping predicates.json + docs,
           git mv julia-port/ -> code/, update root README + CLAUDE,
           write code/CLAUDE.md and code/README.md, update reach
           README + WALKTHROUGH file paths, journal preamble note
           that pre-port entries reference MATLAB paths.

Why now: prompt-neutron stiffness in nonlinear reach made it clear we
need TMJets, which is Julia. Already had the Julia plant model
working and matching MATLAB. Two languages = two sources of truth =
two places to drift. One language, one truth.

Manifest.toml gitignored. .mat results gitignored.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-20 21:44:59 -04:00

77 lines
2.5 KiB
TeX

% journal.tex — top-level document that aggregates all dated entries.
%
% Build:
% cd journal && latexmk -pdf journal.tex
% or individual entry:
% cd journal && latexmk -pdf entries/2026-04-17-controllers-linear-reach.tex
\input{preamble.tex}
\title{HAHACS Lab Journal\\
\large PWR\_HYBRID\_3 preliminary example, invention log}
\author{Dane Sabo, with Claude (Hacker-Split)}
\date{Started \today}
\begin{document}
\maketitle
\tableofcontents
\newpage
\section*{How to read this journal}
Each section is a dated session. Sessions are written in two styles:
\begin{itemize}
\item \textbf{Deep (A-style)}: full invention-log depth. Derivations
in math, code snippets with commentary, figures with long
captions, dead-ends documented, terminal output included where
it changes the story. A reader in 2030 should be able to
rebuild the work from this alone.
\item \textbf{Narrative (B-style)}: end-of-session notes with
pointers. Marked with \apass{some detail} callouts for
content that should be expanded in a later A-pass.
\end{itemize}
\textbf{File-path archaeology note.} Entries dated on or before
2026-04-20 (afternoon) refer to MATLAB files under \texttt{plant-model/}
and a MATLAB-Julia split where Julia code lived under \texttt{julia-port/}.
The 2026-04-20 evening mega-session ported everything to Julia and
deleted MATLAB; the result is the unified \texttt{code/} directory.
Path references in earlier entries are historically accurate for their
date; recover the corresponding sources via \texttt{git log} or the
parent commit at the time.
Callout boxes signal specific content types:
\begin{derivation}
Mathematical derivations — algebra, integrals, limits. Where they
matter to the safety claim, they live here in full.
\end{derivation}
\begin{decision}
Design decisions made during the session, with the rationale and the
alternatives considered.
\end{decision}
\begin{deadend}
Approaches that didn't work and why. These are as valuable as the
working paths — they keep the next explorer from repeating the mistake.
\end{deadend}
\begin{limitation}
Known-approximate or known-broken behavior. Soundness gaps live here.
Each limitation ties to a plan or an open question.
\end{limitation}
\newpage
% ---- Session entries, in chronological order -------------------------------
\input{entries/2026-04-17-controllers-linear-reach.tex}
\newpage
\input{entries/2026-04-20-predicates-boundaries-julia-nonlinear.tex}
\newpage
\input{entries/2026-04-20-evening-mega-session.tex}
\end{document}