Tag. substructural

Notes (2)

Theorem. Day Convolution is Closed day-closed-structure

Let 𝒱︀ be a symmetric monoidal closed category that is complete and cocomplete. Let (π’žοΈ€,βŠ—π’žοΈ€,𝐼) be a small monoidal 𝒱︀-enriched category and 𝐴,𝐡 be 𝒱︀-enriched presheaves on π’žοΈ€. Define

(𝐴⊸𝐡)𝑐=βˆ«π‘’π΄π‘’βŠΈπ’±οΈ€π΅(π‘’βŠ—π’žοΈ€π‘).

Then, for Day convolution βŠ—Day,

π΄βŠ—Dayβˆ’βŠ£π΄βŠΈDayβˆ’.

Proof. Proof that Day Convolution is Closed day-closed-structure-proof

For 𝑋,𝐡:π’žοΈ€op→𝒱︀, the enriched hom in [π’žοΈ€op,𝒱︀] is given by the end:

βˆ«π‘((π΄βŠ—Day𝑋)π‘βŠΈπ’±οΈ€π΅π‘)β‰…βˆ«π‘((βˆ«π‘’,π‘£π’žοΈ€(𝑐,π‘’βŠ—π’žοΈ€π‘£)βŠ—π’±οΈ€π΄π‘’βŠ—π’±οΈ€π‘‹π‘£)βŠΈπ’±οΈ€π΅π‘)β‰…βˆ«π‘βˆ«π‘’,𝑣((π’žοΈ€(𝑐,π‘’βŠ—π’žοΈ€π‘£)βŠ—π’±οΈ€π΄π‘’βŠ—π’±οΈ€π‘‹π‘£)βŠΈπ’±οΈ€π΅π‘)β‰…βˆ«π‘’,𝑣((π΄π‘’βŠ—π’±οΈ€π‘‹π‘£)βŠΈπ’±οΈ€βˆ«π‘(π’žοΈ€(𝑐,π‘’βŠ—π’žοΈ€π‘£)βŠΈπ’±οΈ€π΅π‘))β‰…βˆ«π‘’,𝑣((π΄π‘’βŠ—π’±οΈ€π‘‹π‘£)βŠΈπ’±οΈ€π΅(π‘’βŠ—π’žοΈ€π‘£))β‰…βˆ«π‘£(π‘‹π‘£βŠΈπ’±οΈ€βˆ«π‘’(π΄π‘’βŠΈπ’±οΈ€π΅(π‘’βŠ—π’žοΈ€π‘£)))β‰…βˆ«π‘£(π‘‹π‘£βŠΈπ’±οΈ€(𝐴⊸𝐡)𝑣).

∎

Symmetrically, (𝐡⟜𝐴)𝑐=βˆ«π‘£π΄π‘£βŠΈπ’±οΈ€π΅(π‘βŠ—π’žοΈ€π‘£) and βˆ’βŠ—Dayπ΄βŠ£βˆ’βŸœπ΄, so the enriched presheaf category [π’žοΈ€op,𝒱︀] is biclosed [1].

Definition. Day Convolution day-convolution

Let 𝒱︀ be a symmetric monoidal closed category that is complete and cocomplete. Let (π’žοΈ€,βŠ—π’žοΈ€,𝐼) be a small monoidal 𝒱︀-enriched category. The Day convolution of 𝒱︀-enriched presheaves 𝐴,𝐡:π’žοΈ€op→𝒱︀ is the enriched presheaf

(π΄βŠ—Day𝐡)𝑐=βˆ«π‘’,π‘£π’žοΈ€(𝑐,π‘’βŠ—π’žοΈ€π‘£)βŠ—π’±οΈ€π΄π‘’βŠ—π’±οΈ€π΅π‘£,

with unit the representable π’žοΈ€(βˆ’,𝐼).

Day convolution makes the enriched presheaf category [π’žοΈ€op,𝒱︀] a monoidal category, symmetric when π’žοΈ€ is [1]. It is moreover closed.

Under the enriched Yoneda embedding the convolution of representables is representable, π’žοΈ€(βˆ’,π‘₯)βŠ—Dayπ’žοΈ€(βˆ’,𝑦)β‰…π’žοΈ€(βˆ’,π‘₯βŠ—π’žοΈ€π‘¦), so Day convolution is the cocontinuous extension of the tensor of π’žοΈ€.

As a Kan Extension

Equivalently, π΄βŠ—Day𝐡 is the left Kan extension of (𝑒,𝑣)β†¦π΄π‘’βŠ—π’±οΈ€π΅π‘£ along βŠ—π’žοΈ€op:π’žοΈ€opΓ—π’žοΈ€opβ†’π’žοΈ€op.

In π’πžπ­

When 𝒱︀=π’πžπ­, we recover the ordinary Day convolution of presheaves 𝐴,𝐡:π’žοΈ€opβ†’π’πžπ­, where the formula simplifies to:

(π΄βŠ—Day𝐡)𝑐=βˆ«π‘’,π‘£π’žοΈ€[𝑐,π‘’βŠ—π’žοΈ€π‘£]×𝐴𝑒×𝐡𝑣.

References (16)

Security Reasoning via Substructural Dependency Tracking gouni-2026-security

Substructural type systems provide the ability to speak about resources . By enforcing usage restrictions on inputs to computations they allow programmers to reify limited system units–such as memory–in types. We demonstrate a new form of resource reasoning founded on constraining outputs and explore its utility for practical programming. In particular, we identify a number of disparate programming features explored largely in the security literature as various fragments of our unified framework. These encompass capabilities, quantitative information leakage, sandboxing in the style of the Linux seccomp interface, authorization protocols, and more. We furthermore explore its connection to conventional input-based resource reasoning, casting it as an internal treatment of the constructive Kripke semantics of substructural logics. We verify the capability, quantity, and protocol safety of our system through a single logical relations argument. In doing so, we take the first steps towards obtaining the ultimate multitool for security reasoning.
PDF Β· DOI Β· pldb

Day algebras robinson_wrigley_2026

In this paper we show that the Day monoidal product generalises in a straightforward way to other algebraic constructions and partial algebraic constructions on categories. This generalisation was motivated by its applications in logic, for example in hybrid and separation logic. We use the description of the Day monoidal product using profunctors to show that the definition generalises to an extension of an arbitrary algebraic structure on a category to a pseudo-algebraic structure on a functor category. We provide two further extensions. First we consider the case where some of the operations on the category are partial, and second we show that the resulting operations on the functor category have adjoints (they are residuated).
DOI Β· arXiv

Ordered Adjoint Logic roshal-2026-ordered

Ordered logics and type systems have been used in a variety of applications including computational linguistics, memory allocation, stream processing, logical frameworks, parametricity, and enforcing security protocols. In most formulations, ordered types are also linear, requiring each resource to be used exactly once. Prior work by Kanovich et al. has investigated calculi that relax this constraint through subexponentials within a linear ordered logic. We generalize their work by using adjoint modalities to combine logics with varying fine-grained structural properties, including weakening, left contraction, right contraction, left mobility, and right mobility. We show that the resulting sequent calculus admits cut elimination. We further provide a natural deduction formulation in which structural rules are implicit, and show that proof checking for this system is decidable. This makes it a suitable foundation for an expressive adjoint programming language or logical framework.
DOI

Substructural Abstract Syntax with Variable Binding and Single-Variable Substitution fiore-2025-substructural

DOI Β· arXiv

Substructural Parametricity aberle-2025-substructural

Ordered, linear, and other substructural type systems allow us to expose deep properties of programs at the syntactic level of types. In this paper, we develop a family of unary logical relations that allow us to prove consequences of parametricity for a range of substructural type systems. A key idea is to parameterize the relation by an algebra, which we exemplify with a monoid and commutative monoid to interpret ordered and linear type systems, respectively. We prove the fundamental theorem of logical relations and apply it to deduce extensional properties of inhabitants of certain types. Examples include demonstrating that the ordered types for list append and reversal are inhabited by exactly one function, as are types of some tree traversals. Similarly, the linear type of the identity function on lists is inhabited only by permutations of the input. Our most advanced example shows that the ordered type of the list fold function is inhabited only by the fold function.
DOI

Foundations of Substructural Dependent Type Theory aberle-2024-foundations

This paper presents preliminary work on a general system for integrating dependent types into substructural type systems such as linear logic and linear type theory. Prior work on this front has generally managed to deliver type systems possessing either syntax or semantics inclusive of certain practical applications, but has struggled to combine these all in one and the same system. Toward resolving this difficulty, I propose a novel categorical interpretation of substructural dependent types, analogous to the use of monoidal categories as models of linear and ordered logic, that encompasses a wide class of mathematical and computational examples. On this basis, I develop a general framework for substructural dependent type theories, and proceed to prove some essential metatheoretic properties thereof. As an application of this framework, I show how it can be used to construct a type theory that satisfactorily addresses the problem of effectively representing cut admissibility for linear sequent calculus in a logical framework.
arXiv

Adjoint Natural Deduction jang-2024-adjoint

Adjoint logic is a general approach to combining multiple logics with different structural properties, including linear, affine, strict, and (ordinary) intuitionistic logics, where each proposition has an intrinsic mode of truth. It has been defined in the form of a sequent calculus because the central concept of independence is most clearly understood in this form, and because it permits a proof of cut elimination following standard techniques. In this paper we present a natural deduction formulation of adjoint logic and show how it is related to the sequent calculus. As a consequence, every provable proposition has a verification (sometimes called a long normal form). We also give a computational interpretation of adjoint logic in the form of a functional language and prove properties of computations that derive from the structure of modes, including freedom from garbage (for modes without weakening and contraction), strictness (for modes disallowing weakening), and erasure (based on a preorder between modes). Finally, we present a surprisingly subtle algorithm for type checking.
DOI Β· arXiv

A Framework for Substructural Type Systems wood-2022-a

Mechanisation of programming language research is of growing interest, and the act of mechanising type systems and their metatheory is generally becoming easier as new techniques are invented. However, state-of-the-art techniques mostly rely on structurality of the type system β€” that weakening, contraction, and exchange are admissible and variables can be used unrestrictedly once assumed. Linear logic, and many related subsequent systems, provide motivations for breaking some of these assumptions. We present a framework for mechanising the metatheory of certain substructural type systems, in a style resembling mechanised metatheory of structural type systems. The framework covers a wide range of simply typed syntaxes with semiring usage annotations, via a metasyntax of typing rules. The metasyntax for the premises of a typing rule is related to bunched logic, featuring both sharing and separating conjunction, roughly corresponding to the additive and multiplicative features of linear logic. We use the uniformity of syntaxes to derive type system-generic renaming, substitution, and a form of linearity checking.
PDF Β· DOI Β· pldb

Predictable accelerator design with time-sensitive affine types nigam-2020-predictable

PDF Β· DOI Β· arXiv Β· pldb

Syntax and Semantics of Quantitative Type Theory atkey-2018-syntax

DOI

Substructural calculi with dependent types luo

In this paper, we investigate how to introduce dependent types into the substructural calculi such as the Lambek calculus and linear logic. The motivations of such a move include facilitating a closer correspondence between syntax and semantics in natural language analysis and developing promising applications such as that to concurrency through dependent session types.

We shall present two substructural calculi with dependent types: the first containing dependent Lambek types and the second dependent linear types. Technically, the former adheres to the usual assumption that types do not depend on substructural variables (in this case, the Lambek variables), which makes the technical development easier, while the latter allows type dependency on linear variables, which makes the development more challenging as well as more interesting in applications.

DOI

I Got Plenty o’ Nuttin’ mcbride-2016-i

DOI

Multi-Sorted Residuation buszkowski_2014

Web

Type refinement and monoidal closed bifibrations mellies_zeilberger_2013

The concept of refinement in type theory is a way of reconciling the β€œintrinsic” and the β€œextrinsic” meanings of types. We begin with a rigorous analysis of this concept, settling on the simple conclusion that the type-theoretic notion of β€œtype refinement system” may be identified with the category-theoretic notion of β€œfunctor”. We then use this correspondence to give an equivalent type-theoretic formulation of Grothendieck’s definition of (bi)fibration, and extend this to a definition of monoidal closed bifibrations, which we see as a natural space in which to study the properties of proofs and programs. Our main result is a representation theorem for strong monads on a monoidal closed fibration, describing sufficient conditions for a monad to be isomorphic to a continuations monad β€œup to pullback”.
Web

On the Logic of Bunched Implications β€” and its relation to separation logic biering_bunched_2004

Web

The logic of bunched implications ohearn_pym_bi_1999

We introduce a logic BI in which a multiplicative (or linear) and an additive (or intuitionistic) implication live side-by-side. The propositional version of BI arises from an analysis of the proof-theoretic relationship between conjunction and implication; it can be viewed as a merging of intuitionistic logic and multiplicative intuitionistic linear logic. The naturality of BI can be seen categorically: models of propositional BI’s proofs are given by bicartesian doubly closed categories, i.e., categories which freely combine the semantics of propositional intuitionistic logic and propositional multiplicative intuitionistic linear logic. The predicate version of BI includes, in addition to standard additive quantifiers, multiplicative (or intensional) quantifiers [inline image] and [inline image] which arise from observing restrictions on structural rules on the level of terms as well as propositions. We discuss computational interpretations, based on sharing, at both the propositional and predicate levels.
tag-substructural tag