(0) Obligation:
Q restricted rewrite system:
The TRS R consists of the following rules:
app(app(apply, f_1), x) → app(f_1, x)
app(id, x) → x
app(app(app(uncurry, f_2), x), y) → app(app(f_2, x), y)
app(app(app(swap, f_2), y), x) → app(app(f_2, x), y)
app(app(app(compose, g_1), f_1), x) → app(g_1, app(f_1, x))
app(app(const, x), y) → x
app(listify, x) → app(app(cons, x), nil)
app(app(app(app(fold, f_3), g_2), x), nil) → x
app(app(app(app(fold, f_3), g_2), x), app(app(cons, z), t)) → app(app(f_3, app(g_2, z)), app(app(app(app(fold, f_3), g_2), x), t))
app(sum, l) → app(app(app(app(fold, add), id), 0), l)
app(app(uncurry, app(app(fold, cons), id)), nil) → id
append → app(app(compose, app(app(swap, fold), cons)), id)
reverse → app(app(uncurry, app(app(fold, app(swap, append)), listify)), nil)
length → app(app(uncurry, app(app(fold, add), app(cons, 1))), 0)
Q is empty.
(1) DependencyPairsProof (EQUIVALENT transformation)
Using Dependency Pairs [AG00,LPAR04] we result in the following initial DP problem.
(2) Obligation:
Q DP problem:
The TRS P consists of the following rules:
APP(app(apply, f_1), x) → APP(f_1, x)
APP(app(app(uncurry, f_2), x), y) → APP(app(f_2, x), y)
APP(app(app(uncurry, f_2), x), y) → APP(f_2, x)
APP(app(app(swap, f_2), y), x) → APP(app(f_2, x), y)
APP(app(app(swap, f_2), y), x) → APP(f_2, x)
APP(app(app(compose, g_1), f_1), x) → APP(g_1, app(f_1, x))
APP(app(app(compose, g_1), f_1), x) → APP(f_1, x)
APP(listify, x) → APP(app(cons, x), nil)
APP(listify, x) → APP(cons, x)
APP(app(app(app(fold, f_3), g_2), x), app(app(cons, z), t)) → APP(app(f_3, app(g_2, z)), app(app(app(app(fold, f_3), g_2), x), t))
APP(app(app(app(fold, f_3), g_2), x), app(app(cons, z), t)) → APP(f_3, app(g_2, z))
APP(app(app(app(fold, f_3), g_2), x), app(app(cons, z), t)) → APP(g_2, z)
APP(app(app(app(fold, f_3), g_2), x), app(app(cons, z), t)) → APP(app(app(app(fold, f_3), g_2), x), t)
APP(sum, l) → APP(app(app(app(fold, add), id), 0), l)
APP(sum, l) → APP(app(app(fold, add), id), 0)
APP(sum, l) → APP(app(fold, add), id)
APP(sum, l) → APP(fold, add)
APPEND → APP(app(compose, app(app(swap, fold), cons)), id)
APPEND → APP(compose, app(app(swap, fold), cons))
APPEND → APP(app(swap, fold), cons)
APPEND → APP(swap, fold)
REVERSE → APP(app(uncurry, app(app(fold, app(swap, append)), listify)), nil)
REVERSE → APP(uncurry, app(app(fold, app(swap, append)), listify))
REVERSE → APP(app(fold, app(swap, append)), listify)
REVERSE → APP(fold, app(swap, append))
REVERSE → APP(swap, append)
REVERSE → APPEND
LENGTH → APP(app(uncurry, app(app(fold, add), app(cons, 1))), 0)
LENGTH → APP(uncurry, app(app(fold, add), app(cons, 1)))
LENGTH → APP(app(fold, add), app(cons, 1))
LENGTH → APP(fold, add)
LENGTH → APP(cons, 1)
The TRS R consists of the following rules:
app(app(apply, f_1), x) → app(f_1, x)
app(id, x) → x
app(app(app(uncurry, f_2), x), y) → app(app(f_2, x), y)
app(app(app(swap, f_2), y), x) → app(app(f_2, x), y)
app(app(app(compose, g_1), f_1), x) → app(g_1, app(f_1, x))
app(app(const, x), y) → x
app(listify, x) → app(app(cons, x), nil)
app(app(app(app(fold, f_3), g_2), x), nil) → x
app(app(app(app(fold, f_3), g_2), x), app(app(cons, z), t)) → app(app(f_3, app(g_2, z)), app(app(app(app(fold, f_3), g_2), x), t))
app(sum, l) → app(app(app(app(fold, add), id), 0), l)
app(app(uncurry, app(app(fold, cons), id)), nil) → id
append → app(app(compose, app(app(swap, fold), cons)), id)
reverse → app(app(uncurry, app(app(fold, app(swap, append)), listify)), nil)
length → app(app(uncurry, app(app(fold, add), app(cons, 1))), 0)
Q is empty.
We have to consider all minimal (P,Q,R)-chains.
(3) DependencyGraphProof (EQUIVALENT transformation)
The approximation of the Dependency Graph [LPAR04,FROCOS05,EDGSTAR] contains 1 SCC with 20 less nodes.
(4) Obligation:
Q DP problem:
The TRS P consists of the following rules:
APP(app(app(uncurry, f_2), x), y) → APP(app(f_2, x), y)
APP(app(apply, f_1), x) → APP(f_1, x)
APP(app(app(uncurry, f_2), x), y) → APP(f_2, x)
APP(app(app(swap, f_2), y), x) → APP(app(f_2, x), y)
APP(app(app(swap, f_2), y), x) → APP(f_2, x)
APP(app(app(compose, g_1), f_1), x) → APP(g_1, app(f_1, x))
APP(app(app(compose, g_1), f_1), x) → APP(f_1, x)
APP(app(app(app(fold, f_3), g_2), x), app(app(cons, z), t)) → APP(app(f_3, app(g_2, z)), app(app(app(app(fold, f_3), g_2), x), t))
APP(app(app(app(fold, f_3), g_2), x), app(app(cons, z), t)) → APP(f_3, app(g_2, z))
APP(app(app(app(fold, f_3), g_2), x), app(app(cons, z), t)) → APP(g_2, z)
APP(app(app(app(fold, f_3), g_2), x), app(app(cons, z), t)) → APP(app(app(app(fold, f_3), g_2), x), t)
APP(sum, l) → APP(app(app(app(fold, add), id), 0), l)
The TRS R consists of the following rules:
app(app(apply, f_1), x) → app(f_1, x)
app(id, x) → x
app(app(app(uncurry, f_2), x), y) → app(app(f_2, x), y)
app(app(app(swap, f_2), y), x) → app(app(f_2, x), y)
app(app(app(compose, g_1), f_1), x) → app(g_1, app(f_1, x))
app(app(const, x), y) → x
app(listify, x) → app(app(cons, x), nil)
app(app(app(app(fold, f_3), g_2), x), nil) → x
app(app(app(app(fold, f_3), g_2), x), app(app(cons, z), t)) → app(app(f_3, app(g_2, z)), app(app(app(app(fold, f_3), g_2), x), t))
app(sum, l) → app(app(app(app(fold, add), id), 0), l)
app(app(uncurry, app(app(fold, cons), id)), nil) → id
append → app(app(compose, app(app(swap, fold), cons)), id)
reverse → app(app(uncurry, app(app(fold, app(swap, append)), listify)), nil)
length → app(app(uncurry, app(app(fold, add), app(cons, 1))), 0)
Q is empty.
We have to consider all minimal (P,Q,R)-chains.