• Aucun résultat trouvé

Reductions and Causality (IV)

N/A
N/A
Protected

Academic year: 2022

Partager "Reductions and Causality (IV)"

Copied!
25
0
0

Texte intégral

(1)

Reductions and Causality (IV)

jean-jacques.levy@inria.fr Tsinghua University, November 11, 2011

http://pauillac.inria.fr/~levy/courses/tsinghua/reductions

(2)

























Exercices

• Show all standard reductions in the 2 reduction graphs of

beginning of this class.

(3)

Exercices

• Show all standard reductions in the 2 reduction graphs of beginning of this class.

( x .x )(( y .( x .x )a)b )

( y .( x .x )a)b ( x .x )(( y .a)b)

( x .x )(( x .x )a)

( x .x )a ( y .a)b

a

( x .x )a

mid int ext

(4)

Exercices

• Find an example where there is no greatest lower bound of 2 reductions. (Hint: you should use K -terms)

Y

f

= ( x .f (xx ))( x .f (xx )) ( y .a)(( z .b)Y

f

))

( y .a)b ( x .a)( z .b)

M = ( x .( y .a)(xY

f

))( z .b) ( x .( y .a)(xY

fn

))( z .b )

( y .a)(( z .b)Y

fn

))

(5)

Exercices

• Show that there is inf-lattice of reductions in I-calculus.

st

: M N ,

st

: M

0

N , ⌧ : M M

0

then | ⇢

st

| |

st

| + | ⌧ |

(6)

Plan

• redexes and their history

• creation of redexes

• redex families

• finite developments

• finite developments+

• infinite reductions, strong normalization

(7)

Redex families

(8)

Initial redexes - new redexes

Red and blue are initial redexes. Green is new.

























(9)

Redexes and their history (1/3)

Notation [historical redexes]

We write h ⇢, R i when ⇢ : M N and R is redex in N .

Definition [copies of redexes]

h ⇢, R i  h , S i when ⇢ v and S 2 R /( /⇢)

Definition [redex families]

h ⇢, R i ⇠ h , S i stands for the symmetric and transitive

closure of the copy relation.

(10)

Redexes and their history (2/3)

σ

'

R S

h ⇢, R i ⇠ h , S i h ⇢, R i  h , S i

'

σ

R

S

S 2 R/⇢

(11)

Redex families (1/3)

3 redex families: red, blue, green.

























(12)

Redex families (2/3)

3 redex families: red, blue, green.

( x.x)(( y.( x.x)a)b)

( y.( x.x)a)b ( x.x)(( y.a)b)

( x.x)(( x.x)a)

( x.x)a ( y.a)b

a ( x.x)a

mid int ext

(13)

Redexes families (3/3)

Proposition

Question Is there a canonical redex in each family ?

T 2 R/⇢,T 2 S/⇢ implies R = S

' implies R/⇢ = R/

h⇢,Ri  h,Ti, h ,Si  h,Ti does not implies h0,T0i  h⇢,Ri, h0,T0i  h ,Si for some h0,T0i h⇢,Ri  h,Ti, h ,Si  h,Ti implies h⇢,Ri  h t ,T0i  h,Ti,

h ,Si  h t ,T0i  h,Ti

h⇢,Ri ⇠ h ,Si does not implies h0,T0i  h⇢,Ri, h0,T0i  h ,Si for some h0,T0i h⇢,Ri ⇠ h ,Si does not implies h⇢,Ri  h0,T0i, h ,Si  h0,T0i for some h0,T0i

(b) (a)

(c)

(d)

(e)

(f)

(14)

























shortest standard reduction

Canonical representatives (1/4)

Proposition [initial redexes]

h0,Ri ⇠ h ,Si implies S 2 R/

Others ?

(15)

Canonical representatives (2/4)

Definition [extraction of canonical redex]

Let M = ( x .P )Q M

1

M

2

· · · M

n

and h ⇢

st

, R i be historical redex from M and H is head redex in M .

extract(H ; ⇢

st

, R ) = H ; extract(⇢

st

, R )

(16)

Finite developments

(17)

Parallel steps revisited (1/3)

parallel steps were defined with inside-out strategy [a la Martin-Löf]

can we take any order as reduction strategy ?

in M is any reduction contracting only residuals of F .

Definition A reduction relative to a set

F of redexes

F is any maximal relative reduction of F .

A development of

(18)

Parallel steps revisited (2/3)

Theorem [Finite Developments, Curry, 50]

Let F be set of redexes in M .

(1) there are no infinite relative reductions of F , (2) they all finish on same term N

(3) Let R be redex in M . Residuals of R by all finite developments of F are the same.

Similar to parallel moves lemma, but we considered particular inside-out reduction strategy.

(19)

Parallel steps revisited (3/3)

Notation’ [parallel reduction steps]

Let F be set of redexes in M . We write M

F

N if a development of F connects M to N .

This notation is consistent with previous results

Corollaries of FD thm are also parallel moves + cube lemmas

(20)

Finite and infinite reductions (1/3)

Definition A reduction relative to a set

F of redex families is any reduction contracting redexes in families of F .

F is any maximal relative reduction.

A development of

Theorem [Finite Developments+, 76]

Let F be a finite set of redex families.

(1) there are no infinite reductions relative to F , (2) they all finish on same term N

(3) All developments are equivalent by permutations.

(21)

Finite and infinite reductions (2/3)

Corollary An infinite reduction contracts an infinite set of redex families.

Corollary The first-order typed λ-calculus strongly terminates.

Proof In first-order typed λ-calculus:

(1) residuals R

0

= ( x .M

0

)N

0

of R = ( x .M )N keep the same type of the function part

(2) new redexes have lower type of their function part

(22)

Finite and infinite reductions (3/3)

( x.· · ·xN · · ·)( y.M) · · ·( y.M)N · · ·

creates

( x. y.M)NP ( y.M )P

creates

creates

!

( x.x)( y.M)N ( y.M)N

Proof (cont’d) Created redexes have lower type

(23)

Inside-out reductions

Definition: The following reduction is inside-out

⇢ : M = M

0 R1

M

1 R2

M

2

· · ·

Rn

M

n

= N

i↵ for all i and j , i < j , then R

j

is not residual along ⇢ of some R

j0

inside R

i

in M

i 1

.

Theorem [Inside-out completeness, 74]

Let M N . Then M

io

P and N P for some P .

io

'

inside-out+

(24)

Exercices

(25)

Exercices

Show

io io

io io io io

io

Références

Documents relatifs

The lambda-calculus is more directly connected to functional languages (Lisp, Scheme, SML, Ocaml, Haskell), but its type theory inspired many other languages (Java, C#, F#, Scala)..

• we replaced occurences by giving names (labels) to

• Similar to parallel moves lemma, but we considered particular inside-out reduction strategy... Parallel steps

• highly exponential in the handling of fans node (not elementary recursive) [Asperti, Mairson 2000]. • nice algorithms unsharing paths to bound variables [Wadsworth

• Need closer look at reduction steps and notice when they can be permuted.. • Show reductions equivalent by permutations in following reduction

• permutations of derivations are defined with critical pairs. • critical pairs

• Exercice 4: Complete all proofs of propositions. • Exercice 5: Show equivalent

The Acoustic Keyword Spotting (AKWS) systems follow our paper [6]. We build an HMM for each query. For each frame, the detection score is calculated as the log- likelihood ratio