Commit graph

21 commits

Author SHA1 Message Date
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
3b1fa8325c
fix(readme): link the three documents straight to the PDF files
The server sends X-Frame-Options: DENY on every response, so the forge's
file view cannot show a PDF inside the page: the frame stays blank. The
links in the table now point at the raw files, which open in the
browser's own PDF viewer (200, application/pdf, inline).

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-10 17:23:43 +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
23aea8f2e2
docs(claude): describe the published state of the repository
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-10 16:22:31 +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
4a9170c3b7
docs(sim): point code comments at the current equation and table numbers
Four references still used the numbering from before the note was
extended: the crime dynamics are equation (12), the court queue is
equation (28) and the parameter table is table 3. Comments and one
printed heading only. Verified by running sim.py before and after:
22/22 data files byte-identical, output differs in that one heading.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-10 16:00:57 +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
13026a987e
docs(readme): lead with the tool and the first Norwegian diagnosis
The first screen now says what the tool does (binding link, type of
measure, size), states the principle and the fixed penal provisions,
and gives the result on public 2025 figures. Status and non-goals no
longer call the work "not a tool"; they state what the diagnosis can and
cannot do.

The capacity dismissals are now SSB's exact figure (30 334 in 2025,
table 09407, read from the SSB API), and README and the data file note
that SSB counts offences while the police report counts cases: using
SSB's share instead gives utilization 1.11 instead of 1.09.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 13:56:07 +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
69d693ce18
docs(paper): lead with the model as a tool for finding solutions
The abstract, introduction, conclusion and summary note now present the
model as a tool that goes from observed numbers to the binding link, the
type of measure (Theory of Constraints), how strong it can be (stability
condition) and its effect on the rest of the chain and on trust. The three
contributions are reframed as the three parts of that tool, and the
novelty table gets a first row for it.

New subsection 9.5 runs the tool step by step (a-g) on a full court and
compares its recommendation with the obvious alternatives (new table,
numbers taken from the existing runs). The summary note stays at two
pages. sim.py and paper/data/ are unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 12:46:52 +01:00
4c9a7304f3
docs(paper): add appendix mapping each equation to sim.py
New appendix C "Fra ligning til kode": for each of the 39 numbered
equations, the function and lines in sim.py that compute it, the figure
or table it feeds, and its status (18 implemented, 11 simplified, 10 not
implemented), plus a table tracing every figure and table to code and
data file. Documents small code-text differences (cap in the xi rule,
latched binding and dead zone in the coordinated rule, two-sided quality
loop). Introduction points to the appendix. sim.py and paper/data/ are
unchanged; main.tex builds with no undefined references.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 12:34:36 +01:00
520433f4a7
docs(paper): lead with what is new versus known, in use and planned
- Abstract: states first what is known and already done (dynamic optimal
  enforcement, chain forecasting in NL and SE, Norway's planned forecasting
  model and police priority analysis), then the three contributions with
  the coordination result first: forecasts are not enough.
- Introduction: prior and ongoing work now precedes "Bidrag" and ends in a
  table (tab:nytt) separating known in research / in use / under way in
  Norway / new here. "Bidrag" is rewritten to the three new things; the rest
  of the framework is labelled as mainly built on known work.
- Conclusion: one paragraph on what the result means for the chain
  forecasting model the ministry expects, limited to the court link that
  the model actually simulates.
- Summary (notat): new section "Hva som finnes, og hva som er nytt"; key
  finding retitled "prognoser er ikke nok"; tightened to stay at two pages
  (margins 16 -> 14 mm, figure height 2.8 -> 2.5 cm, shorter source line).

Built with pdflatex (TeX Live 2026): main 52 pages, notat 2 pages, no
undefined references. pdf/ is not replaced yet; that is the next part.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 12:19:30 +01:00
a167953307
docs(paper): acknowledge Norwegian precedents for chain and legislation proposals
- Forsøksloven (1992, amended 2021) already allows four-year trials in public
  administration, but only for organisation and task allocation and never by
  restricting rights; trials with procedure and sanction forms need their own
  legal basis.
- A general sunset act for regulations was rejected by the Storting in 2001
  (Innst. O. nr. 77 (2000-2001)); the proposal here covers intrusive powers only.
- Riksrevisjonen, Dokument 3:13 (2007-2008), found deadline breaches across
  several links of the chain.
- NOU 2020:11, p. 197, records a minority of the previous court commission
  warning that one oversized link creates bottlenecks.

All four were read in the primary source (Lovdata, stortinget.no,
riksrevisjonen.no, regjeringen.no PDF). Not built: TeX not installed yet.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 12:08:30 +01:00
92cca5e912
docs(notat): acknowledge existing chain-forecasting models in the summary
One sentence in "Hva modellen er" so the two-page summary does not claim
more than the main text: the Netherlands and Sweden already run whole-chain
forecasting models, and the ministry expects one for Norway. Sources added
to the source line. Not built: no TeX on this machine; the two-page limit
must be checked in the PDF build.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 11:26:51 +01:00
7a9af46350
docs(paper): acknowledge prior work and ongoing chain-forecasting efforts
The prior-work paragraph claimed novelty for the coupling only, but left out
three bodies of work a reviewer would raise:
- dynamic optimal law enforcement (Feichtinger and Tragler 2002; Tragler,
  Caulkins and Feichtinger 2001; Grass et al. 2008)
- whole-chain forecasting models already used for justice budgets
  (Netherlands PMJ since 2004, Swedish joint forecasts since 2008,
  England and Wales MoJ projections, NSW simulation model)
- Norwegian work under way (joint chain statistics until a forecasting
  model is ready, 2023; police priority-effectiveness assignment due
  31.12.2026; Riksadvokaten's priorities, stable over time by its own account)

Also adds harm-focused policing (ONS 2016, Sherman 2013, Ratcliffe 2015),
risk-based regulation (Black and Baldwin 2010), Pontell 1985, Olaya et al.
2018, Hao et al. 2026 (preprint, marked as such) and Azaria et al. 2023. The
contribution is restated as three things: the stability analysis of the
delayed loop, the coupling in one model, and the shared-constraint method.

Every new reference was checked against Crossref or the publisher's or
issuer's own document. pdf/ is not rebuilt: no TeX installation here.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 10:45:20 +01:00
0aed121706
fix(paper): correct police elasticity range attributed to Chalfin and McCrary
The note said most estimates lie between -0.1 and -0.5 (citing Chalfin and
McCrary 2017). The review instead gives a best guess of about -0.4 (violent)
and -0.2 (property), with quasi-experimental estimates spanning roughly -0.1
to -2, few of them significant (JEL 55(1), pp. 14 and 37). The conclusion
that the model's -0.83 is at the strong end still holds.

pdf/ is not rebuilt: no TeX installation on this machine.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 10:28:41 +01:00
666d3a1abc
docs(license): license the text under CC BY 4.0, keep MIT for code
PDFs and LaTeX source are CC BY 4.0; sim.py, requirements.txt and the
figure data stay MIT. README and CLAUDE.md state the split.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 10:14:43 +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