Certification Problem
Input (TPDB TRS_Standard/CiME_04/list-sum-prod-bin-assoc)
The rewrite relation of the following TRS is considered.
0(#) |
→ |
# |
(1) |
+(x,#) |
→ |
x |
(2) |
+(#,x) |
→ |
x |
(3) |
+(0(x),0(y)) |
→ |
0(+(x,y)) |
(4) |
+(0(x),1(y)) |
→ |
1(+(x,y)) |
(5) |
+(1(x),0(y)) |
→ |
1(+(x,y)) |
(6) |
+(1(x),1(y)) |
→ |
0(+(+(x,y),1(#))) |
(7) |
+(+(x,y),z) |
→ |
+(x,+(y,z)) |
(8) |
*(#,x) |
→ |
# |
(9) |
*(0(x),y) |
→ |
0(*(x,y)) |
(10) |
*(1(x),y) |
→ |
+(0(*(x,y)),y) |
(11) |
*(*(x,y),z) |
→ |
*(x,*(y,z)) |
(12) |
sum(nil) |
→ |
0(#) |
(13) |
sum(cons(x,l)) |
→ |
+(x,sum(l)) |
(14) |
prod(nil) |
→ |
1(#) |
(15) |
prod(cons(x,l)) |
→ |
*(x,prod(l)) |
(16) |
Property / Task
Prove or disprove termination.Answer / Result
Yes.Proof (by NaTT @ termCOMP 2023)
1 Dependency Pair Transformation
The following set of initial dependency pairs has been identified.
sum#(nil) |
→ |
0#(#) |
(17) |
*#(*(x,y),z) |
→ |
*#(x,*(y,z)) |
(18) |
*#(0(x),y) |
→ |
0#(*(x,y)) |
(19) |
sum#(cons(x,l)) |
→ |
sum#(l) |
(20) |
+#(1(x),1(y)) |
→ |
+#(+(x,y),1(#)) |
(21) |
+#(1(x),1(y)) |
→ |
+#(x,y) |
(22) |
*#(0(x),y) |
→ |
*#(x,y) |
(23) |
+#(0(x),0(y)) |
→ |
0#(+(x,y)) |
(24) |
*#(*(x,y),z) |
→ |
*#(y,z) |
(25) |
+#(1(x),1(y)) |
→ |
0#(+(+(x,y),1(#))) |
(26) |
*#(1(x),y) |
→ |
*#(x,y) |
(27) |
prod#(cons(x,l)) |
→ |
prod#(l) |
(28) |
+#(+(x,y),z) |
→ |
+#(y,z) |
(29) |
+#(0(x),0(y)) |
→ |
+#(x,y) |
(30) |
prod#(cons(x,l)) |
→ |
*#(x,prod(l)) |
(31) |
*#(1(x),y) |
→ |
+#(0(*(x,y)),y) |
(32) |
+#(1(x),0(y)) |
→ |
+#(x,y) |
(33) |
sum#(cons(x,l)) |
→ |
+#(x,sum(l)) |
(34) |
+#(0(x),1(y)) |
→ |
+#(x,y) |
(35) |
*#(1(x),y) |
→ |
0#(*(x,y)) |
(36) |
+#(+(x,y),z) |
→ |
+#(x,+(y,z)) |
(37) |
1.1 Dependency Graph Processor
The dependency pairs are split into 4
components.
-
The
1st
component contains the
pair
sum#(cons(x,l)) |
→ |
sum#(l) |
(20) |
1.1.1 Reduction Pair Processor with Usable Rules
Using the Max-polynomial interpretation
[0#(x1)] |
=
|
0 |
[1(x1)] |
=
|
0 |
[prod(x1)] |
=
|
0 |
[prod#(x1)] |
=
|
0 |
[*#(x1, x2)] |
=
|
0 |
[#] |
=
|
0 |
[sum(x1)] |
=
|
0 |
[0(x1)] |
=
|
0 |
[nil] |
=
|
0 |
[cons(x1, x2)] |
=
|
x2 + 1 |
[+(x1, x2)] |
=
|
0 |
[sum#(x1)] |
=
|
x1 + 0 |
[+#(x1, x2)] |
=
|
0 |
[*(x1, x2)] |
=
|
0 |
having no usable rules (w.r.t. the implicit argument filter of the
reduction pair),
the
pair
sum#(cons(x,l)) |
→ |
sum#(l) |
(20) |
could be deleted.
1.1.1.1 Dependency Graph Processor
The dependency pairs are split into 0
components.
-
The
2nd
component contains the
pair
prod#(cons(x,l)) |
→ |
prod#(l) |
(28) |
1.1.2 Reduction Pair Processor with Usable Rules
Using the Max-polynomial interpretation
[0#(x1)] |
=
|
0 |
[1(x1)] |
=
|
0 |
[prod(x1)] |
=
|
0 |
[prod#(x1)] |
=
|
x1 + 0 |
[*#(x1, x2)] |
=
|
0 |
[#] |
=
|
0 |
[sum(x1)] |
=
|
0 |
[0(x1)] |
=
|
0 |
[nil] |
=
|
0 |
[cons(x1, x2)] |
=
|
x2 + 1 |
[+(x1, x2)] |
=
|
0 |
[sum#(x1)] |
=
|
0 |
[+#(x1, x2)] |
=
|
0 |
[*(x1, x2)] |
=
|
0 |
having no usable rules (w.r.t. the implicit argument filter of the
reduction pair),
the
pair
prod#(cons(x,l)) |
→ |
prod#(l) |
(28) |
could be deleted.
1.1.2.1 Dependency Graph Processor
The dependency pairs are split into 0
components.
-
The
3rd
component contains the
pair
*#(0(x),y) |
→ |
*#(x,y) |
(23) |
*#(*(x,y),z) |
→ |
*#(x,*(y,z)) |
(18) |
*#(1(x),y) |
→ |
*#(x,y) |
(27) |
*#(*(x,y),z) |
→ |
*#(y,z) |
(25) |
1.1.3 Reduction Pair Processor with Usable Rules
Using the Max-polynomial interpretation
[0#(x1)] |
=
|
0 |
[1(x1)] |
=
|
x1 + 2 |
[prod(x1)] |
=
|
0 |
[prod#(x1)] |
=
|
0 |
[*#(x1, x2)] |
=
|
x1 + 0 |
[#] |
=
|
1 |
[sum(x1)] |
=
|
0 |
[0(x1)] |
=
|
x1 + 1 |
[nil] |
=
|
0 |
[cons(x1, x2)] |
=
|
1 |
[+(x1, x2)] |
=
|
x2 + 4 |
[sum#(x1)] |
=
|
0 |
[+#(x1, x2)] |
=
|
0 |
[*(x1, x2)] |
=
|
x1 + x2 + 1 |
having no usable rules (w.r.t. the implicit argument filter of the
reduction pair),
the
pairs
*#(0(x),y) |
→ |
*#(x,y) |
(23) |
*#(*(x,y),z) |
→ |
*#(x,*(y,z)) |
(18) |
*#(1(x),y) |
→ |
*#(x,y) |
(27) |
*#(*(x,y),z) |
→ |
*#(y,z) |
(25) |
could be deleted.
1.1.3.1 Dependency Graph Processor
The dependency pairs are split into 0
components.
-
The
4th
component contains the
pair
+#(+(x,y),z) |
→ |
+#(x,+(y,z)) |
(37) |
+#(0(x),1(y)) |
→ |
+#(x,y) |
(35) |
+#(1(x),1(y)) |
→ |
+#(x,y) |
(22) |
+#(1(x),0(y)) |
→ |
+#(x,y) |
(33) |
+#(0(x),0(y)) |
→ |
+#(x,y) |
(30) |
+#(1(x),1(y)) |
→ |
+#(+(x,y),1(#)) |
(21) |
+#(+(x,y),z) |
→ |
+#(y,z) |
(29) |
1.1.4 Reduction Pair Processor with Usable Rules
Using the Max-polynomial interpretation
[0#(x1)] |
=
|
0 |
[1(x1)] |
=
|
x1 + 51103 |
[prod(x1)] |
=
|
0 |
[prod#(x1)] |
=
|
0 |
[*#(x1, x2)] |
=
|
0 |
[#] |
=
|
1 |
[sum(x1)] |
=
|
0 |
[0(x1)] |
=
|
x1 + 18816 |
[nil] |
=
|
0 |
[cons(x1, x2)] |
=
|
1 |
[+(x1, x2)] |
=
|
x1 + x2 + 32286 |
[sum#(x1)] |
=
|
0 |
[+#(x1, x2)] |
=
|
x1 + x2 + 0 |
[*(x1, x2)] |
=
|
0 |
together with the usable
rules
+(0(x),0(y)) |
→ |
0(+(x,y)) |
(4) |
+(+(x,y),z) |
→ |
+(x,+(y,z)) |
(8) |
0(#) |
→ |
# |
(1) |
+(#,x) |
→ |
x |
(3) |
+(0(x),1(y)) |
→ |
1(+(x,y)) |
(5) |
+(1(x),1(y)) |
→ |
0(+(+(x,y),1(#))) |
(7) |
+(1(x),0(y)) |
→ |
1(+(x,y)) |
(6) |
+(x,#) |
→ |
x |
(2) |
(w.r.t. the implicit argument filter of the reduction pair),
the
pairs
+#(0(x),1(y)) |
→ |
+#(x,y) |
(35) |
+#(1(x),1(y)) |
→ |
+#(x,y) |
(22) |
+#(1(x),0(y)) |
→ |
+#(x,y) |
(33) |
+#(0(x),0(y)) |
→ |
+#(x,y) |
(30) |
+#(1(x),1(y)) |
→ |
+#(+(x,y),1(#)) |
(21) |
+#(+(x,y),z) |
→ |
+#(y,z) |
(29) |
could be deleted.
1.1.4.1 Dependency Graph Processor
The dependency pairs are split into 1
component.