Commit graph

10 commits

Author SHA1 Message Date
e354616ffa
docs: mark the work as finished and fix the last two review findings
- README: status line saying the work is finished and no new versions
  are planned; input can still be sent by e-mail.
- Section 9.7: the five kinds of insight were one 18-line sentence and
  are now a list. Same content. A conditional page break keeps the
  heading of 9.8 with its box.
- Appendix C, row for equation (8): states that the budget forecast
  (sim.py line 624) starts from the full state and the forcing as they
  were 3 months earlier, while capacity is known without delay.
- Note PDF rebuilt (59 pages). Summary and slides unchanged.
- sim.py, diagnose.py, forlop.py and paper/data are unchanged.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-11 20:55:35 +01:00
dbcab3fb68
docs: present the plugin for Claude and state the start-point limitation
- README, the note (abstract, introduction, section 10), the two-page
  summary and the slides now point to the plugin dynamisk-rettsstat, with
  link. The slides get a new slide 16 about it (17 slides in all); the
  summary gets a box with both links and stays on two pages.
- New limitation in section 10: in the models with a court queue the
  starting point is close to, but not exactly, an equilibrium. Without any
  shock crime drifts from 1.000 to 1.018 and the processing time from 3.0
  to 4.6 months over 240 months. No numbers, tables or figures change.
- PDFs rebuilt: note 59 pages (was 58), summary 2, slides 17 (was 16).
- sim.py, diagnose.py, forlop.py and paper/data are unchanged.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-11 20:39:26 +01:00
2badc25e51
feat(forlop): start the time course in the backlog given in the file
forlop.py now puts the backlog from the input file straight into the
model at the time the numbers apply, instead of letting the model build
it up itself (which reached at most 15 months and left larger backlogs
"ikke regnet"). It carries its own copy of the simulate_endo loop
(simuler, policies koord and sched) and checks on every run that the
copy matches sim.py bit for bit. sim.py and paper/data are untouched
(22/22 data files identical after a fresh run).

The example file gives the same numbers as before (+19 %, +12 %, 1,31;
8,3 / 0,74 / 1,10 / +31 % / 3,5; 68,7 / 0,65 / 1,26). A copy with
backlog 3000 now gives a course starting at 3 000 (+119 %). The course
is not computed when crime falls below 0,80 or police effort below 0,50
in the model while the backlog is cleared.

Independent review before commit: 8 findings, 7 fixed (the eighth is an
older column-width issue for seven-digit numbers).

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-10 18:01:55 +01:00
974a9f31f1
docs(readme): state plainly who did what
The author supplied the topic, the starting point, the use of Theory of
Constraints and comments along the way; the text, mathematics,
simulations and code were in practice produced by AI. The author has not
verified all the mathematics. Replaces the stronger wording that the
author made the professional choices. Operator decision 2026-11-10.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-10 17:09:54 +01:00
01d335e941
feat(forlop): time course and stability check from own numbers
New script paper/forlop.py reads the same input file as diagnose.py.
It checks whether the steering tolerates its own delay, places the
binding link in the model as the link with a queue, calibrates the size
and start of the increase so that the coordinated rule's first budget
decision sees the numbers in the file, and runs simulate_endo month by
month with and without measures. It also reports what the measure does
to the rest of the chain: police effort, the share diverted, and whether
the bottleneck moves to the links after it.

The example file reproduces section 9.5 and table 10: +19 % now, +12 %
after 12 months, capacity 1,31; 8,3 / 0,74 / 1,10 / 3,5 with measures and
68,7 / 0,65 / 1,26 without. The stability block reproduces section 9.3
with delay 11 and reactivity 3. The script declines to print a time
course when the steering is unstable, when the forecast has not settled
within the horizon, or when the model cannot build the backlog in the
file before the first decision.

sim.py is imported unchanged; paper/data is untouched. diagnose.py gives
identical output for both input files; the bottleneck selection is now a
function so forlop.py can reuse it, and true/false are rejected where a
number is expected. Reviewed by an independent agent; its 14 findings
are addressed.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-10 16:20:31 +01:00
e6e9d3c74d
fix: correct findings from the pre-publication quality check
Seventeen independent read-only reviews (figures and sources, the diagnosis
tool, the mathematics, simulation numbers, appendix C, references, claims,
language, layout, summary and slides, README and repo, cross-document
consistency), each followed by an independent verifier. Every fix below was
checked against the source or recomputed before it was applied.

Norwegian diagnosis (paper/norge_2025.json, README):
- The prison outflow mixed units: it multiplied "cases handled" (16 000) by
  the share of enforced cases. It now uses enforced cases (KDI annual report
  2025, p. 70: 5 180 in the community = 58 %, so about 3 750 in prison), and
  the queue excludes sentences waiting for electronic monitoring.
- Result changes: prison and police/prosecution tie at utilisation 1,09; the
  tool points to prison on backlog growth. README says the difference is
  smaller than the uncertainty and lists the sensitivity (1,06 to 1,10).
- Police backlog taken directly from POD report 1/2026 fig. 3.2.1 (31 908
  vs 30 295); page references to the courts report corrected (15 and 18).

diagnose.py:
- Norwegian error messages instead of tracebacks for bad input; same
  expansion threshold as sim.py; tie message; honest wording when no
  forecast is given, when the constraint is the first link, and when a
  backlog grows with no link above full utilisation.

Note, summary and slides (PDFs rebuilt: 58, 2 and 16 pages):
- b_sat in (13') lacked the factor 1/T-bar; lowest trust in appendix C is
  0,33, not 0,47; nine numbers rounded or quoted wrongly; one sensitivity
  sentence was wrong for mu_4; the abstract claimed more police effort does
  not reduce crime, which the model contradicts.
- The decommissioning rule is described as the code implements it.
- Three references corrected, one added (Srivastav et al. 2019).
- Core sentence quoted verbatim in README and section 9.
- Layout: duplicate hyperref targets, the overfull box in table 1, three
  figures with colliding labels, one stranded heading.
- Summary and slides no longer say "not tested on Norwegian data"; slide 16
  gives the repository address.

sim.py and paper/data/ are untouched.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-10 15:46:23 +01:00
1723d593f8
feat(diagnose): first bottleneck diagnosis on public Norwegian figures
paper/norge_2025.json holds 2025 and October 2026 figures for police and
prosecution, district courts, appeal courts and prison, each with its
source (POD report 1/2026, Domstoladministrasjonen annual report 2025,
Kriminalomsorgen key figures October 2026 and annual report 2025, SSB).
Derived values are marked as estimates.

Result: police and prosecution bind (utilization 1.09 once dismissals
for lack of capacity are counted as untreated), with prison (1.06) and
district courts (1.04) also above full utilization; appeal courts are
below (0.88). README shows the table and its caveats.

diagnose.py accepts an acceptable backlog instead of a target time, and
cases closed without treatment, and lists other links above capacity.
The stylized example still reproduces section 9.5.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 13:37:12 +01:00
809dd4ccba
feat(diagnose): bottleneck diagnosis from own numbers, first version
paper/diagnose.py takes inflow, capacity, backlog and target time per
link and returns utilization, throughput time and backlog growth per
link, the binding link, the type of measure in Theory of Constraints
order (exploit, subordinate, elevate) and, for the binding link, the
capacity needed under the coordinated rule from sim.py, sized on the
forecast flow rather than the queue.

The example file holds the stylized month-24 values from the coordinated
run and reproduces section 9.5 (utilization 1.28, +19 % capacity);
checked against simulate_endo("koord"), which orders +19 % in month 24.
sim.py and paper/data/ are unchanged. Time paths and the stability check
for the police rule are not in this version.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 13:25:39 +01:00
5d4557d912
docs(pdf): lead the slides with the tool and rebuild all PDFs from source
The slides now present the model as a tool right after the idea: a new
slide on what it finds (binding link and type of measure, how strong,
effect on the rest of the chain and on trust), the seven steps, and the
worked full-court example with the table from section 9.5 next to the
coordination figure. The findings follow as what the tool builds on. The
separate full-link slide is replaced by the example; 16 slides.

The font path for Inter is no longer a hard-coded Linux path, so the
slides build with TeX Live's copy of Inter.

main (57 pages), notat (2) and karusell (16) are rebuilt from the source
in this repository and replace the PDFs in pdf/. README, CHANGELOG and
CLAUDE.md state the new page counts and the verified build commands.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 13:20:00 +01:00
85bc99b257
feat: initial commit of concept note v2 and simulation
Concept note "Den dynamiske rettsstaten" version 2: PDFs, LaTeX source,
simulation (sim.py) and figure data. Working documents are kept out of
the repository.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 10:10:20 +01:00