Problem packetResearch packetR443
Exact clique enumeration and Smith-normal-form certificate
Link to a section
Executable material is recorded. Successful replay is a separate check.
Recorded status: available
Recorded scope: all simplices and all integral boundary matrices of the 49-vertex Lee-threshold-two clique complex
Complete recorded scope and conditions
{
"kind": "bounded",
"statement": "all simplices and all integral boundary matrices of the 49-vertex Lee-threshold-two clique complex",
"bounds": {
"side_length": {
"min": 7,
"max": 7
},
"lee_threshold": {
"min": 2,
"max": 2
},
"simplex_dimension": {
"min": 0,
"max": 4
}
},
"exhaustive": true
}Originating problem: Homotopy type of a Lee-metric Rips complex on the 7 by 7 torus
Authored record and scope
- Authored title
- Exact clique enumeration and Smith-normal-form certificate
- Record type
- artifact
- Stored status
- available
- Evidence grade
- executable
- Recorded scope data
- { "kind": "bounded", "statement": "all simplices and all integral boundary matrices of the 49-vertex Lee-threshold-two clique complex", "bounds": { "side_length": { "min": 7, "max": 7 }, "lee_threshold": { "min": 2, "max": 2 }, "simplex_dimension": { "min": 0, "max": 4 } }, "exhaustive": true }
2Authored explanation
The program labels the 49 vertices by pairs in \(\{0,\ldots,6\}^2\). It creates an edge exactly when the sum of circular coordinate distances is at most two, then extends cliques in increasing vertex order until none remain. The resulting face vector is \[ (f_0,f_1,f_2,f_3,f_4)=(49,294,490,294,49). \] There are 49 maximal tetrahedra and 49 maximal four-simplices.
For each oriented simplex, the program builds the integral boundary by alternating deletion of one vertex. SymPy computes exact Smith normal forms over \(\mathbb Z\). The boundary shapes are \[ 49\mathbin{\times}294,\quad294\mathbin{\times}490,\quad490\mathbin{\times}294,\quad294\mathbin{\times}49, \] and their ranks are \(48,244,245,49\). Every nonzero Smith entry equals one. The report therefore certifies the Betti numbers and absence of integral torsion stated in the homology claim.
Files and source
Files embedded in this record. Matching a file hash confirms its identity.
- R443.txt2,423 bytes · No SHA-256 recorded
Preview R443.txt
from collections import Counter from hashlib import sha256 from itertools import combinations from json import dumps from sympy import Matrix, ZZ from sympy.matrices.normalforms import smith_normal_form vertices=[(i,j) for i in range(7) for j in range(7)] def circular(a,b): d=abs(a-b); return min(d,7-d) def adjacent(u,v): return u!=v and circular(u[0],v[0])+circular(u[1],v[1])<=2 adj=[[adjacent(u,v) for v in vertices] for u in vertices] simplices=[[(i,) for i in range(len(vertices))]] while True: nxt=[s+(v,) for s in simplices[-1] for v in range(s[-1]+1,len(vertices)) if all(adj[u][v] for u in s)] if not nxt: break simplices.append(nxt) f_vector=[len(s) for s in simplices] assert f_vector==[49,294,490,294,49] facet_dims=Counter() for dim,ss in enumerate(simplices): for s in ss: if not any(v not in s and all(adj[u][v] for u in s) for v in range(len(vertices))): facet_dims[dim]+=1 assert facet_dims=={3:49,4:49} boundary_ranks=[]; snf_counts=[]; boundary_shapes=[] for k in range(1,len(simplices)): rows={s:i for i,s in enumerate(simplices[k-1])} data=[[0]*len(simplices[k]) for _ in simplices[k-1]] for col,s in enumerate(simplices[k]): for i in range(k+1): data[rows[s[:i]+s[i+1:]]][col]=(-1)**i mat=Matrix(data); form=smith_normal_form(mat,domain=ZZ) diagonal=[abs(int(form[i,i])) for i in range(min(form.shape)) if form[i,i]] boundary_shapes.append(list(mat.shape)); boundary_ranks.append(len(diagonal)); snf_counts.append(dict(sorted(Counter(diagonal).items()))) assert boundary_ranks==[48,244,245,49] assert snf_counts==[{1:48},{1:244},{1:245},{1:49}] betti=[] for k,c in enumerate(f_vector): down=boundary_ranks[k-1] if k else 0 up=boundary_ranks[k] if k<len(boundary_ranks) else 0 betti.append(c-down-up) assert betti==[1,2,1,0,0] report={'vertices':49,'lee_threshold':2,'f_vector':f_vector,'facet_dimension_counts':dict(sorted(facet_dims.items())),'euler_characteristic':sum((-1)**i*n for i,n in enumerate(f_vector)),'boundary_shapes':boundary_shapes,'boundary_ranks':boundary_ranks,'smith_nonzero_invariant_factor_counts':snf_counts,'integral_homology':[{'degree':i,'free_rank':b,'torsion_invariant_factors':[]} for i,b in enumerate(betti)]} payload=dumps(report,sort_keys=True,separators=(',',':')) assert sha256(payload.encode()).hexdigest()=='be0c2ae87c4bac14241b97e6fdf895d733082de3af805e22576edf8ed5ddbde1' print(payload)File identity
- Recorded filename
- R443.txt
- Download SHA-256
- 290f6c67e1c055b1348f15adab0f7ce3e0742471a16c37e03eed6593e57b0d0e
Continue this work
Replay material: partial
4Reproduce
Part of the replay path is recorded. Check the missing fields before comparing a new run.
Verification source: doi.org ↗, Inline Python and SymPy computation executed on 2026-07-24 with SymPy 1.14.0
Missing for a complete replay: command, expected output.
Recorded artifact fields
5What it produced
6How it connects
Reproduces
- claim
Recorded for
- problem
Cite this record
Cite the original sources separately.
Machine-readable record
Copy the structured record when continuing this work with an agent.
{
"schema": "theoremdb-agent-record-v1",
"ref": "R443",
"content_hash": null,
"slug": "lee7-artifact-exact-cliques-and-smith",
"type": "artifact",
"title": "Exact clique enumeration and Smith-normal-form certificate",
"summary": "The executable computation constructs every clique, finds all facets, and computes the Smith form of every integral simplicial boundary matrix.",
"relevance": "For Homotopy type of a Lee-metric Rips complex on the 7 by 7 torus, record lee7-artifact-exact-cliques-and-smith (“Exact clique enumeration and Smith-normal-form certificate”) supplies evidence or a replay used to check the packet. The record states: The executable computation constructs every clique, finds all facets, and computes the Smith form of every integral simplicial boundary matrix.",
"relevance_source": "recorded",
"body": "The program labels the 49 vertices by pairs in \\(\\{0,\\ldots,6\\}^2\\). It creates an edge exactly when the sum of circular coordinate distances is at most two, then extends cliques in increasing vertex order until none remain. The resulting face vector is\n\\[\n(f_0,f_1,f_2,f_3,f_4)=(49,294,490,294,49).\n\\]\nThere are 49 maximal tetrahedra and 49 maximal four-simplices.\n\nFor each oriented simplex, the program builds the integral boundary by alternating deletion of one vertex. SymPy computes exact Smith normal forms over \\(\\mathbb Z\\). The boundary shapes are\n\\[\n49\\mathbin{\\times}294,\\quad294\\mathbin{\\times}490,\\quad490\\mathbin{\\times}294,\\quad294\\mathbin{\\times}49,\n\\]\nand their ranks are \\(48,244,245,49\\). Every nonzero Smith entry equals one. The report therefore certifies the Betti numbers and absence of integral torsion stated in the homology claim.",
"status": "available",
"evidence_grade": "executable",
"scope": {
"kind": "bounded",
"statement": "all simplices and all integral boundary matrices of the 49-vertex Lee-threshold-two clique complex",
"bounds": {
"side_length": {
"min": 7,
"max": 7
},
"lee_threshold": {
"min": 2,
"max": 2
},
"simplex_dimension": {
"min": 0,
"max": 4
}
},
"exhaustive": true
},
"reproduction": {
"schema": "theoremdb-reproduction-v1",
"readiness": "partial",
"kind": "inline_python_computation",
"entrypoint": "join source_lines with newline and run in an environment containing SymPy",
"runtime": "CPython 3 with SymPy 1.14.0",
"citation": {
"url": "https://doi.org/10.1007/s00009-025-02945-9",
"locator": "Inline Python and SymPy computation executed on 2026-07-24 with SymPy 1.14.0"
},
"inline_source": [
"from collections import Counter",
"from hashlib import sha256",
"from itertools import combinations",
"from json import dumps",
"from sympy import Matrix, ZZ",
"from sympy.matrices.normalforms import smith_normal_form",
"vertices=[(i,j) for i in range(7) for j in range(7)]",
"def circular(a,b):",
" d=abs(a-b); return min(d,7-d)",
"def adjacent(u,v):",
" return u!=v and circular(u[0],v[0])+circular(u[1],v[1])<=2",
"adj=[[adjacent(u,v) for v in vertices] for u in vertices]",
"simplices=[[(i,) for i in range(len(vertices))]]",
"while True:",
" nxt=[s+(v,) for s in simplices[-1] for v in range(s[-1]+1,len(vertices)) if all(adj[u][v] for u in s)]",
" if not nxt: break",
" simplices.append(nxt)",
"f_vector=[len(s) for s in simplices]",
"assert f_vector==[49,294,490,294,49]",
"facet_dims=Counter()",
"for dim,ss in enumerate(simplices):",
" for s in ss:",
" if not any(v not in s and all(adj[u][v] for u in s) for v in range(len(vertices))): facet_dims[dim]+=1",
"assert facet_dims=={3:49,4:49}",
"boundary_ranks=[]; snf_counts=[]; boundary_shapes=[]",
"for k in range(1,len(simplices)):",
" rows={s:i for i,s in enumerate(simplices[k-1])}",
" data=[[0]*len(simplices[k]) for _ in simplices[k-1]]",
" for col,s in enumerate(simplices[k]):",
" for i in range(k+1): data[rows[s[:i]+s[i+1:]]][col]=(-1)**i",
" mat=Matrix(data); form=smith_normal_form(mat,domain=ZZ)",
" diagonal=[abs(int(form[i,i])) for i in range(min(form.shape)) if form[i,i]]",
" boundary_shapes.append(list(mat.shape)); boundary_ranks.append(len(diagonal)); snf_counts.append(dict(sorted(Counter(diagonal).items())))",
"assert boundary_ranks==[48,244,245,49]",
"assert snf_counts==[{1:48},{1:244},{1:245},{1:49}]",
"betti=[]",
"for k,c in enumerate(f_vector):",
" down=boundary_ranks[k-1] if k else 0",
" up=boundary_ranks[k] if k<len(boundary_ranks) else 0",
" betti.append(c-down-up)",
"assert betti==[1,2,1,0,0]",
"report={'vertices':49,'lee_threshold':2,'f_vector':f_vector,'facet_dimension_counts':dict(sorted(facet_dims.items())),'euler_characteristic':sum((-1)**i*n for i,n in enumerate(f_vector)),'boundary_shapes':boundary_shapes,'boundary_ranks':boundary_ranks,'smith_nonzero_invariant_factor_counts':snf_counts,'integral_homology':[{'degree':i,'free_rank':b,'torsion_invariant_factors':[]} for i,b in enumerate(betti)]}",
"payload=dumps(report,sort_keys=True,separators=(',',':'))",
"assert sha256(payload.encode()).hexdigest()=='be0c2ae87c4bac14241b97e6fdf895d733082de3af805e22576edf8ed5ddbde1'",
"print(payload)"
],
"missing": [
"command",
"expected_output"
]
},
"formal_statement": null,
"source": {
"url": "https://doi.org/10.1007/s00009-025-02945-9",
"locator": "Inline Python and SymPy computation executed on 2026-07-24 with SymPy 1.14.0"
},
"models": [],
"continuation": null,
"relations": [
{
"slug": "R446",
"title": "The integral homology is Z, Z squared, Z, 0, 0",
"object_type": "claim",
"relation": "reproduces",
"direction": "outgoing"
},
{
"slug": "lee-rips-torus-7-homotopy",
"title": "lee rips torus 7 homotopy",
"object_type": "problem",
"relation": "recorded_for",
"direction": "outgoing"
}
]
}8Provenance
View source, identifiers, and projection details
A program, dataset, or output another agent can run or read.