Prenex-normaalvorm

Een wiskundige formule uit de predicatenlogica is in de prenex-normaalvorm als ze geschreven is als een reeks kwantoren, gevolgd door een deel zonder kwantoren, de matrix genoemd. Deze normaalvorm schrijft dus voor hoe de kwantoren moeten worden geplaatst.

Iedere formule in de klassieke logica is logisch equivalent met een formule in prenex-normaalvorm. Bijvoorbeeld, als ϕ ( y ) ,   ψ ( z ) {\displaystyle \phi (y),\ \psi (z)} en ρ ( x ) {\displaystyle \rho (x)} kwantorloze formules zijn met vrije variabelen, dan is

x   y   z   ( ϕ ( ψ ρ ) ) {\displaystyle \forall x\ \exists y\ \exists z\ (\phi \lor (\psi \rightarrow \rho ))}

in prenex-normaalvorm met matrix ϕ ( ψ ρ ) {\displaystyle \phi \lor (\psi \rightarrow \rho )} , terwijl

x   ( ( y   ϕ ) ( ( z   ψ ) ρ ) ) {\displaystyle \forall x\ ((\exists y\ \phi )\lor ((\forall z\ \psi )\rightarrow \rho ))}

hiermee logisch equivalent is, maar niet in prenex-normaalvorm.

Conversie

Het is mogelijk een willekeurige formule H {\displaystyle H} naar een logisch equivalente formule in prenex-normaalvorm om te schrijven. Daarvoor moeten we er eerst voor zorgen dat elke variabele in H {\displaystyle H} slechts één keer voorkomt, en dat er geen variabelen zijn die zowel gebonden als vrij in H {\displaystyle H} voorkomen. Dit kunnen we altijd doen door gebonden variabelen te hernoemen. Daarna kunnen we stapsgewijs H {\displaystyle H} naar prenex-normaalvorm converteren door steeds subformules waarin een kwantor in een argument van een andere bewerking voorkomt volgens de volgende tabel om te schrijven:

Formule Prenex-normaalvorm
¬ x F {\displaystyle \lnot \forall xF} x ¬ F {\displaystyle \exists x\lnot F}
( x F ) G {\displaystyle (\forall xF)\land G} x ( F G ) {\displaystyle \forall x(F\land G)}
( x F ) G {\displaystyle (\forall xF)\lor G} x ( F G ) {\displaystyle \forall x(F\lor G)}
( x F ) G {\displaystyle (\forall xF)\rightarrow G} x ( F G ) {\displaystyle \exists x(F\rightarrow G)}
G ( x F ) {\displaystyle G\land (\forall xF)} x ( G F ) {\displaystyle \forall x(G\land F)}
G ( x F ) {\displaystyle G\lor (\forall xF)} x ( G F ) {\displaystyle \forall x(G\lor F)}
G ( x F ) {\displaystyle G\rightarrow (\forall xF)} x ( G F ) {\displaystyle \forall x(G\rightarrow F)}
¬ x F {\displaystyle \lnot \exists xF} x ¬ F {\displaystyle \forall x\lnot F}
( x F ) G {\displaystyle (\exists xF)\land G} x ( F G ) {\displaystyle \exists x(F\land G)}
( x F ) G {\displaystyle (\exists xF)\lor G} x ( F G ) {\displaystyle \exists x(F\lor G)}
( x F ) G {\displaystyle (\exists xF)\rightarrow G} x ( F G ) {\displaystyle \forall x(F\rightarrow G)}
G ( x F ) {\displaystyle G\land (\exists xF)} x ( G F ) {\displaystyle \exists x(G\land F)}
G ( x F ) {\displaystyle G\lor (\exists xF)} x ( G F ) {\displaystyle \exists x(G\lor F)}
G ( x F ) {\displaystyle G\rightarrow (\exists xF)} x ( G F ) {\displaystyle \exists x(G\rightarrow F)}

Voorbeeld

Gegeven de formule H = x P ( x ) x ( y R ( x , y ) Q ( x ) ) {\displaystyle H=\exists xP(x)\land \forall x{\bigl (}\exists yR(x,y)\to Q(x){\bigr )}} . We kunnen deze formule as volgt in prenex-normaalvorm omschrijven:

  1. Herbenoemen van variabelen: z P ( z ) x ( y R ( x , y ) Q ( x ) ) {\displaystyle \exists zP(z)\land \forall x{\bigl (}\exists yR(x,y)\to Q(x){\bigr )}}
  2. z P ( z ) x y ( R ( x , y ) Q ( x ) ) {\displaystyle \exists zP(z)\land \forall x\forall y{\bigl (}R(x,y)\to Q(x){\bigr )}}
  3. z x y ( P ( z ) ( R ( x , y ) Q ( x ) ) ) {\displaystyle \exists z\forall x\forall y{\bigl (}P(z)\land {\bigl (}R(x,y)\to Q(x){\bigr )}{\bigr )}}