Tag Info

Accepted

How do you get the Calculus of Constructions from the other points in the Lambda Cube?

First, to reiterate one of cody's points, the Calculus of Inductive Constructions (which Coq's kernel is based on) is very different from the Calculus of Constructions. It is best thought of as ...
• 32.8k

How do you get the Calculus of Constructions from the other points in the Lambda Cube?

I've often wanted to try and summarize each dimension of the $\lambda$-cube and what they represent, so I'll give this one a shot. But first, one should probably try to dis-entangle various issues. ...
• 14k
Accepted

• 5,588

Calculus of Constructions: compress expression to its smallest form

As Andrej has said, the problem is undecidable if you allow replacing one term by another, extensionally equal one. However, you might be interested in optimal sharing of expressions, in the following ...
• 14k

Eta expansion in the pattern lambda calculus

This is not a complete answer; it is a comment that got too large. If you extend typed lambda calculus with products with projective eliminators (ie, product eliminators ...
• 32.8k
Accepted

Is simply typed lambda calculus equivalent to primitive recursive functions

The simply-typed λ-calculus with β-equality at type (o → o) → o → o (which can be seen as type of the natural numbers, whenever o is any base type) can define exactly the extended polynomials (= ...
• 11.5k
Accepted

Structural equality of Pi Types with heterogeneous equality?

I am not aware that J or K exists for heterogeneous equality. It does not need an elimination principle, because it can be simply defined as a sigma type: ...
• 1,639
Accepted

Understanding the Proof of Strong Normalization of the Calculus of Constructions

Unfortunately, I'm not sure there are more beginner friendly resources than Geuvers' account. You might try this note from Chris Casinghino which gives an account of several proofs in excruciating ...
• 14k
Accepted

Typing of substitution in a bidirectional type system

The key observation is that whether the substitution theorem holds, depends on the definition of substitution. For the usual definition of substitution of terms for variables, the substitution ...
• 32.8k

Typing of substitution in a bidirectional type system

One solution is indeed to restrict to substituting with synthesizing expressions. You can only hope to replace variables with terms of the same mode (i.e. inferrable terms), anything else just won't ...
• 635
Accepted

Termination checking for Scott-encodings in System F with positive-recursive types

I'll first point you to Types for the Scott Numerals by Plotkin, Cardelli and Abadi, where they show how to encode Scott numerals in plain old system F. This at least shows that you can write the "...
• 14k

Calculus of Constructions: compress expression to its smallest form

Let me insist on the viewpoint touched upon by cody's answer. As far a see it, the question of finding a smallest $\lambda$-term equivalent to another $\lambda$-term is not really interesting, even ...
• 5,588

Type checking, Hypothetical judgments, meaning explanations and computational type theory

Part of the problem is we cannot say that we have a checker for categorical judgments, because these often reduce to hypothetical judgments. For instance, the categorical judgment $M\in A\to B$ ...
Accepted

Enumerating all simply typed lambda terms of a given type

This question has been considered several times in the academic community, from the practical: Yakushev & Jeuring, Enumerating Well-Typed Terms Generically Fetsher & al, Making Random ...
• 14k

Is there an efficient beta-equivalence algorithm?

I'd like to point out that if: the terms $M$ and $N$ are strongly normalizing (as the question allows), and one considers the complexity as depending also on the number $k_M$ and $k_N$ of beta-steps ...

Model of MLTT with $\eta$ rule where function extensionality fails

The simplest one that I know about is the $\text{Set}$-based polynomial model ("container" model). Here, every context is interpreted as a family of sets, i.e. a $Q : \text{Set}$ together ...
• 1,639

Complexity of convertibility in simply typed λ-calculus with sums

(Gabriel Scherer reporting.) I'm not a complexity person, so my answer will be partial. Here is what I can tell in short amount of thinking: You mention that the arrow(,product) case is TOWER-...
• 2,040
Accepted

Lambda-calculus: Beta-equivalent terms have the same type

The answer depends on what you mean by "simply-typed $\lambda$-calculus". There are two possibilities: Church-style: in this formulation, terms explicitly carry their type and reduction/...
• 5,588

Program inversion algorithms for higher-order programs

There hasn't been a huge amount of work in this space, but what work there is, is pretty interesting. Torben Mogensen has worked on this problem. Here are two papers of his. The first paper gives ...
• 32.8k

Moggi's computational metalanguage

It is an interesting problem to figure out what bothers the OP. First of all, it is not at all the case that the equation put forward by the OP says "different computations have the same value". For ...
• 29.3k

Can typed lambda calculi express *all* algorithms below a given complexity?

Two complements to Damiano's answer: in the simply typed λ-calculus, the expressible functions depend very much on the input and output representations, and for instance there is a way to make all ...
Accepted

Decidability of rank-k polymorphism vs. System F

The conclusion of [Kfoury & Tiuryn 1992] says (emphasis mine): We prove that [...] for every $k\ge 3$ there is a typing of constants that assigns types in $S(1)$ such that the type ...
• 4,796
Accepted

What arithmetical theorems can plain $\lambda \Pi$ reason about?

As Andrej notes, $\lambda\Pi$ is a conservative extension of first-order logic which means: Adding the axioms of PA to $\lambda\Pi$ gives exactly the same arithmetic theorems as PA. However, ...
• 14k
Accepted

Generalizations, or extensions of W-types in MLTT

The representation issue of W-types was resolved by Jasper Hugunin. So from type formers $0$, $1$, $2$, $W$, $\Pi$, $\Sigma$, identity and a universe hierarchy we do get all indexed inductive families ...
• 1,639
I've talked about a couple of these in this question, though Neel's answer gives a lot of insight as well, though I didn't dwell on $\lambda P_\underline{\omega}$ specifically. $\lambda P_2$ is quite ...