R
↳Dependency Pair Analysis
EQ(s(X), s(Y)) -> EQ(X, Y)
LE(s(X), s(Y)) -> LE(X, Y)
MIN(cons(N, cons(M, L))) -> IFMIN(le(N, M), cons(N, cons(M, L)))
MIN(cons(N, cons(M, L))) -> LE(N, M)
IFMIN(true, cons(N, cons(M, L))) -> MIN(cons(N, L))
IFMIN(false, cons(N, cons(M, L))) -> MIN(cons(M, L))
REPLACE(N, M, cons(K, L)) -> IFREPL(eq(N, K), N, M, cons(K, L))
REPLACE(N, M, cons(K, L)) -> EQ(N, K)
IFREPL(false, N, M, cons(K, L)) -> REPLACE(N, M, L)
SELSORT(cons(N, L)) -> IFSELSORT(eq(N, min(cons(N, L))), cons(N, L))
SELSORT(cons(N, L)) -> EQ(N, min(cons(N, L)))
SELSORT(cons(N, L)) -> MIN(cons(N, L))
IFSELSORT(true, cons(N, L)) -> SELSORT(L)
IFSELSORT(false, cons(N, L)) -> MIN(cons(N, L))
IFSELSORT(false, cons(N, L)) -> SELSORT(replace(min(cons(N, L)), N, L))
IFSELSORT(false, cons(N, L)) -> REPLACE(min(cons(N, L)), N, L)
R
↳DPs
→DP Problem 1
↳Argument Filtering and Ordering
→DP Problem 2
↳AFS
→DP Problem 3
↳Nar
→DP Problem 4
↳Remaining
→DP Problem 5
↳Remaining
EQ(s(X), s(Y)) -> EQ(X, Y)
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
EQ(s(X), s(Y)) -> EQ(X, Y)
EQ(x1, x2) -> EQ(x1, x2)
s(x1) -> s(x1)
R
↳DPs
→DP Problem 1
↳AFS
→DP Problem 6
↳Dependency Graph
→DP Problem 2
↳AFS
→DP Problem 3
↳Nar
→DP Problem 4
↳Remaining
→DP Problem 5
↳Remaining
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
R
↳DPs
→DP Problem 1
↳AFS
→DP Problem 2
↳Argument Filtering and Ordering
→DP Problem 3
↳Nar
→DP Problem 4
↳Remaining
→DP Problem 5
↳Remaining
LE(s(X), s(Y)) -> LE(X, Y)
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
LE(s(X), s(Y)) -> LE(X, Y)
LE(x1, x2) -> LE(x1, x2)
s(x1) -> s(x1)
R
↳DPs
→DP Problem 1
↳AFS
→DP Problem 2
↳AFS
→DP Problem 7
↳Dependency Graph
→DP Problem 3
↳Nar
→DP Problem 4
↳Remaining
→DP Problem 5
↳Remaining
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
R
↳DPs
→DP Problem 1
↳AFS
→DP Problem 2
↳AFS
→DP Problem 3
↳Narrowing Transformation
→DP Problem 4
↳Remaining
→DP Problem 5
↳Remaining
IFREPL(false, N, M, cons(K, L)) -> REPLACE(N, M, L)
REPLACE(N, M, cons(K, L)) -> IFREPL(eq(N, K), N, M, cons(K, L))
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
four new Dependency Pairs are created:
REPLACE(N, M, cons(K, L)) -> IFREPL(eq(N, K), N, M, cons(K, L))
REPLACE(0, M, cons(0, L)) -> IFREPL(true, 0, M, cons(0, L))
REPLACE(0, M, cons(s(Y'), L)) -> IFREPL(false, 0, M, cons(s(Y'), L))
REPLACE(s(X'), M, cons(0, L)) -> IFREPL(false, s(X'), M, cons(0, L))
REPLACE(s(X'), M, cons(s(Y'), L)) -> IFREPL(eq(X', Y'), s(X'), M, cons(s(Y'), L))
R
↳DPs
→DP Problem 1
↳AFS
→DP Problem 2
↳AFS
→DP Problem 3
↳Nar
→DP Problem 8
↳Instantiation Transformation
→DP Problem 4
↳Remaining
→DP Problem 5
↳Remaining
REPLACE(s(X'), M, cons(s(Y'), L)) -> IFREPL(eq(X', Y'), s(X'), M, cons(s(Y'), L))
REPLACE(s(X'), M, cons(0, L)) -> IFREPL(false, s(X'), M, cons(0, L))
REPLACE(0, M, cons(s(Y'), L)) -> IFREPL(false, 0, M, cons(s(Y'), L))
IFREPL(false, N, M, cons(K, L)) -> REPLACE(N, M, L)
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
three new Dependency Pairs are created:
IFREPL(false, N, M, cons(K, L)) -> REPLACE(N, M, L)
IFREPL(false, 0, M'', cons(s(Y'''), L'')) -> REPLACE(0, M'', L'')
IFREPL(false, s(X'''), M'', cons(0, L'')) -> REPLACE(s(X'''), M'', L'')
IFREPL(false, s(X'''), M'', cons(s(Y'''), L'')) -> REPLACE(s(X'''), M'', L'')
R
↳DPs
→DP Problem 1
↳AFS
→DP Problem 2
↳AFS
→DP Problem 3
↳Nar
→DP Problem 4
↳Remaining Obligation(s)
→DP Problem 5
↳Remaining Obligation(s)
IFREPL(false, s(X'''), M'', cons(0, L'')) -> REPLACE(s(X'''), M'', L'')
REPLACE(s(X'), M, cons(0, L)) -> IFREPL(false, s(X'), M, cons(0, L))
IFREPL(false, s(X'''), M'', cons(s(Y'''), L'')) -> REPLACE(s(X'''), M'', L'')
REPLACE(s(X'), M, cons(s(Y'), L)) -> IFREPL(eq(X', Y'), s(X'), M, cons(s(Y'), L))
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
IFMIN(false, cons(N, cons(M, L))) -> MIN(cons(M, L))
IFMIN(true, cons(N, cons(M, L))) -> MIN(cons(N, L))
MIN(cons(N, cons(M, L))) -> IFMIN(le(N, M), cons(N, cons(M, L)))
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
IFSELSORT(false, cons(N, L)) -> SELSORT(replace(min(cons(N, L)), N, L))
IFSELSORT(true, cons(N, L)) -> SELSORT(L)
SELSORT(cons(N, L)) -> IFSELSORT(eq(N, min(cons(N, L))), cons(N, L))
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
R
↳DPs
→DP Problem 1
↳AFS
→DP Problem 2
↳AFS
→DP Problem 3
↳Nar
→DP Problem 8
↳Inst
...
→DP Problem 10
↳Argument Filtering and Ordering
→DP Problem 4
↳Remaining
→DP Problem 5
↳Remaining
IFREPL(false, 0, M'', cons(s(Y'''), L'')) -> REPLACE(0, M'', L'')
REPLACE(0, M, cons(s(Y'), L)) -> IFREPL(false, 0, M, cons(s(Y'), L))
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
IFREPL(false, 0, M'', cons(s(Y'''), L'')) -> REPLACE(0, M'', L'')
REPLACE(x1, x2, x3) -> x3
cons(x1, x2) -> cons(x1, x2)
IFREPL(x1, x2, x3, x4) -> x4
s(x1) -> s(x1)
R
↳DPs
→DP Problem 1
↳AFS
→DP Problem 2
↳AFS
→DP Problem 3
↳Nar
→DP Problem 8
↳Inst
...
→DP Problem 11
↳Dependency Graph
→DP Problem 4
↳Remaining
→DP Problem 5
↳Remaining
REPLACE(0, M, cons(s(Y'), L)) -> IFREPL(false, 0, M, cons(s(Y'), L))
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
R
↳DPs
→DP Problem 1
↳AFS
→DP Problem 2
↳AFS
→DP Problem 3
↳Nar
→DP Problem 4
↳Remaining Obligation(s)
→DP Problem 5
↳Remaining Obligation(s)
IFREPL(false, s(X'''), M'', cons(0, L'')) -> REPLACE(s(X'''), M'', L'')
REPLACE(s(X'), M, cons(0, L)) -> IFREPL(false, s(X'), M, cons(0, L))
IFREPL(false, s(X'''), M'', cons(s(Y'''), L'')) -> REPLACE(s(X'''), M'', L'')
REPLACE(s(X'), M, cons(s(Y'), L)) -> IFREPL(eq(X', Y'), s(X'), M, cons(s(Y'), L))
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
IFMIN(false, cons(N, cons(M, L))) -> MIN(cons(M, L))
IFMIN(true, cons(N, cons(M, L))) -> MIN(cons(N, L))
MIN(cons(N, cons(M, L))) -> IFMIN(le(N, M), cons(N, cons(M, L)))
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
IFSELSORT(false, cons(N, L)) -> SELSORT(replace(min(cons(N, L)), N, L))
IFSELSORT(true, cons(N, L)) -> SELSORT(L)
SELSORT(cons(N, L)) -> IFSELSORT(eq(N, min(cons(N, L))), cons(N, L))
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
R
↳DPs
→DP Problem 1
↳AFS
→DP Problem 2
↳AFS
→DP Problem 3
↳Nar
→DP Problem 4
↳Remaining Obligation(s)
→DP Problem 5
↳Remaining Obligation(s)
IFREPL(false, s(X'''), M'', cons(0, L'')) -> REPLACE(s(X'''), M'', L'')
REPLACE(s(X'), M, cons(0, L)) -> IFREPL(false, s(X'), M, cons(0, L))
IFREPL(false, s(X'''), M'', cons(s(Y'''), L'')) -> REPLACE(s(X'''), M'', L'')
REPLACE(s(X'), M, cons(s(Y'), L)) -> IFREPL(eq(X', Y'), s(X'), M, cons(s(Y'), L))
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
IFMIN(false, cons(N, cons(M, L))) -> MIN(cons(M, L))
IFMIN(true, cons(N, cons(M, L))) -> MIN(cons(N, L))
MIN(cons(N, cons(M, L))) -> IFMIN(le(N, M), cons(N, cons(M, L)))
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost
IFSELSORT(false, cons(N, L)) -> SELSORT(replace(min(cons(N, L)), N, L))
IFSELSORT(true, cons(N, L)) -> SELSORT(L)
SELSORT(cons(N, L)) -> IFSELSORT(eq(N, min(cons(N, L))), cons(N, L))
eq(0, 0) -> true
eq(0, s(Y)) -> false
eq(s(X), 0) -> false
eq(s(X), s(Y)) -> eq(X, Y)
le(0, Y) -> true
le(s(X), 0) -> false
le(s(X), s(Y)) -> le(X, Y)
min(cons(0, nil)) -> 0
min(cons(s(N), nil)) -> s(N)
min(cons(N, cons(M, L))) -> ifmin(le(N, M), cons(N, cons(M, L)))
ifmin(true, cons(N, cons(M, L))) -> min(cons(N, L))
ifmin(false, cons(N, cons(M, L))) -> min(cons(M, L))
replace(N, M, nil) -> nil
replace(N, M, cons(K, L)) -> ifrepl(eq(N, K), N, M, cons(K, L))
ifrepl(true, N, M, cons(K, L)) -> cons(M, L)
ifrepl(false, N, M, cons(K, L)) -> cons(K, replace(N, M, L))
selsort(nil) -> nil
selsort(cons(N, L)) -> ifselsort(eq(N, min(cons(N, L))), cons(N, L))
ifselsort(true, cons(N, L)) -> cons(N, selsort(L))
ifselsort(false, cons(N, L)) -> cons(min(cons(N, L)), selsort(replace(min(cons(N, L)), N, L)))
innermost