\PassOptionsToPackage{hyphens}{url} \documentclass[11pt,a4paper]{article} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage[hmargin=27mm,vmargin=27mm]{geometry} \usepackage{amsmath,amssymb,amsthm,booktabs,array,microtype} \usepackage[numbers,sort&compress]{natbib} \usepackage[hidelinks,pdfencoding=auto]{hyperref} \usepackage{accsupp} \hypersetup{ pdftitle={Strong normalization for the K-extension of arbitrary pure type systems}, pdfauthor={Francisco R. Villatoro} } \urlstyle{same} \newcommand{\doi}[1]{\href{https://doi.org/#1}{\nolinkurl{#1}}} \newtheorem{thm}{Theorem}[section] \newtheorem{lem}[thm]{Lemma} \newtheorem{cor}[thm]{Corollary} \newtheorem{theorem}[thm]{Theorem} \newtheorem{lemma}[thm]{Lemma} \newtheorem{proposition}[thm]{Proposition} \theoremstyle{definition} \newtheorem{definition}[thm]{Definition} \newtheorem{exa}[thm]{Example} \newcommand{\WN}{\mathsf{WN}} \newcommand{\SN}{\mathsf{SN}} \newcommand{\Ktag}{\mathsf{K}} \newcommand{\keepop}{\mathsf{keep}} \newcommand{\ep}[1]{\lvert #1\rvert} \newcommand{\hexp}{\mathsf{e}} \newcommand{\cfree}{\mathsf{c}} \newcommand{\Kraw}{P^{\Ktag}} \newcommand{\Kbin}{P^{\kappa}} \newcommand{\proofnamelean}[1]{\texttt{\small #1}} \makeatletter \renewcommand{\@maketitle}{% \begin{center} {\LARGE\@title\par}\vspace{.65em} {\large\lineskip .5em\begin{tabular}[t]{c}\@author\end{tabular}\par} \end{center}} \makeatother \title{Strong normalization for the K-extension\\of arbitrary pure type systems} \author{Francisco R. Villatoro\\[3pt] {\small Escuela de Ingenierías Industriales, Universidad de Málaga}\\ {\small 29071 Málaga, Spain}\\ {\small Corresponding author: \href{mailto:frvillatoro@uma.es}{frvillatoro@uma.es} \quad\textbar\quad \href{https://orcid.org/0000-0003-4314-6213}{ORCID 0000-0003-4314-6213}}} \date{} \begin{document} \maketitle \begin{abstract} Barthe's K-extension of a pure type system adds a constant that takes two independently typed arguments and returns the first. A reduction sequence may continue computing inside the second argument for as long as it is retained. We prove that system-wide weak normalization of the ordinary calculus implies strong normalization of the extension for arbitrary specifications, including nonfunctional axioms and product rules. The proof lifts the profile construction for ordinary normalization to reducibility candidates whose realizers carry both arguments and whose dependent indices are ordinary terms. A separate adequacy theorem translates each historical typing judgment into a binary presentation and reflects every one-step reduct of its expanded terms, including steps in annotations and in discarded arguments. Ordinary strong normalization therefore implies strong normalization of the applicative K-extension. The proofs are formalized in Lean. \smallskip \par\noindent\textbf{Keywords.} Pure type systems, K-conjecture, strong normalization, reducibility candidates, formal verification. \end{abstract} \section{Introduction}\label{sec:intro} In a pure type system, a term of type $A$ and a term of type $B$ need not determine an admissible function space from $B$ to $A$. Nevertheless, one may add a constant satisfying \[ \frac{\Gamma\vdash m:A\qquad\Gamma\vdash n:B} {\Gamma\vdash\Ktag\,m\,n:A} \qquad\qquad (\Ktag\,m)\,n\longrightarrow_\kappa m . \] The rule admits a contraction regardless of the types of its arguments. Its interaction with substitution is the difficulty. Substituting a term for $x$ in $\Ktag\,y\,(x\,x)$ places it twice inside a branch that can either disappear at once or support further computation. A proof that every reduction terminates must account for both possibilities. Barthe introduced the K-rules in a study of definitions, subsets and quotients~\cite{Barthe1995}. His conjecture asks whether strong normalization of a pure type system is preserved on adjoining K (see~\cite[p.~148]{Sorensen1997} and~\cite[\S6, p.~360]{BHS2001K}). He subsequently reduced this question, for functional specifications, to the ordinary Barendregt--Geuvers--Klop conjecture~\cite{Barthe1998}. Functionality requires each axiom and each pair of input sorts of a product rule to have at most one output sort. Write $\WN_\beta(P)$ for weak normalization of every legal expression in every valid context of the ordinary PTS $P$. Geuvers formulated the ordinary weak-to-strong conjecture for both $\beta$ and $\beta\eta$~\cite[Conj.~8.1.2]{Geuvers1993}. An intermediate result of Mull~\cite[Theorem~47]{MullTYPES2023} transfers the ordinary implication from an irrelevancy-reduced specification to the original tiered PTS. In September 2026, OpenAI~\cite[Theorem~1]{OpenAI2026} proved that $\WN_\beta(P)$ implies $\SN_\beta(P)$ for every pure type specification, including reduction inside annotations. Combined with Barthe's reduction, this already settles the K-conjecture for functional specifications. We prove the following theorem even when both the axiom and product relations have multiple outputs. \begin{thm}[K-normalization]\label{th:main} For every pure type specification $P$, if $\WN_\beta(P)$ holds, every legal expression of the applicative K-extension $\Kraw$ is strongly normalizing for full $\beta\kappa$-reduction. In particular, adjoining K preserves system-wide strong normalization. \end{thm} The extension has a raw constant: partial applications are available to raw equality even though the typing rules introduce K only with two arguments. The result includes open expressions, both sides of a typing judgment, and reduction in annotations of products and abstractions. The first part of the proof concerns a binary constructor $\keepop(m,n)$ with its own intrinsic typing judgment. Erasing the second argument projects a marked type to an ordinary type. This projection retains the ordinary graph of sort profiles from~\cite{OpenAI2026}. We generalize the interpretations on that graph so that an application is tested on a marked argument $n$ while its dependent result is indexed by the erasure of $n$. A typed expansion lemma controls the second branch against a whole argument stack. We use OpenAI's exclusion of a configuration of ordinary sort profiles under system-wide weak normalization~\cite[Proposition~59]{OpenAI2026}. Because every profile is computed after erasure, the exclusion still applies while the candidates themselves control reduction in both branches. This gives the equivalence \begin{equation}\label{eq:central} \WN_\beta(P)\quad\Longleftrightarrow\quad\SN_{\beta\kappa}(\Kbin). \end{equation} The second part concerns the presentation used to state the conjecture. We construct the compression of each legal applicative term and prove exact one-step correspondence on the image of the binary syntax. Equality premises can run through raw terms outside that image. We handle those premises by a separate interpretation on the entire raw language. This interpretation is needed only for equality and requires no product rule in $P$. A close precedent for the binary constructor is the memory wrapper $t\{s\}$ of Barenbaum and Sottile~\cite[Definitions~1 and~8, Proposition~10]{BarenbaumSottile2023}. It has the type of $t$ whenever $s$ is typable, and their contextual forgetful step is exactly $t\{s\}\to t$. Their main reduction stores a copy of the argument at each contraction and their decreasing measures use simple types. Barenbaum, Ronchi Della Rocca and Sottile~\cite[Definition~3.14 and Lemma~3.18]{BarenbaumEtAl2025} use memory and forgetting in a system of idempotent intersection types. For a dependent product in the present setting the second branch of a mark can reduce while the type of an application depends on the argument. The proof of~\eqref{eq:central} must therefore control full reduction of that argument and also determine the ordinary term used to instantiate the codomain. \section{The two presentations}\label{sec:calculi} Fix a specification $P=(S,\mathcal A,\mathcal R)$ with a set of sorts $S$, an axiom relation $\mathcal A\subseteq S^2$ and a product relation $\mathcal R\subseteq S^3$. The ordinary expressions are variables, sorts, applications, abstractions $\lambda x:A.b$, and products $\Pi x:A.B$. We take expressions up to renaming of bound variables. Substitution is capture avoiding, including in annotations. A valid context is a finite sequence of distinct declarations, each of whose types inhabits a sort in its prefix. An expression $m$ is \emph{legal} in $\Gamma$ if for some $A$ either $\Gamma\vdash m:A$ or $\Gamma\vdash A:m$. For a reduction $\rho$, $\WN_\rho$ means existence of a finite path to a $\rho$-normal form and $\SN_\rho$ means accessibility for the successor relation. We use the same symbols on a system when the assertion holds for every legal expression in every valid context. \begin{figure}[t] \centering\small \BeginAccSupp{Alt={Eight typing rules cover axioms, variables, weakening, product formation, abstraction, application, conversion and the binary mark. The mark takes two independently typed arguments and has the type of the first.}} \[ \begin{gathered} \frac{(s,t)\in\mathcal A}{\varnothing\vdash s:t} \qquad \frac{\Gamma\vdash A:s}{\Gamma,x:A\vdash x:A} \qquad \frac{\Gamma\vdash m:B\quad\Gamma\vdash A:s} {\Gamma,x:A\vdash m:B} \\[7pt] \frac{\Gamma\vdash A:s_1\quad\Gamma,x:A\vdash B:s_2\quad(s_1,s_2,s_3)\in\mathcal R} {\Gamma\vdash\Pi x:A.B:s_3} \\[7pt] \frac{\Gamma,x:A\vdash b:B\quad\Gamma\vdash\Pi x:A.B:s} {\Gamma\vdash\lambda x:A.b:\Pi x:A.B} \qquad \frac{\Gamma\vdash f:\Pi x:A.B\quad\Gamma\vdash a:A} {\Gamma\vdash f\,a:B[a/x]} \\[7pt] \frac{\Gamma\vdash m:A\quad\Gamma\vdash B:s\quad A\simeq B} {\Gamma\vdash m:B} \qquad \frac{\Gamma\vdash m:A\quad\Gamma\vdash n:B} {\Gamma\vdash\keepop(m,n):A} \end{gathered} \] \EndAccSupp{} \caption{Typing of the binary presentation. Variables added to a context are fresh. For the ordinary PTS omit the last rule and take $\simeq$ to be $\beta$-equality. In the binary presentation use $\beta\kappa$-equality. In the applicative presentation replace $\keepop(m,n)$ by $(\Ktag\,m)\,n$ and allow a $\beta$-equality or a $\kappa$-equality at each conversion.}\label{fig:rules} % Alt text: Eight typing rules cover axioms, variables, weakening, product % formation, abstraction, application, conversion and the binary mark. % The mark takes two independently typed arguments and has the type of the first. \end{figure} \paragraph{Binary marks.} The grammar of $\Kbin$ adds $\keepop(m,n)$. Its reduction combines the ordinary $\beta$-contraction with $\keepop(m,n)\to_\kappa m$, closed under all term constructors. In particular a step in $n$ gives a step in $\keepop(m,n)$. Erasure $\ep{-}$ is the homomorphism on ordinary constructors satisfying $\ep{\keepop(m,n)}=\ep m$. Write $\iota$ for the inclusion of ordinary terms. Both maps act pointwise on contexts. The two branches are typed independently in Figure~\ref{fig:rules}; the judgment imposes no relation between their types. \begin{lem}[Erasure and conservativity]\label{lem:erase} A marked derivation erases to an ordinary derivation, and an ordinary derivation embeds into the marked system. Each raw marked term $m$ reduces to $\iota\ep m$. For raw marked $a,b$, \[ a=_{\beta\kappa}b\quad\Longleftrightarrow\quad \ep a=_{\beta}\ep b . \] \end{lem} \begin{proof} Erasure commutes with substitution by induction on expressions. Each marked step either erases to an identity or projects to a single ordinary step. For reachability of $\iota\ep m$, erase recursively under constructors and use the root $\kappa$-step for a mark. If the erasures are convertible, embed their ordinary conversion and join its endpoints to $a$ and $b$ by these erasing reductions. Induction on either typing derivation now gives the two typing claims, including at conversion; erasure of the mark rule retains the first premise. \end{proof} It follows that ordinary system-wide WN suffices for marked WN, by erasing first and then following an ordinary normalizing path. Strong normalization requires additional information. \begin{exa}[A diverging discarded branch]\label{ex:raw} In raw syntax put $d=\lambda x:s.\keepop(s,x\,x)$ and $w=d\,d$. Then $w\to\keepop(s,w)\to s$. Continuing the first reduction inside each new right branch instead gives an infinite sequence. The erasure $(\lambda x:s.s)(\lambda x:s.s)$ is strongly normalizing, as are the erasures of the proper subterms of $w$. Thus even checking the erasures of all the original subterms does not by itself certify strong normalization. The example concerns raw syntax. Typability of the marked expression is a hypothesis of Theorem~\ref{th:main}. \end{exa} \paragraph{The applicative constant.} The grammar of $\Kraw$ adds the constant $\Ktag$. We write application left associatively. The two head rules are ordinary $\beta$ and $(\Ktag\,m)\,n\to_\kappa m$. Their compatible closures are taken separately, and a run may use either kind of step. The histories in a conversion premise are raw: a $\beta$- or $\kappa$-equality is a zigzag of the indicated kind. More than one conversion may appear in a derivation, each with a typeable target type. There is no axiom assigning a type to the bare constant. Figure~\ref{fig:rules} with the indicated replacements defines the judgment $\Gamma\vdash_H r:T$ with variable classes omitted. Section~\ref{sec:name-classes} reinstates the historical side conditions on names. The ordinary specification always has the same sorts, axioms, and product triples on both sides of the preservation theorem. \input{adequacy} \input{semantics} \input{discussion} {\raggedright\input{bibliography}\par} \end{document}