Certification Problem

Input (TPDB TRS_Standard/Applicative_05/Ex8Polymorphic)

The rewrite relation of the following TRS is considered.

app(app(twice,f),x) app(f,app(f,x)) (1)
app(app(map,f),nil) nil (2)
app(app(map,f),app(app(cons,h),t)) app(app(cons,app(f,h)),app(app(map,f),t)) (3)
app(app(fmap,nil),x) nil (4)
app(app(fmap,app(app(cons,f),t_f)),x) app(app(cons,app(f,x)),app(app(fmap,t_f),x)) (5)

Property / Task

Prove or disprove termination.

Answer / Result

Yes.

Proof (by AProVE @ termCOMP 2023)

1 Uncurrying

We uncurry the binary symbol app in combination with the following symbol map which also determines the applicative arities of these symbols.

twice is mapped to twice, twice1(x1), twice2(x1, x2)
map is mapped to map, map1(x1), map2(x1, x2)
nil is mapped to nil
cons is mapped to cons, cons1(x1), cons2(x1, x2)
fmap is mapped to fmap, fmap1(x1), fmap2(x1, x2)
t_f is mapped to t_f


There are no uncurry rules.
No rules have to be added for the eta-expansion.

Uncurrying the rules and adding the uncurrying rules yields the new set of rules
twice2(f,x) app(f,app(f,x)) (14)
map2(f,nil) nil (15)
map2(f,cons2(h,t)) cons2(app(f,h),map2(f,t)) (16)
fmap2(nil,x) nil (17)
fmap2(cons2(f,t_f),x) cons2(app(f,x),fmap2(t_f,x)) (18)
app(twice,y1) twice1(y1) (6)
app(twice1(x0),y1) twice2(x0,y1) (7)
app(map,y1) map1(y1) (8)
app(map1(x0),y1) map2(x0,y1) (9)
app(cons,y1) cons1(y1) (10)
app(cons1(x0),y1) cons2(x0,y1) (11)
app(fmap,y1) fmap1(y1) (12)
app(fmap1(x0),y1) fmap2(x0,y1) (13)

1.1 Switch to Innermost Termination

The TRS is overlay and locally confluent:

10

Hence, it suffices to show innermost termination in the following.

1.1.1 Dependency Pair Transformation

The following set of initial dependency pairs has been identified.
twice2#(f,x) app#(f,app(f,x)) (19)
twice2#(f,x) app#(f,x) (20)
map2#(f,cons2(h,t)) app#(f,h) (21)
map2#(f,cons2(h,t)) map2#(f,t) (22)
fmap2#(cons2(f,t_f),x) app#(f,x) (23)
fmap2#(cons2(f,t_f),x) fmap2#(t_f,x) (24)
app#(twice1(x0),y1) twice2#(x0,y1) (25)
app#(map1(x0),y1) map2#(x0,y1) (26)
app#(fmap1(x0),y1) fmap2#(x0,y1) (27)

1.1.1.1 Dependency Graph Processor

The dependency pairs are split into 1 component.