Term Rewriting System R:
[m, n, x, k]
eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))

Innermost Termination of R to be shown.



   R
Dependency Pair Analysis



R contains the following Dependency Pairs:

EQ(s(n), s(m)) -> EQ(n, m)
LE(s(n), s(m)) -> LE(n, m)
MIN(cons(n, cons(m, x))) -> IFMIN(le(n, m), cons(n, cons(m, x)))
MIN(cons(n, cons(m, x))) -> LE(n, m)
IFMIN(true, cons(n, cons(m, x))) -> MIN(cons(n, x))
IFMIN(false, cons(n, cons(m, x))) -> MIN(cons(m, x))
REPLACE(n, m, cons(k, x)) -> IFREPLACE(eq(n, k), n, m, cons(k, x))
REPLACE(n, m, cons(k, x)) -> EQ(n, k)
IFREPLACE(false, n, m, cons(k, x)) -> REPLACE(n, m, x)
SORT(cons(n, x)) -> MIN(cons(n, x))
SORT(cons(n, x)) -> SORT(replace(min(cons(n, x)), n, x))
SORT(cons(n, x)) -> REPLACE(min(cons(n, x)), n, x)

Furthermore, R contains five SCCs.


   R
DPs
       →DP Problem 1
Forward Instantiation Transformation
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pair:

EQ(s(n), s(m)) -> EQ(n, m)


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

EQ(s(n), s(m)) -> EQ(n, m)
one new Dependency Pair is created:

EQ(s(s(n'')), s(s(m''))) -> EQ(s(n''), s(m''))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
           →DP Problem 6
Forward Instantiation Transformation
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pair:

EQ(s(s(n'')), s(s(m''))) -> EQ(s(n''), s(m''))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

EQ(s(s(n'')), s(s(m''))) -> EQ(s(n''), s(m''))
one new Dependency Pair is created:

EQ(s(s(s(n''''))), s(s(s(m'''')))) -> EQ(s(s(n'''')), s(s(m'''')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
           →DP Problem 6
FwdInst
             ...
               →DP Problem 7
Polynomial Ordering
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pair:

EQ(s(s(s(n''''))), s(s(s(m'''')))) -> EQ(s(s(n'''')), s(s(m'''')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




The following dependency pair can be strictly oriented:

EQ(s(s(s(n''''))), s(s(s(m'''')))) -> EQ(s(s(n'''')), s(s(m'''')))


There are no usable rules for innermost w.r.t. to the implicit AFS that need to be oriented.

Used ordering: Polynomial ordering with Polynomial interpretation:
  POL(EQ(x1, x2))=  1 + x1  
  POL(s(x1))=  1 + x1  

resulting in one new DP problem.



   R
DPs
       →DP Problem 1
FwdInst
           →DP Problem 6
FwdInst
             ...
               →DP Problem 8
Dependency Graph
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pair:


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




Using the Dependency Graph resulted in no new DP problems.


   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
Forward Instantiation Transformation
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pair:

LE(s(n), s(m)) -> LE(n, m)


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

LE(s(n), s(m)) -> LE(n, m)
one new Dependency Pair is created:

LE(s(s(n'')), s(s(m''))) -> LE(s(n''), s(m''))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
           →DP Problem 9
Forward Instantiation Transformation
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pair:

LE(s(s(n'')), s(s(m''))) -> LE(s(n''), s(m''))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

LE(s(s(n'')), s(s(m''))) -> LE(s(n''), s(m''))
one new Dependency Pair is created:

LE(s(s(s(n''''))), s(s(s(m'''')))) -> LE(s(s(n'''')), s(s(m'''')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
           →DP Problem 9
FwdInst
             ...
               →DP Problem 10
Polynomial Ordering
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pair:

LE(s(s(s(n''''))), s(s(s(m'''')))) -> LE(s(s(n'''')), s(s(m'''')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




The following dependency pair can be strictly oriented:

LE(s(s(s(n''''))), s(s(s(m'''')))) -> LE(s(s(n'''')), s(s(m'''')))


There are no usable rules for innermost w.r.t. to the implicit AFS that need to be oriented.

Used ordering: Polynomial ordering with Polynomial interpretation:
  POL(LE(x1, x2))=  1 + x1  
  POL(s(x1))=  1 + x1  

resulting in one new DP problem.



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
           →DP Problem 9
FwdInst
             ...
               →DP Problem 11
Dependency Graph
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pair:


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




Using the Dependency Graph resulted in no new DP problems.


   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Narrowing Transformation
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

IFREPLACE(false, n, m, cons(k, x)) -> REPLACE(n, m, x)
REPLACE(n, m, cons(k, x)) -> IFREPLACE(eq(n, k), n, m, cons(k, x))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Narrowing SCC transformation can be performed.
As a result of transforming the rule

REPLACE(n, m, cons(k, x)) -> IFREPLACE(eq(n, k), n, m, cons(k, x))
four new Dependency Pairs are created:

REPLACE(0, m, cons(0, x)) -> IFREPLACE(true, 0, m, cons(0, x))
REPLACE(0, m, cons(s(m''), x)) -> IFREPLACE(false, 0, m, cons(s(m''), x))
REPLACE(s(n''), m, cons(0, x)) -> IFREPLACE(false, s(n''), m, cons(0, x))
REPLACE(s(n''), m, cons(s(m''), x)) -> IFREPLACE(eq(n'', m''), s(n''), m, cons(s(m''), x))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Narrowing Transformation
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

REPLACE(s(n''), m, cons(s(m''), x)) -> IFREPLACE(eq(n'', m''), s(n''), m, cons(s(m''), x))
REPLACE(s(n''), m, cons(0, x)) -> IFREPLACE(false, s(n''), m, cons(0, x))
REPLACE(0, m, cons(s(m''), x)) -> IFREPLACE(false, 0, m, cons(s(m''), x))
IFREPLACE(false, n, m, cons(k, x)) -> REPLACE(n, m, x)


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Narrowing SCC transformation can be performed.
As a result of transforming the rule

REPLACE(s(n''), m, cons(s(m''), x)) -> IFREPLACE(eq(n'', m''), s(n''), m, cons(s(m''), x))
four new Dependency Pairs are created:

REPLACE(s(0), m, cons(s(0), x)) -> IFREPLACE(true, s(0), m, cons(s(0), x))
REPLACE(s(0), m, cons(s(s(m''')), x)) -> IFREPLACE(false, s(0), m, cons(s(s(m''')), x))
REPLACE(s(s(n')), m, cons(s(0), x)) -> IFREPLACE(false, s(s(n')), m, cons(s(0), x))
REPLACE(s(s(n')), m, cons(s(s(m''')), x)) -> IFREPLACE(eq(n', m'''), s(s(n')), m, cons(s(s(m''')), x))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 13
Instantiation Transformation
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

REPLACE(s(s(n')), m, cons(s(s(m''')), x)) -> IFREPLACE(eq(n', m'''), s(s(n')), m, cons(s(s(m''')), x))
REPLACE(s(s(n')), m, cons(s(0), x)) -> IFREPLACE(false, s(s(n')), m, cons(s(0), x))
REPLACE(s(0), m, cons(s(s(m''')), x)) -> IFREPLACE(false, s(0), m, cons(s(s(m''')), x))
REPLACE(0, m, cons(s(m''), x)) -> IFREPLACE(false, 0, m, cons(s(m''), x))
IFREPLACE(false, n, m, cons(k, x)) -> REPLACE(n, m, x)
REPLACE(s(n''), m, cons(0, x)) -> IFREPLACE(false, s(n''), m, cons(0, x))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, an Instantiation SCC transformation can be performed.
As a result of transforming the rule

IFREPLACE(false, n, m, cons(k, x)) -> REPLACE(n, m, x)
five new Dependency Pairs are created:

IFREPLACE(false, 0, m'', cons(s(m''''), x'')) -> REPLACE(0, m'', x'')
IFREPLACE(false, s(n''''), m'', cons(0, x'')) -> REPLACE(s(n''''), m'', x'')
IFREPLACE(false, s(0), m'', cons(s(s(m''''')), x'')) -> REPLACE(s(0), m'', x'')
IFREPLACE(false, s(s(n''')), m'', cons(s(0), x'')) -> REPLACE(s(s(n''')), m'', x'')
IFREPLACE(false, s(s(n''')), m'', cons(s(s(m''''')), x')) -> REPLACE(s(s(n''')), m'', x')

The transformation is resulting in two new DP problems:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 14
Forward Instantiation Transformation
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

IFREPLACE(false, s(s(n''')), m'', cons(s(0), x'')) -> REPLACE(s(s(n''')), m'', x'')
REPLACE(s(s(n')), m, cons(s(0), x)) -> IFREPLACE(false, s(s(n')), m, cons(s(0), x))
IFREPLACE(false, s(0), m'', cons(s(s(m''''')), x'')) -> REPLACE(s(0), m'', x'')
REPLACE(s(0), m, cons(s(s(m''')), x)) -> IFREPLACE(false, s(0), m, cons(s(s(m''')), x))
IFREPLACE(false, s(n''''), m'', cons(0, x'')) -> REPLACE(s(n''''), m'', x'')
REPLACE(s(n''), m, cons(0, x)) -> IFREPLACE(false, s(n''), m, cons(0, x))
IFREPLACE(false, s(s(n''')), m'', cons(s(s(m''''')), x')) -> REPLACE(s(s(n''')), m'', x')
REPLACE(s(s(n')), m, cons(s(s(m''')), x)) -> IFREPLACE(eq(n', m'''), s(s(n')), m, cons(s(s(m''')), x))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

IFREPLACE(false, s(n''''), m'', cons(0, x'')) -> REPLACE(s(n''''), m'', x'')
four new Dependency Pairs are created:

IFREPLACE(false, s(n'''''), m''', cons(0, cons(0, x'''))) -> REPLACE(s(n'''''), m''', cons(0, x'''))
IFREPLACE(false, s(0), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(0), m''', cons(s(s(m''''')), x'''))
IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(0), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(0), x'''))
IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(s(m''''')), x'''))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 16
Forward Instantiation Transformation
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

IFREPLACE(false, s(s(n''')), m'', cons(s(s(m''''')), x')) -> REPLACE(s(s(n''')), m'', x')
REPLACE(s(s(n')), m, cons(s(s(m''')), x)) -> IFREPLACE(eq(n', m'''), s(s(n')), m, cons(s(s(m''')), x))
IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(s(m''''')), x'''))
REPLACE(s(s(n')), m, cons(s(0), x)) -> IFREPLACE(false, s(s(n')), m, cons(s(0), x))
IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(0), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(0), x'''))
IFREPLACE(false, s(0), m'', cons(s(s(m''''')), x'')) -> REPLACE(s(0), m'', x'')
REPLACE(s(0), m, cons(s(s(m''')), x)) -> IFREPLACE(false, s(0), m, cons(s(s(m''')), x))
IFREPLACE(false, s(0), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(0), m''', cons(s(s(m''''')), x'''))
IFREPLACE(false, s(n'''''), m''', cons(0, cons(0, x'''))) -> REPLACE(s(n'''''), m''', cons(0, x'''))
REPLACE(s(n''), m, cons(0, x)) -> IFREPLACE(false, s(n''), m, cons(0, x))
IFREPLACE(false, s(s(n''')), m'', cons(s(0), x'')) -> REPLACE(s(s(n''')), m'', x'')


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

REPLACE(s(n''), m, cons(0, x)) -> IFREPLACE(false, s(n''), m, cons(0, x))
four new Dependency Pairs are created:

REPLACE(s(n'''), m', cons(0, cons(0, x'''''))) -> IFREPLACE(false, s(n'''), m', cons(0, cons(0, x''''')))
REPLACE(s(0), m', cons(0, cons(s(s(m''''''')), x'''''))) -> IFREPLACE(false, s(0), m', cons(0, cons(s(s(m''''''')), x''''')))
REPLACE(s(s(n''''')), m', cons(0, cons(s(0), x'''''))) -> IFREPLACE(false, s(s(n''''')), m', cons(0, cons(s(0), x''''')))
REPLACE(s(s(n''''')), m', cons(0, cons(s(s(m''''''')), x'''''))) -> IFREPLACE(false, s(s(n''''')), m', cons(0, cons(s(s(m''''''')), x''''')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 18
Forward Instantiation Transformation
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(s(m''''')), x'''))
REPLACE(s(s(n''''')), m', cons(0, cons(s(s(m''''''')), x'''''))) -> IFREPLACE(false, s(s(n''''')), m', cons(0, cons(s(s(m''''''')), x''''')))
IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(0), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(0), x'''))
REPLACE(s(s(n''''')), m', cons(0, cons(s(0), x'''''))) -> IFREPLACE(false, s(s(n''''')), m', cons(0, cons(s(0), x''''')))
IFREPLACE(false, s(0), m'', cons(s(s(m''''')), x'')) -> REPLACE(s(0), m'', x'')
REPLACE(s(0), m, cons(s(s(m''')), x)) -> IFREPLACE(false, s(0), m, cons(s(s(m''')), x))
IFREPLACE(false, s(0), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(0), m''', cons(s(s(m''''')), x'''))
REPLACE(s(0), m', cons(0, cons(s(s(m''''''')), x'''''))) -> IFREPLACE(false, s(0), m', cons(0, cons(s(s(m''''''')), x''''')))
IFREPLACE(false, s(n'''''), m''', cons(0, cons(0, x'''))) -> REPLACE(s(n'''''), m''', cons(0, x'''))
REPLACE(s(n'''), m', cons(0, cons(0, x'''''))) -> IFREPLACE(false, s(n'''), m', cons(0, cons(0, x''''')))
REPLACE(s(s(n')), m, cons(s(s(m''')), x)) -> IFREPLACE(eq(n', m'''), s(s(n')), m, cons(s(s(m''')), x))
IFREPLACE(false, s(s(n''')), m'', cons(s(0), x'')) -> REPLACE(s(s(n''')), m'', x'')
REPLACE(s(s(n')), m, cons(s(0), x)) -> IFREPLACE(false, s(s(n')), m, cons(s(0), x))
IFREPLACE(false, s(s(n''')), m'', cons(s(s(m''''')), x')) -> REPLACE(s(s(n''')), m'', x')


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

IFREPLACE(false, s(0), m'', cons(s(s(m''''')), x'')) -> REPLACE(s(0), m'', x'')
three new Dependency Pairs are created:

IFREPLACE(false, s(0), m''', cons(s(s(m''''')), cons(s(s(m''''')), x'''))) -> REPLACE(s(0), m''', cons(s(s(m''''')), x'''))
IFREPLACE(false, s(0), m'''', cons(s(s(m''''')), cons(0, cons(0, x''''''')))) -> REPLACE(s(0), m'''', cons(0, cons(0, x''''''')))
IFREPLACE(false, s(0), m'''', cons(s(s(m''''')), cons(0, cons(s(s(m''''''''')), x''''''')))) -> REPLACE(s(0), m'''', cons(0, cons(s(s(m''''''''')), x''''''')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 20
Forward Instantiation Transformation
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

REPLACE(s(s(n''''')), m', cons(0, cons(s(s(m''''''')), x'''''))) -> IFREPLACE(false, s(s(n''''')), m', cons(0, cons(s(s(m''''''')), x''''')))
IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(0), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(0), x'''))
REPLACE(s(s(n''''')), m', cons(0, cons(s(0), x'''''))) -> IFREPLACE(false, s(s(n''''')), m', cons(0, cons(s(0), x''''')))
IFREPLACE(false, s(0), m'''', cons(s(s(m''''')), cons(0, cons(s(s(m''''''''')), x''''''')))) -> REPLACE(s(0), m'''', cons(0, cons(s(s(m''''''''')), x''''''')))
IFREPLACE(false, s(0), m'''', cons(s(s(m''''')), cons(0, cons(0, x''''''')))) -> REPLACE(s(0), m'''', cons(0, cons(0, x''''''')))
IFREPLACE(false, s(0), m''', cons(s(s(m''''')), cons(s(s(m''''')), x'''))) -> REPLACE(s(0), m''', cons(s(s(m''''')), x'''))
REPLACE(s(0), m, cons(s(s(m''')), x)) -> IFREPLACE(false, s(0), m, cons(s(s(m''')), x))
IFREPLACE(false, s(0), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(0), m''', cons(s(s(m''''')), x'''))
REPLACE(s(0), m', cons(0, cons(s(s(m''''''')), x'''''))) -> IFREPLACE(false, s(0), m', cons(0, cons(s(s(m''''''')), x''''')))
IFREPLACE(false, s(n'''''), m''', cons(0, cons(0, x'''))) -> REPLACE(s(n'''''), m''', cons(0, x'''))
REPLACE(s(n'''), m', cons(0, cons(0, x'''''))) -> IFREPLACE(false, s(n'''), m', cons(0, cons(0, x''''')))
IFREPLACE(false, s(s(n''')), m'', cons(s(0), x'')) -> REPLACE(s(s(n''')), m'', x'')
REPLACE(s(s(n')), m, cons(s(0), x)) -> IFREPLACE(false, s(s(n')), m, cons(s(0), x))
IFREPLACE(false, s(s(n''')), m'', cons(s(s(m''''')), x')) -> REPLACE(s(s(n''')), m'', x')
REPLACE(s(s(n')), m, cons(s(s(m''')), x)) -> IFREPLACE(eq(n', m'''), s(s(n')), m, cons(s(s(m''')), x))
IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(s(m''''')), x'''))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

IFREPLACE(false, s(s(n''')), m'', cons(s(0), x'')) -> REPLACE(s(s(n''')), m'', x'')
five new Dependency Pairs are created:

IFREPLACE(false, s(s(n'''')), m''', cons(s(0), cons(s(0), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(0), x'''))
IFREPLACE(false, s(s(n'''')), m''', cons(s(0), cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(s(m''''')), x'''))
IFREPLACE(false, s(s(n''''')), m'''', cons(s(0), cons(0, cons(0, x''''''')))) -> REPLACE(s(s(n''''')), m'''', cons(0, cons(0, x''''''')))
IFREPLACE(false, s(s(n'''')), m'''', cons(s(0), cons(0, cons(s(0), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(0), x''''''')))
IFREPLACE(false, s(s(n'''')), m'''', cons(s(0), cons(0, cons(s(s(m''''''''')), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(s(m''''''''')), x''''''')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 21
Forward Instantiation Transformation
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

IFREPLACE(false, s(s(n'''')), m'''', cons(s(0), cons(0, cons(s(s(m''''''''')), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(s(m''''''''')), x''''''')))
IFREPLACE(false, s(s(n'''')), m'''', cons(s(0), cons(0, cons(s(0), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(0), x''''''')))
IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(0), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(0), x'''))
REPLACE(s(s(n''''')), m', cons(0, cons(s(0), x'''''))) -> IFREPLACE(false, s(s(n''''')), m', cons(0, cons(s(0), x''''')))
IFREPLACE(false, s(0), m'''', cons(s(s(m''''')), cons(0, cons(s(s(m''''''''')), x''''''')))) -> REPLACE(s(0), m'''', cons(0, cons(s(s(m''''''''')), x''''''')))
IFREPLACE(false, s(0), m'''', cons(s(s(m''''')), cons(0, cons(0, x''''''')))) -> REPLACE(s(0), m'''', cons(0, cons(0, x''''''')))
IFREPLACE(false, s(0), m''', cons(s(s(m''''')), cons(s(s(m''''')), x'''))) -> REPLACE(s(0), m''', cons(s(s(m''''')), x'''))
REPLACE(s(0), m, cons(s(s(m''')), x)) -> IFREPLACE(false, s(0), m, cons(s(s(m''')), x))
IFREPLACE(false, s(0), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(0), m''', cons(s(s(m''''')), x'''))
REPLACE(s(0), m', cons(0, cons(s(s(m''''''')), x'''''))) -> IFREPLACE(false, s(0), m', cons(0, cons(s(s(m''''''')), x''''')))
IFREPLACE(false, s(n'''''), m''', cons(0, cons(0, x'''))) -> REPLACE(s(n'''''), m''', cons(0, x'''))
REPLACE(s(n'''), m', cons(0, cons(0, x'''''))) -> IFREPLACE(false, s(n'''), m', cons(0, cons(0, x''''')))
IFREPLACE(false, s(s(n''''')), m'''', cons(s(0), cons(0, cons(0, x''''''')))) -> REPLACE(s(s(n''''')), m'''', cons(0, cons(0, x''''''')))
IFREPLACE(false, s(s(n'''')), m''', cons(s(0), cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(s(m''''')), x'''))
IFREPLACE(false, s(s(n'''')), m''', cons(s(0), cons(s(0), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(0), x'''))
REPLACE(s(s(n')), m, cons(s(0), x)) -> IFREPLACE(false, s(s(n')), m, cons(s(0), x))
IFREPLACE(false, s(s(n''')), m'', cons(s(s(m''''')), x')) -> REPLACE(s(s(n''')), m'', x')
REPLACE(s(s(n')), m, cons(s(s(m''')), x)) -> IFREPLACE(eq(n', m'''), s(s(n')), m, cons(s(s(m''')), x))
IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(s(m''''')), x'''))
REPLACE(s(s(n''''')), m', cons(0, cons(s(s(m''''''')), x'''''))) -> IFREPLACE(false, s(s(n''''')), m', cons(0, cons(s(s(m''''''')), x''''')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

IFREPLACE(false, s(s(n''')), m'', cons(s(s(m''''')), x')) -> REPLACE(s(s(n''')), m'', x')
five new Dependency Pairs are created:

IFREPLACE(false, s(s(n'''')), m''', cons(s(s(m''''')), cons(s(0), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(0), x'''))
IFREPLACE(false, s(s(n'''')), m''', cons(s(s(m''''')), cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(s(m''''')), x'''))
IFREPLACE(false, s(s(n''''')), m'''', cons(s(s(m''''')), cons(0, cons(0, x''''''')))) -> REPLACE(s(s(n''''')), m'''', cons(0, cons(0, x''''''')))
IFREPLACE(false, s(s(n'''')), m'''', cons(s(s(m''''')), cons(0, cons(s(0), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(0), x''''''')))
IFREPLACE(false, s(s(n'''')), m'''', cons(s(s(m''''')), cons(0, cons(s(s(m''''''''')), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(s(m''''''''')), x''''''')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 22
Polynomial Ordering
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

IFREPLACE(false, s(s(n'''')), m'''', cons(s(s(m''''')), cons(0, cons(s(s(m''''''''')), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(s(m''''''''')), x''''''')))
IFREPLACE(false, s(s(n'''')), m'''', cons(s(s(m''''')), cons(0, cons(s(0), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(0), x''''''')))
IFREPLACE(false, s(s(n''''')), m'''', cons(s(s(m''''')), cons(0, cons(0, x''''''')))) -> REPLACE(s(s(n''''')), m'''', cons(0, cons(0, x''''''')))
IFREPLACE(false, s(s(n'''')), m''', cons(s(s(m''''')), cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(s(m''''')), x'''))
IFREPLACE(false, s(s(n'''')), m'''', cons(s(0), cons(0, cons(s(0), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(0), x''''''')))
IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(0), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(0), x'''))
REPLACE(s(s(n''''')), m', cons(0, cons(s(0), x'''''))) -> IFREPLACE(false, s(s(n''''')), m', cons(0, cons(s(0), x''''')))
IFREPLACE(false, s(0), m'''', cons(s(s(m''''')), cons(0, cons(s(s(m''''''''')), x''''''')))) -> REPLACE(s(0), m'''', cons(0, cons(s(s(m''''''''')), x''''''')))
IFREPLACE(false, s(0), m'''', cons(s(s(m''''')), cons(0, cons(0, x''''''')))) -> REPLACE(s(0), m'''', cons(0, cons(0, x''''''')))
IFREPLACE(false, s(0), m''', cons(s(s(m''''')), cons(s(s(m''''')), x'''))) -> REPLACE(s(0), m''', cons(s(s(m''''')), x'''))
REPLACE(s(0), m, cons(s(s(m''')), x)) -> IFREPLACE(false, s(0), m, cons(s(s(m''')), x))
IFREPLACE(false, s(0), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(0), m''', cons(s(s(m''''')), x'''))
REPLACE(s(0), m', cons(0, cons(s(s(m''''''')), x'''''))) -> IFREPLACE(false, s(0), m', cons(0, cons(s(s(m''''''')), x''''')))
IFREPLACE(false, s(n'''''), m''', cons(0, cons(0, x'''))) -> REPLACE(s(n'''''), m''', cons(0, x'''))
REPLACE(s(n'''), m', cons(0, cons(0, x'''''))) -> IFREPLACE(false, s(n'''), m', cons(0, cons(0, x''''')))
IFREPLACE(false, s(s(n''''')), m'''', cons(s(0), cons(0, cons(0, x''''''')))) -> REPLACE(s(s(n''''')), m'''', cons(0, cons(0, x''''''')))
IFREPLACE(false, s(s(n'''')), m''', cons(s(0), cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(s(m''''')), x'''))
IFREPLACE(false, s(s(n'''')), m''', cons(s(0), cons(s(0), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(0), x'''))
REPLACE(s(s(n')), m, cons(s(0), x)) -> IFREPLACE(false, s(s(n')), m, cons(s(0), x))
IFREPLACE(false, s(s(n'''')), m''', cons(s(s(m''''')), cons(s(0), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(0), x'''))
REPLACE(s(s(n')), m, cons(s(s(m''')), x)) -> IFREPLACE(eq(n', m'''), s(s(n')), m, cons(s(s(m''')), x))
IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(s(m''''')), x'''))
REPLACE(s(s(n''''')), m', cons(0, cons(s(s(m''''''')), x'''''))) -> IFREPLACE(false, s(s(n''''')), m', cons(0, cons(s(s(m''''''')), x''''')))
IFREPLACE(false, s(s(n'''')), m'''', cons(s(0), cons(0, cons(s(s(m''''''''')), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(s(m''''''''')), x''''''')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




The following dependency pairs can be strictly oriented:

IFREPLACE(false, s(s(n'''')), m'''', cons(s(s(m''''')), cons(0, cons(s(s(m''''''''')), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(s(m''''''''')), x''''''')))
IFREPLACE(false, s(s(n'''')), m'''', cons(s(s(m''''')), cons(0, cons(s(0), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(0), x''''''')))
IFREPLACE(false, s(s(n''''')), m'''', cons(s(s(m''''')), cons(0, cons(0, x''''''')))) -> REPLACE(s(s(n''''')), m'''', cons(0, cons(0, x''''''')))
IFREPLACE(false, s(s(n'''')), m''', cons(s(s(m''''')), cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(s(m''''')), x'''))
IFREPLACE(false, s(s(n'''')), m'''', cons(s(0), cons(0, cons(s(0), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(0), x''''''')))
IFREPLACE(false, s(0), m'''', cons(s(s(m''''')), cons(0, cons(s(s(m''''''''')), x''''''')))) -> REPLACE(s(0), m'''', cons(0, cons(s(s(m''''''''')), x''''''')))
IFREPLACE(false, s(0), m'''', cons(s(s(m''''')), cons(0, cons(0, x''''''')))) -> REPLACE(s(0), m'''', cons(0, cons(0, x''''''')))
IFREPLACE(false, s(0), m''', cons(s(s(m''''')), cons(s(s(m''''')), x'''))) -> REPLACE(s(0), m''', cons(s(s(m''''')), x'''))
IFREPLACE(false, s(s(n''''')), m'''', cons(s(0), cons(0, cons(0, x''''''')))) -> REPLACE(s(s(n''''')), m'''', cons(0, cons(0, x''''''')))
IFREPLACE(false, s(s(n'''')), m''', cons(s(0), cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(s(m''''')), x'''))
IFREPLACE(false, s(s(n'''')), m''', cons(s(0), cons(s(0), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(0), x'''))
IFREPLACE(false, s(s(n'''')), m''', cons(s(s(m''''')), cons(s(0), x'''))) -> REPLACE(s(s(n'''')), m''', cons(s(0), x'''))
IFREPLACE(false, s(s(n'''')), m'''', cons(s(0), cons(0, cons(s(s(m''''''''')), x''''''')))) -> REPLACE(s(s(n'''')), m'''', cons(0, cons(s(s(m''''''''')), x''''''')))


There are no usable rules for innermost w.r.t. to the implicit AFS that need to be oriented.

Used ordering: Polynomial ordering with Polynomial interpretation:
  POL(REPLACE(x1, x2, x3))=  x3  
  POL(eq(x1, x2))=  0  
  POL(0)=  0  
  POL(false)=  0  
  POL(cons(x1, x2))=  x1 + x2  
  POL(IF_REPLACE(x1, x2, x3, x4))=  x4  
  POL(true)=  0  
  POL(s(x1))=  1  

resulting in one new DP problem.



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 24
Dependency Graph
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(0), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(0), x'''))
REPLACE(s(s(n''''')), m', cons(0, cons(s(0), x'''''))) -> IFREPLACE(false, s(s(n''''')), m', cons(0, cons(s(0), x''''')))
REPLACE(s(0), m, cons(s(s(m''')), x)) -> IFREPLACE(false, s(0), m, cons(s(s(m''')), x))
IFREPLACE(false, s(0), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(0), m''', cons(s(s(m''''')), x'''))
REPLACE(s(0), m', cons(0, cons(s(s(m''''''')), x'''''))) -> IFREPLACE(false, s(0), m', cons(0, cons(s(s(m''''''')), x''''')))
IFREPLACE(false, s(n'''''), m''', cons(0, cons(0, x'''))) -> REPLACE(s(n'''''), m''', cons(0, x'''))
REPLACE(s(n'''), m', cons(0, cons(0, x'''''))) -> IFREPLACE(false, s(n'''), m', cons(0, cons(0, x''''')))
REPLACE(s(s(n')), m, cons(s(0), x)) -> IFREPLACE(false, s(s(n')), m, cons(s(0), x))
REPLACE(s(s(n')), m, cons(s(s(m''')), x)) -> IFREPLACE(eq(n', m'''), s(s(n')), m, cons(s(s(m''')), x))
IFREPLACE(false, s(s(n''')), m''', cons(0, cons(s(s(m''''')), x'''))) -> REPLACE(s(s(n''')), m''', cons(s(s(m''''')), x'''))
REPLACE(s(s(n''''')), m', cons(0, cons(s(s(m''''''')), x'''''))) -> IFREPLACE(false, s(s(n''''')), m', cons(0, cons(s(s(m''''''')), x''''')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




Using the Dependency Graph the DP problem was split into 1 DP problems.


   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 25
Polynomial Ordering
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

REPLACE(s(n'''), m', cons(0, cons(0, x'''''))) -> IFREPLACE(false, s(n'''), m', cons(0, cons(0, x''''')))
IFREPLACE(false, s(n'''''), m''', cons(0, cons(0, x'''))) -> REPLACE(s(n'''''), m''', cons(0, x'''))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




The following dependency pair can be strictly oriented:

REPLACE(s(n'''), m', cons(0, cons(0, x'''''))) -> IFREPLACE(false, s(n'''), m', cons(0, cons(0, x''''')))


There are no usable rules for innermost w.r.t. to the implicit AFS that need to be oriented.

Used ordering: Polynomial ordering with Polynomial interpretation:
  POL(REPLACE(x1, x2, x3))=  1 + x3  
  POL(0)=  0  
  POL(cons(x1, x2))=  1 + x2  
  POL(false)=  0  
  POL(IF_REPLACE(x1, x2, x3, x4))=  x4  
  POL(s(x1))=  0  

resulting in one new DP problem.



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 26
Dependency Graph
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pair:

IFREPLACE(false, s(n'''''), m''', cons(0, cons(0, x'''))) -> REPLACE(s(n'''''), m''', cons(0, x'''))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




Using the Dependency Graph resulted in no new DP problems.


   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 15
Forward Instantiation Transformation
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

IFREPLACE(false, 0, m'', cons(s(m''''), x'')) -> REPLACE(0, m'', x'')
REPLACE(0, m, cons(s(m''), x)) -> IFREPLACE(false, 0, m, cons(s(m''), x))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

IFREPLACE(false, 0, m'', cons(s(m''''), x'')) -> REPLACE(0, m'', x'')
one new Dependency Pair is created:

IFREPLACE(false, 0, m''0, cons(s(m''''), cons(s(m''''), x'''))) -> REPLACE(0, m''0, cons(s(m''''), x'''))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 17
Forward Instantiation Transformation
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

IFREPLACE(false, 0, m''0, cons(s(m''''), cons(s(m''''), x'''))) -> REPLACE(0, m''0, cons(s(m''''), x'''))
REPLACE(0, m, cons(s(m''), x)) -> IFREPLACE(false, 0, m, cons(s(m''), x))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

REPLACE(0, m, cons(s(m''), x)) -> IFREPLACE(false, 0, m, cons(s(m''), x))
one new Dependency Pair is created:

REPLACE(0, m', cons(s(m'''), cons(s(m'''''''), x'''''))) -> IFREPLACE(false, 0, m', cons(s(m'''), cons(s(m'''''''), x''''')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 19
Polynomial Ordering
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pairs:

REPLACE(0, m', cons(s(m'''), cons(s(m'''''''), x'''''))) -> IFREPLACE(false, 0, m', cons(s(m'''), cons(s(m'''''''), x''''')))
IFREPLACE(false, 0, m''0, cons(s(m''''), cons(s(m''''), x'''))) -> REPLACE(0, m''0, cons(s(m''''), x'''))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




The following dependency pair can be strictly oriented:

REPLACE(0, m', cons(s(m'''), cons(s(m'''''''), x'''''))) -> IFREPLACE(false, 0, m', cons(s(m'''), cons(s(m'''''''), x''''')))


There are no usable rules for innermost w.r.t. to the implicit AFS that need to be oriented.

Used ordering: Polynomial ordering with Polynomial interpretation:
  POL(REPLACE(x1, x2, x3))=  1 + x3  
  POL(0)=  0  
  POL(cons(x1, x2))=  x1 + x2  
  POL(false)=  0  
  POL(IF_REPLACE(x1, x2, x3, x4))=  x4  
  POL(s(x1))=  1  

resulting in one new DP problem.



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
           →DP Problem 12
Nar
             ...
               →DP Problem 23
Dependency Graph
       →DP Problem 4
Nar
       →DP Problem 5
Nar


Dependency Pair:

IFREPLACE(false, 0, m''0, cons(s(m''''), cons(s(m''''), x'''))) -> REPLACE(0, m''0, cons(s(m''''), x'''))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




Using the Dependency Graph resulted in no new DP problems.


   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Narrowing Transformation
       →DP Problem 5
Nar


Dependency Pairs:

IFMIN(false, cons(n, cons(m, x))) -> MIN(cons(m, x))
IFMIN(true, cons(n, cons(m, x))) -> MIN(cons(n, x))
MIN(cons(n, cons(m, x))) -> IFMIN(le(n, m), cons(n, cons(m, x)))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Narrowing SCC transformation can be performed.
As a result of transforming the rule

MIN(cons(n, cons(m, x))) -> IFMIN(le(n, m), cons(n, cons(m, x)))
three new Dependency Pairs are created:

MIN(cons(0, cons(m'', x))) -> IFMIN(true, cons(0, cons(m'', x)))
MIN(cons(s(n''), cons(0, x))) -> IFMIN(false, cons(s(n''), cons(0, x)))
MIN(cons(s(n''), cons(s(m''), x))) -> IFMIN(le(n'', m''), cons(s(n''), cons(s(m''), x)))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Narrowing Transformation
       →DP Problem 5
Nar


Dependency Pairs:

MIN(cons(s(n''), cons(s(m''), x))) -> IFMIN(le(n'', m''), cons(s(n''), cons(s(m''), x)))
MIN(cons(s(n''), cons(0, x))) -> IFMIN(false, cons(s(n''), cons(0, x)))
IFMIN(true, cons(n, cons(m, x))) -> MIN(cons(n, x))
MIN(cons(0, cons(m'', x))) -> IFMIN(true, cons(0, cons(m'', x)))
IFMIN(false, cons(n, cons(m, x))) -> MIN(cons(m, x))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Narrowing SCC transformation can be performed.
As a result of transforming the rule

MIN(cons(s(n''), cons(s(m''), x))) -> IFMIN(le(n'', m''), cons(s(n''), cons(s(m''), x)))
three new Dependency Pairs are created:

MIN(cons(s(0), cons(s(m'''), x))) -> IFMIN(true, cons(s(0), cons(s(m'''), x)))
MIN(cons(s(s(n')), cons(s(0), x))) -> IFMIN(false, cons(s(s(n')), cons(s(0), x)))
MIN(cons(s(s(n')), cons(s(s(m')), x))) -> IFMIN(le(n', m'), cons(s(s(n')), cons(s(s(m')), x)))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 28
Instantiation Transformation
       →DP Problem 5
Nar


Dependency Pairs:

MIN(cons(s(s(n')), cons(s(s(m')), x))) -> IFMIN(le(n', m'), cons(s(s(n')), cons(s(s(m')), x)))
MIN(cons(s(s(n')), cons(s(0), x))) -> IFMIN(false, cons(s(s(n')), cons(s(0), x)))
MIN(cons(s(0), cons(s(m'''), x))) -> IFMIN(true, cons(s(0), cons(s(m'''), x)))
IFMIN(true, cons(n, cons(m, x))) -> MIN(cons(n, x))
MIN(cons(0, cons(m'', x))) -> IFMIN(true, cons(0, cons(m'', x)))
IFMIN(false, cons(n, cons(m, x))) -> MIN(cons(m, x))
MIN(cons(s(n''), cons(0, x))) -> IFMIN(false, cons(s(n''), cons(0, x)))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, an Instantiation SCC transformation can be performed.
As a result of transforming the rule

IFMIN(true, cons(n, cons(m, x))) -> MIN(cons(n, x))
three new Dependency Pairs are created:

IFMIN(true, cons(0, cons(m', x''))) -> MIN(cons(0, x''))
IFMIN(true, cons(s(0), cons(s(m'''''), x''))) -> MIN(cons(s(0), x''))
IFMIN(true, cons(s(s(n''')), cons(s(s(m''')), x'))) -> MIN(cons(s(s(n''')), x'))

The transformation is resulting in two new DP problems:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 29
Forward Instantiation Transformation
       →DP Problem 5
Nar


Dependency Pairs:

IFMIN(true, cons(0, cons(m', x''))) -> MIN(cons(0, x''))
MIN(cons(0, cons(m'', x))) -> IFMIN(true, cons(0, cons(m'', x)))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

IFMIN(true, cons(0, cons(m', x''))) -> MIN(cons(0, x''))
one new Dependency Pair is created:

IFMIN(true, cons(0, cons(m', cons(m'''', x''')))) -> MIN(cons(0, cons(m'''', x''')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 31
Forward Instantiation Transformation
       →DP Problem 5
Nar


Dependency Pairs:

IFMIN(true, cons(0, cons(m', cons(m'''', x''')))) -> MIN(cons(0, cons(m'''', x''')))
MIN(cons(0, cons(m'', x))) -> IFMIN(true, cons(0, cons(m'', x)))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

MIN(cons(0, cons(m'', x))) -> IFMIN(true, cons(0, cons(m'', x)))
one new Dependency Pair is created:

MIN(cons(0, cons(m'''', cons(m'''''', x''''')))) -> IFMIN(true, cons(0, cons(m'''', cons(m'''''', x'''''))))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 34
Polynomial Ordering
       →DP Problem 5
Nar


Dependency Pairs:

MIN(cons(0, cons(m'''', cons(m'''''', x''''')))) -> IFMIN(true, cons(0, cons(m'''', cons(m'''''', x'''''))))
IFMIN(true, cons(0, cons(m', cons(m'''', x''')))) -> MIN(cons(0, cons(m'''', x''')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




The following dependency pair can be strictly oriented:

MIN(cons(0, cons(m'''', cons(m'''''', x''''')))) -> IFMIN(true, cons(0, cons(m'''', cons(m'''''', x'''''))))


There are no usable rules for innermost w.r.t. to the implicit AFS that need to be oriented.

Used ordering: Polynomial ordering with Polynomial interpretation:
  POL(0)=  0  
  POL(cons(x1, x2))=  1 + x2  
  POL(MIN(x1))=  1 + x1  
  POL(true)=  0  
  POL(IF_MIN(x1, x2))=  x2  

resulting in one new DP problem.



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 38
Dependency Graph
       →DP Problem 5
Nar


Dependency Pair:

IFMIN(true, cons(0, cons(m', cons(m'''', x''')))) -> MIN(cons(0, cons(m'''', x''')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




Using the Dependency Graph resulted in no new DP problems.


   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 30
Instantiation Transformation
       →DP Problem 5
Nar


Dependency Pairs:

IFMIN(true, cons(s(s(n''')), cons(s(s(m''')), x'))) -> MIN(cons(s(s(n''')), x'))
MIN(cons(s(s(n')), cons(s(0), x))) -> IFMIN(false, cons(s(s(n')), cons(s(0), x)))
IFMIN(true, cons(s(0), cons(s(m'''''), x''))) -> MIN(cons(s(0), x''))
MIN(cons(s(0), cons(s(m'''), x))) -> IFMIN(true, cons(s(0), cons(s(m'''), x)))
MIN(cons(s(n''), cons(0, x))) -> IFMIN(false, cons(s(n''), cons(0, x)))
IFMIN(false, cons(n, cons(m, x))) -> MIN(cons(m, x))
MIN(cons(s(s(n')), cons(s(s(m')), x))) -> IFMIN(le(n', m'), cons(s(s(n')), cons(s(s(m')), x)))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, an Instantiation SCC transformation can be performed.
As a result of transforming the rule

IFMIN(false, cons(n, cons(m, x))) -> MIN(cons(m, x))
three new Dependency Pairs are created:

IFMIN(false, cons(s(n''''), cons(0, x''))) -> MIN(cons(0, x''))
IFMIN(false, cons(s(s(n''')), cons(s(0), x''))) -> MIN(cons(s(0), x''))
IFMIN(false, cons(s(s(n''')), cons(s(s(m''')), x'))) -> MIN(cons(s(s(m''')), x'))

The transformation is resulting in two new DP problems:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 32
Forward Instantiation Transformation
       →DP Problem 5
Nar


Dependency Pairs:

IFMIN(true, cons(s(0), cons(s(m'''''), x''))) -> MIN(cons(s(0), x''))
MIN(cons(s(0), cons(s(m'''), x))) -> IFMIN(true, cons(s(0), cons(s(m'''), x)))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

IFMIN(true, cons(s(0), cons(s(m'''''), x''))) -> MIN(cons(s(0), x''))
one new Dependency Pair is created:

IFMIN(true, cons(s(0), cons(s(m'''''), cons(s(m'''''), x''')))) -> MIN(cons(s(0), cons(s(m'''''), x''')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 35
Polynomial Ordering
       →DP Problem 5
Nar


Dependency Pairs:

IFMIN(true, cons(s(0), cons(s(m'''''), cons(s(m'''''), x''')))) -> MIN(cons(s(0), cons(s(m'''''), x''')))
MIN(cons(s(0), cons(s(m'''), x))) -> IFMIN(true, cons(s(0), cons(s(m'''), x)))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




The following dependency pair can be strictly oriented:

IFMIN(true, cons(s(0), cons(s(m'''''), cons(s(m'''''), x''')))) -> MIN(cons(s(0), cons(s(m'''''), x''')))


There are no usable rules for innermost w.r.t. to the implicit AFS that need to be oriented.

Used ordering: Polynomial ordering with Polynomial interpretation:
  POL(0)=  0  
  POL(cons(x1, x2))=  x1 + x2  
  POL(MIN(x1))=  x1  
  POL(true)=  0  
  POL(IF_MIN(x1, x2))=  x2  
  POL(s(x1))=  1  

resulting in one new DP problem.



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 39
Dependency Graph
       →DP Problem 5
Nar


Dependency Pair:

MIN(cons(s(0), cons(s(m'''), x))) -> IFMIN(true, cons(s(0), cons(s(m'''), x)))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




Using the Dependency Graph resulted in no new DP problems.


   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 33
Forward Instantiation Transformation
       →DP Problem 5
Nar


Dependency Pairs:

IFMIN(false, cons(s(s(n''')), cons(s(s(m''')), x'))) -> MIN(cons(s(s(m''')), x'))
MIN(cons(s(s(n')), cons(s(s(m')), x))) -> IFMIN(le(n', m'), cons(s(s(n')), cons(s(s(m')), x)))
IFMIN(true, cons(s(s(n''')), cons(s(s(m''')), x'))) -> MIN(cons(s(s(n''')), x'))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

IFMIN(true, cons(s(s(n''')), cons(s(s(m''')), x'))) -> MIN(cons(s(s(n''')), x'))
one new Dependency Pair is created:

IFMIN(true, cons(s(s(n'''')), cons(s(s(m''')), cons(s(s(m''')), x''')))) -> MIN(cons(s(s(n'''')), cons(s(s(m''')), x''')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 36
Forward Instantiation Transformation
       →DP Problem 5
Nar


Dependency Pairs:

IFMIN(true, cons(s(s(n'''')), cons(s(s(m''')), cons(s(s(m''')), x''')))) -> MIN(cons(s(s(n'''')), cons(s(s(m''')), x''')))
MIN(cons(s(s(n')), cons(s(s(m')), x))) -> IFMIN(le(n', m'), cons(s(s(n')), cons(s(s(m')), x)))
IFMIN(false, cons(s(s(n''')), cons(s(s(m''')), x'))) -> MIN(cons(s(s(m''')), x'))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Forward Instantiation SCC transformation can be performed.
As a result of transforming the rule

IFMIN(false, cons(s(s(n''')), cons(s(s(m''')), x'))) -> MIN(cons(s(s(m''')), x'))
one new Dependency Pair is created:

IFMIN(false, cons(s(s(n''')), cons(s(s(m'''')), cons(s(s(m''0)), x''')))) -> MIN(cons(s(s(m'''')), cons(s(s(m''0)), x''')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 37
Polynomial Ordering
       →DP Problem 5
Nar


Dependency Pairs:

IFMIN(false, cons(s(s(n''')), cons(s(s(m'''')), cons(s(s(m''0)), x''')))) -> MIN(cons(s(s(m'''')), cons(s(s(m''0)), x''')))
MIN(cons(s(s(n')), cons(s(s(m')), x))) -> IFMIN(le(n', m'), cons(s(s(n')), cons(s(s(m')), x)))
IFMIN(true, cons(s(s(n'''')), cons(s(s(m''')), cons(s(s(m''')), x''')))) -> MIN(cons(s(s(n'''')), cons(s(s(m''')), x''')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




The following dependency pairs can be strictly oriented:

IFMIN(false, cons(s(s(n''')), cons(s(s(m'''')), cons(s(s(m''0)), x''')))) -> MIN(cons(s(s(m'''')), cons(s(s(m''0)), x''')))
IFMIN(true, cons(s(s(n'''')), cons(s(s(m''')), cons(s(s(m''')), x''')))) -> MIN(cons(s(s(n'''')), cons(s(s(m''')), x''')))


There are no usable rules for innermost w.r.t. to the implicit AFS that need to be oriented.

Used ordering: Polynomial ordering with Polynomial interpretation:
  POL(0)=  0  
  POL(false)=  0  
  POL(cons(x1, x2))=  1 + x2  
  POL(MIN(x1))=  x1  
  POL(true)=  0  
  POL(s(x1))=  0  
  POL(IF_MIN(x1, x2))=  x2  
  POL(le(x1, x2))=  0  

resulting in one new DP problem.



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
           →DP Problem 27
Nar
             ...
               →DP Problem 40
Dependency Graph
       →DP Problem 5
Nar


Dependency Pair:

MIN(cons(s(s(n')), cons(s(s(m')), x))) -> IFMIN(le(n', m'), cons(s(s(n')), cons(s(s(m')), x)))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




Using the Dependency Graph resulted in no new DP problems.


   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Narrowing Transformation


Dependency Pair:

SORT(cons(n, x)) -> SORT(replace(min(cons(n, x)), n, x))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Narrowing SCC transformation can be performed.
As a result of transforming the rule

SORT(cons(n, x)) -> SORT(replace(min(cons(n, x)), n, x))
five new Dependency Pairs are created:

SORT(cons(n'', nil)) -> SORT(nil)
SORT(cons(n'', cons(k', x''))) -> SORT(ifreplace(eq(min(cons(n'', cons(k', x''))), k'), min(cons(n'', cons(k', x''))), n'', cons(k', x'')))
SORT(cons(0, nil)) -> SORT(replace(0, 0, nil))
SORT(cons(s(n''), nil)) -> SORT(replace(s(n''), s(n''), nil))
SORT(cons(n'', cons(m', x''))) -> SORT(replace(ifmin(le(n'', m'), cons(n'', cons(m', x''))), n'', cons(m', x'')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar
           →DP Problem 41
Rewriting Transformation


Dependency Pairs:

SORT(cons(n'', cons(m', x''))) -> SORT(replace(ifmin(le(n'', m'), cons(n'', cons(m', x''))), n'', cons(m', x'')))
SORT(cons(s(n''), nil)) -> SORT(replace(s(n''), s(n''), nil))
SORT(cons(0, nil)) -> SORT(replace(0, 0, nil))
SORT(cons(n'', cons(k', x''))) -> SORT(ifreplace(eq(min(cons(n'', cons(k', x''))), k'), min(cons(n'', cons(k', x''))), n'', cons(k', x'')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Rewriting SCC transformation can be performed.
As a result of transforming the rule

SORT(cons(n'', cons(k', x''))) -> SORT(ifreplace(eq(min(cons(n'', cons(k', x''))), k'), min(cons(n'', cons(k', x''))), n'', cons(k', x'')))
one new Dependency Pair is created:

SORT(cons(n'', cons(k', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', k'), cons(n'', cons(k', x''))), k'), min(cons(n'', cons(k', x''))), n'', cons(k', x'')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar
           →DP Problem 41
Rw
             ...
               →DP Problem 42
Rewriting Transformation


Dependency Pairs:

SORT(cons(n'', cons(k', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', k'), cons(n'', cons(k', x''))), k'), min(cons(n'', cons(k', x''))), n'', cons(k', x'')))
SORT(cons(s(n''), nil)) -> SORT(replace(s(n''), s(n''), nil))
SORT(cons(0, nil)) -> SORT(replace(0, 0, nil))
SORT(cons(n'', cons(m', x''))) -> SORT(replace(ifmin(le(n'', m'), cons(n'', cons(m', x''))), n'', cons(m', x'')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Rewriting SCC transformation can be performed.
As a result of transforming the rule

SORT(cons(0, nil)) -> SORT(replace(0, 0, nil))
one new Dependency Pair is created:

SORT(cons(0, nil)) -> SORT(nil)

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar
           →DP Problem 41
Rw
             ...
               →DP Problem 43
Rewriting Transformation


Dependency Pairs:

SORT(cons(n'', cons(m', x''))) -> SORT(replace(ifmin(le(n'', m'), cons(n'', cons(m', x''))), n'', cons(m', x'')))
SORT(cons(s(n''), nil)) -> SORT(replace(s(n''), s(n''), nil))
SORT(cons(n'', cons(k', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', k'), cons(n'', cons(k', x''))), k'), min(cons(n'', cons(k', x''))), n'', cons(k', x'')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Rewriting SCC transformation can be performed.
As a result of transforming the rule

SORT(cons(s(n''), nil)) -> SORT(replace(s(n''), s(n''), nil))
one new Dependency Pair is created:

SORT(cons(s(n''), nil)) -> SORT(nil)

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar
           →DP Problem 41
Rw
             ...
               →DP Problem 44
Rewriting Transformation


Dependency Pairs:

SORT(cons(n'', cons(k', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', k'), cons(n'', cons(k', x''))), k'), min(cons(n'', cons(k', x''))), n'', cons(k', x'')))
SORT(cons(n'', cons(m', x''))) -> SORT(replace(ifmin(le(n'', m'), cons(n'', cons(m', x''))), n'', cons(m', x'')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Rewriting SCC transformation can be performed.
As a result of transforming the rule

SORT(cons(n'', cons(m', x''))) -> SORT(replace(ifmin(le(n'', m'), cons(n'', cons(m', x''))), n'', cons(m', x'')))
one new Dependency Pair is created:

SORT(cons(n'', cons(m', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', m'), cons(n'', cons(m', x''))), m'), ifmin(le(n'', m'), cons(n'', cons(m', x''))), n'', cons(m', x'')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar
           →DP Problem 41
Rw
             ...
               →DP Problem 45
Rewriting Transformation


Dependency Pairs:

SORT(cons(n'', cons(m', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', m'), cons(n'', cons(m', x''))), m'), ifmin(le(n'', m'), cons(n'', cons(m', x''))), n'', cons(m', x'')))
SORT(cons(n'', cons(k', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', k'), cons(n'', cons(k', x''))), k'), min(cons(n'', cons(k', x''))), n'', cons(k', x'')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




On this DP problem, a Rewriting SCC transformation can be performed.
As a result of transforming the rule

SORT(cons(n'', cons(k', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', k'), cons(n'', cons(k', x''))), k'), min(cons(n'', cons(k', x''))), n'', cons(k', x'')))
one new Dependency Pair is created:

SORT(cons(n'', cons(k', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', k'), cons(n'', cons(k', x''))), k'), ifmin(le(n'', k'), cons(n'', cons(k', x''))), n'', cons(k', x'')))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar
           →DP Problem 41
Rw
             ...
               →DP Problem 46
Polynomial Ordering


Dependency Pairs:

SORT(cons(n'', cons(k', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', k'), cons(n'', cons(k', x''))), k'), ifmin(le(n'', k'), cons(n'', cons(k', x''))), n'', cons(k', x'')))
SORT(cons(n'', cons(m', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', m'), cons(n'', cons(m', x''))), m'), ifmin(le(n'', m'), cons(n'', cons(m', x''))), n'', cons(m', x'')))


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




The following dependency pairs can be strictly oriented:

SORT(cons(n'', cons(k', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', k'), cons(n'', cons(k', x''))), k'), ifmin(le(n'', k'), cons(n'', cons(k', x''))), n'', cons(k', x'')))
SORT(cons(n'', cons(m', x''))) -> SORT(ifreplace(eq(ifmin(le(n'', m'), cons(n'', cons(m', x''))), m'), ifmin(le(n'', m'), cons(n'', cons(m', x''))), n'', cons(m', x'')))


Additionally, the following usable rules for innermost w.r.t. to the implicit AFS can be oriented:

replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))


Used ordering: Polynomial ordering with Polynomial interpretation:
  POL(false)=  0  
  POL(true)=  0  
  POL(replace(x1, x2, x3))=  x3  
  POL(if_min(x1, x2))=  0  
  POL(SORT(x1))=  x1  
  POL(eq(x1, x2))=  0  
  POL(0)=  0  
  POL(cons(x1, x2))=  1 + x2  
  POL(min(x1))=  0  
  POL(nil)=  0  
  POL(s(x1))=  0  
  POL(le(x1, x2))=  0  
  POL(if_replace(x1, x2, x3, x4))=  x4  

resulting in one new DP problem.



   R
DPs
       →DP Problem 1
FwdInst
       →DP Problem 2
FwdInst
       →DP Problem 3
Nar
       →DP Problem 4
Nar
       →DP Problem 5
Nar
           →DP Problem 41
Rw
             ...
               →DP Problem 47
Dependency Graph


Dependency Pair:


Rules:


eq(0, 0) -> true
eq(0, s(m)) -> false
eq(s(n), 0) -> false
eq(s(n), s(m)) -> eq(n, m)
le(0, m) -> true
le(s(n), 0) -> false
le(s(n), s(m)) -> le(n, m)
min(cons(0, nil)) -> 0
min(cons(s(n), nil)) -> s(n)
min(cons(n, cons(m, x))) -> ifmin(le(n, m), cons(n, cons(m, x)))
ifmin(true, cons(n, cons(m, x))) -> min(cons(n, x))
ifmin(false, cons(n, cons(m, x))) -> min(cons(m, x))
replace(n, m, nil) -> nil
replace(n, m, cons(k, x)) -> ifreplace(eq(n, k), n, m, cons(k, x))
ifreplace(true, n, m, cons(k, x)) -> cons(m, x)
ifreplace(false, n, m, cons(k, x)) -> cons(k, replace(n, m, x))
sort(nil) -> nil
sort(cons(n, x)) -> cons(min(cons(n, x)), sort(replace(min(cons(n, x)), n, x)))


Strategy:

innermost




Using the Dependency Graph resulted in no new DP problems.

Innermost Termination of R successfully shown.
Duration:
0:07 minutes