Talk:Beta normal form

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia

Definition of head normal form[edit]

I disagree with the definition of head normal form namely: "A term is in head normal form if there is no beta-redex in head position". For me, this is more subtle: "A term is in head normal form if it does not reduce to a term which is a beta-redex in head position". Am I right? --PIerre.Lescanne (talk) 08:32, 24 November 2015 (UTC)[reply]

Definition of normal form, head normal form, and weak head normal form[edit]

I feel like the definitions given, could be made precise and simpler by making them inductive on the structure of terms.

  1. NF(x) holds for any atom x. Or plainly, a variable x or literal is in normal form.
  2. If NF(m) holds for a term m, then NF(λx . m) holds. Or plainly, if a term m is in normal form, then λ x . m is in normal form.
  3. If NF(m) and NF(n) hold and m n is not a redex, then NF(m n). Alternatively, NF(m) and NF(n) and m is not structurally equivalent to λx . m' then NF(m n). Or plainly, if m and n are normal forms and m is not an abstraction, i.e. of the form λx.m', then m n is in normal form.

Head normal form can be done similarly.

  1. HNF(x) holds for any atom x.
  2. If HNF(m) then HNF(λx. m).
  3. If HNF(m) and m ≠ λx.m' then for any n HNF(m n).

Under this definition, there is no confusion as to what to do with a term like (e ((λx . m)t)) n.

Also WHNF can be done similarly.

  1. WHNF(x) holds for any atom x.
  2. For any term m, WHNF(λ x.m).
  3. If WHNF(m) and m ≠ λ.m' then for any n WHNF(m n).


For example, under the current definition that there is no redex in head position, could be mistakenly read as no redex in the head term, the head term is simply the left branch of the top most application node, and this could lead to confusion about a term like (e ((λx . m)t)) n .-- User:2604:3D09:E82:5A00:FCC1:1F27:209B:1B63

I took the liberty of casting your contribution in wiki markup. Please tell us if I have misrepresented it. Regards, --Ancheta Wis   (talk | contribs) 04:02, 1 August 2021 (UTC)[reply]