Add NominalIris: nominal separation as a model of BI (iris-lean)#1
Open
spitters wants to merge 1 commit into
Open
Add NominalIris: nominal separation as a model of BI (iris-lean)#1spitters wants to merge 1 commit into
spitters wants to merge 1 commit into
Conversation
… the STLC [no-golf] An Iris/BI layer over nominal-lean's Atom/FinPerm/NomSet framework: - Nominal.Lambda / Nominal.LambdaAbs: the α-quotient nominal λ-term type Tm (a NomSet with an α-correct lam), with Tm.lam factoring through NameAbs Tm. - NominalIris.Separation: nominal separation as a model of classical BI (freshName_sep_ne), over Atom (the Nat-indexed state reached via Atom.val). - NominalIris.Camera: the DisjointLeibnizSet name camera, the Auth allocation view-shift name_alloc, and the iOwn/bupd ghost-state layer. - NominalIris.Den: the den morphism proving the camera and concrete BI agree. - NominalIris.Lambda: binding the nominal Tm with the ghost state — ownCtx, abs_alloc ((Abs) as name_alloc), binders_distinct, alloc_and_bind. Adds a require on iris-lean (v4.30.0), used only by the NominalIris target; the core Nominal library stays mathlib-only. No sorry; axioms propext/Classical.choice/ Quot.sound only. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
spitters
force-pushed
the
nominal-iris-separation
branch
from
July 20, 2026 17:45
e7e4003 to
543e519
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add
NominalIris: nominal separation as a model of BI (iris-lean)Summary
Adds nominal separation — separation by disjoint name support — as a model
of (classical, non-affine) bunched implications, with its camera and
iOwnghost-state reading. This is the separation-logic / Iris counterpart to the
existing mathlib-only nominal-sets development: where
Nominal.*gives names,permutations, support, and the Schanuel-topos categorical layer,
NominalIris.*gives the spatial logic —
∗as disjoint-support splitting, with atompermutation (α-renaming) as the group action.
The headline law is the nominal analogue of
ℓ₁ ↦ ∗ ℓ₂ ↦ ⊢ ℓ₁ ≠ ℓ₂:realised three ways that are proved to agree: a concrete
HeapPropmodel, theDisjointLeibnizSetcamera, andiOwn/|==>ghost state with an in-logicname-allocation view-shift.
Packaging
NominalIrisneither depends on nor isdepended on by the
Nominalcore; it fixesAtom := ℕand usesEquiv.Perm Atomdirectly, so it stands alone. (A follow-up could rebase it onNominal.Atom/ theNominaltypeclass to share the support theory.)Nominalcore stays mathlib-only. iris-lean is required by a separatelean_lib NominalIristarget only; the defaultNominaltarget is untouched.NominalIris; module rootNominalIris.*.What it adds
Two modules under
NominalIris/:Separation.lean— the nominal-separation BI (reuse route)NomProp := Iris.Instances.Classical.HeapProp Unit, so the ~40 BI laws areinherited from iris-lean's classical separation-algebra instance and
∗isexactly disjoint-name-support splitting. On top of it:
Finset Atom);∗(
psmulP_sep) andemp;freshName aandfreshName_sep_ne;Avoids a P, closed under∗;И/new quantifierNnewand the Gabbay–Pitts some = any principle(
exists_fresh_iff_forall_fresh) for equivariant families;freshName_swap/freshName_framebyiintro/iframe).Camera.lean— the camera andiOwnreadingDisjointLeibnizSet(thegset/copsetRA);NameSetwrapsFinset Atomin theIris.Std.LawfulSetinterface.den : NameRA → NomPropis proved a monoid morphism into the concrete BI:den_unit,den_op(•↦∗, unconditional),den_valid_iff; henceconcrete_sep_iff_camera_valid— distinctness is camera validity.name_alloc— the frame-preserving update● S ~~> ● (S ∪ {a}) • ◯ {a}.ownAuth/ownFreshinIProp GF(the camera as aconstOFfunctor), withown_name_alloc,own_name_alloc_init,ownFresh_distinct, aHasNameAllocclass + points-to notation (
γ ⊨fresh a,γ ⊨auth S).allocation / ν-calculus
new(demo_alloc_two_distinct, proof mode),equivariance (§1.5),
Иsome = any (§3.2).Design notes
NomProp = HeapProp Unitreuses the classical BIinstance rather than declaring a new
Iris.BI; the concreteσ = toNS wreading is kept deliberately ("∗ is literally disjoint support").
▷/OFE/guarded recursion. Name resources areflat and first-order; step-indexing would buy nothing.
name_allocis adiscrete ghost update.
Schanuel-topos monoidal-closed BI (that lives in
Nominal.Category.*).Dependencies / hygiene
require iris(iris-lean,v4.30.0) to the lakefile, used only by theNominalIristarget.Mathlib.Data.Finset.Card,Mathlib.Data.Fintype.EquivFin.sorry. Axioms:propext,Classical.choice,Quot.soundonly.lake build NominalIris.Open questions
Nominal.Atom/ theNominaltypeclass to share support theory?Iris.BIinstance vs. theHeapProp Unitreuse route?NameSet(Finset-as-Iris.Std.LawfulSet) adapter upstream?🤖 Generated with Claude Code