Term Rewriting System R:
[x, y]
app(f, 0) -> true
app(f, 1) -> false
app(f, app(s, x)) -> app(f, x)
app(app(app(if, true), app(s, x)), app(s, y)) -> app(s, x)
app(app(app(if, false), app(s, x)), app(s, y)) -> app(s, y)
app(app(g, x), app(c, y)) -> app(c, app(app(g, x), y))
app(app(g, x), app(c, y)) -> app(app(g, x), app(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y)))

Innermost Termination of R to be shown.



   R
Dependency Pair Analysis



R contains the following Dependency Pairs:

APP(f, app(s, x)) -> APP(f, x)
APP(app(g, x), app(c, y)) -> APP(c, app(app(g, x), y))
APP(app(g, x), app(c, y)) -> APP(app(g, x), y)
APP(app(g, x), app(c, y)) -> APP(app(g, x), app(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y)))
APP(app(g, x), app(c, y)) -> APP(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y))
APP(app(g, x), app(c, y)) -> APP(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y)))
APP(app(g, x), app(c, y)) -> APP(if, app(f, x))
APP(app(g, x), app(c, y)) -> APP(f, x)
APP(app(g, x), app(c, y)) -> APP(c, app(app(g, app(s, x)), y))
APP(app(g, x), app(c, y)) -> APP(app(g, app(s, x)), y)
APP(app(g, x), app(c, y)) -> APP(g, app(s, x))
APP(app(g, x), app(c, y)) -> APP(s, x)

Furthermore, R contains two SCCs.


   R
DPs
       →DP Problem 1
Polynomial Ordering
       →DP Problem 2
Polo


Dependency Pair:

APP(f, app(s, x)) -> APP(f, x)


Rules:


app(f, 0) -> true
app(f, 1) -> false
app(f, app(s, x)) -> app(f, x)
app(app(app(if, true), app(s, x)), app(s, y)) -> app(s, x)
app(app(app(if, false), app(s, x)), app(s, y)) -> app(s, y)
app(app(g, x), app(c, y)) -> app(c, app(app(g, x), y))
app(app(g, x), app(c, y)) -> app(app(g, x), app(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y)))


Strategy:

innermost




The following dependency pair can be strictly oriented:

APP(f, app(s, x)) -> APP(f, 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(s)=  0  
  POL(APP(x1, x2))=  x2  
  POL(f)=  0  
  POL(app(x1, x2))=  1 + x2  

resulting in one new DP problem.



   R
DPs
       →DP Problem 1
Polo
           →DP Problem 3
Dependency Graph
       →DP Problem 2
Polo


Dependency Pair:


Rules:


app(f, 0) -> true
app(f, 1) -> false
app(f, app(s, x)) -> app(f, x)
app(app(app(if, true), app(s, x)), app(s, y)) -> app(s, x)
app(app(app(if, false), app(s, x)), app(s, y)) -> app(s, y)
app(app(g, x), app(c, y)) -> app(c, app(app(g, x), y))
app(app(g, x), app(c, y)) -> app(app(g, x), app(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y)))


Strategy:

innermost




Using the Dependency Graph resulted in no new DP problems.


   R
DPs
       →DP Problem 1
Polo
       →DP Problem 2
Polynomial Ordering


Dependency Pairs:

APP(app(g, x), app(c, y)) -> APP(app(g, app(s, x)), y)
APP(app(g, x), app(c, y)) -> APP(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y)))
APP(app(g, x), app(c, y)) -> APP(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y))
APP(app(g, x), app(c, y)) -> APP(app(g, x), app(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y)))
APP(app(g, x), app(c, y)) -> APP(app(g, x), y)


Rules:


app(f, 0) -> true
app(f, 1) -> false
app(f, app(s, x)) -> app(f, x)
app(app(app(if, true), app(s, x)), app(s, y)) -> app(s, x)
app(app(app(if, false), app(s, x)), app(s, y)) -> app(s, y)
app(app(g, x), app(c, y)) -> app(c, app(app(g, x), y))
app(app(g, x), app(c, y)) -> app(app(g, x), app(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y)))


Strategy:

innermost




The following dependency pairs can be strictly oriented:

APP(app(g, x), app(c, y)) -> APP(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y)))
APP(app(g, x), app(c, y)) -> APP(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y))


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

app(f, 0) -> true
app(f, 1) -> false
app(f, app(s, x)) -> app(f, x)
app(app(app(if, true), app(s, x)), app(s, y)) -> app(s, x)
app(app(app(if, false), app(s, x)), app(s, y)) -> app(s, y)
app(app(g, x), app(c, y)) -> app(c, app(app(g, x), y))
app(app(g, x), app(c, y)) -> app(app(g, x), app(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y)))


Used ordering: Polynomial ordering with Polynomial interpretation:
  POL(if)=  0  
  POL(c)=  0  
  POL(0)=  1  
  POL(g)=  1  
  POL(false)=  0  
  POL(1)=  0  
  POL(true)=  0  
  POL(s)=  0  
  POL(app(x1, x2))=  x1  
  POL(f)=  0  
  POL(APP(x1, x2))=  x1  

resulting in one new DP problem.



   R
DPs
       →DP Problem 1
Polo
       →DP Problem 2
Polo
           →DP Problem 4
Narrowing Transformation


Dependency Pairs:

APP(app(g, x), app(c, y)) -> APP(app(g, app(s, x)), y)
APP(app(g, x), app(c, y)) -> APP(app(g, x), app(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y)))
APP(app(g, x), app(c, y)) -> APP(app(g, x), y)


Rules:


app(f, 0) -> true
app(f, 1) -> false
app(f, app(s, x)) -> app(f, x)
app(app(app(if, true), app(s, x)), app(s, y)) -> app(s, x)
app(app(app(if, false), app(s, x)), app(s, y)) -> app(s, y)
app(app(g, x), app(c, y)) -> app(c, app(app(g, x), y))
app(app(g, x), app(c, y)) -> app(app(g, x), app(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y)))


Strategy:

innermost




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

APP(app(g, x), app(c, y)) -> APP(app(g, x), app(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y)))
five new Dependency Pairs are created:

APP(app(g, 0), app(c, y)) -> APP(app(g, 0), app(app(app(if, true), app(c, app(app(g, app(s, 0)), y))), app(c, y)))
APP(app(g, 1), app(c, y)) -> APP(app(g, 1), app(app(app(if, false), app(c, app(app(g, app(s, 1)), y))), app(c, y)))
APP(app(g, app(s, x'')), app(c, y)) -> APP(app(g, app(s, x'')), app(app(app(if, app(f, x'')), app(c, app(app(g, app(s, app(s, x''))), y))), app(c, y)))
APP(app(g, x''), app(c, app(c, y''))) -> APP(app(g, x''), app(app(app(if, app(f, x'')), app(c, app(c, app(app(g, app(s, x'')), y'')))), app(c, app(c, y''))))
APP(app(g, x''), app(c, app(c, y''))) -> APP(app(g, x''), app(app(app(if, app(f, x'')), app(c, app(app(g, app(s, x'')), app(app(app(if, app(f, app(s, x''))), app(c, app(app(g, app(s, app(s, x''))), y''))), app(c, y''))))), app(c, app(c, y''))))

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
Polo
       →DP Problem 2
Polo
           →DP Problem 4
Nar
             ...
               →DP Problem 5
Remaining Obligation(s)




The following remains to be proven:
Dependency Pairs:

APP(app(g, app(s, x'')), app(c, y)) -> APP(app(g, app(s, x'')), app(app(app(if, app(f, x'')), app(c, app(app(g, app(s, app(s, x''))), y))), app(c, y)))
APP(app(g, x''), app(c, app(c, y''))) -> APP(app(g, x''), app(app(app(if, app(f, x'')), app(c, app(app(g, app(s, x'')), app(app(app(if, app(f, app(s, x''))), app(c, app(app(g, app(s, app(s, x''))), y''))), app(c, y''))))), app(c, app(c, y''))))
APP(app(g, 1), app(c, y)) -> APP(app(g, 1), app(app(app(if, false), app(c, app(app(g, app(s, 1)), y))), app(c, y)))
APP(app(g, x''), app(c, app(c, y''))) -> APP(app(g, x''), app(app(app(if, app(f, x'')), app(c, app(c, app(app(g, app(s, x'')), y'')))), app(c, app(c, y''))))
APP(app(g, 0), app(c, y)) -> APP(app(g, 0), app(app(app(if, true), app(c, app(app(g, app(s, 0)), y))), app(c, y)))
APP(app(g, x), app(c, y)) -> APP(app(g, x), y)
APP(app(g, x), app(c, y)) -> APP(app(g, app(s, x)), y)


Rules:


app(f, 0) -> true
app(f, 1) -> false
app(f, app(s, x)) -> app(f, x)
app(app(app(if, true), app(s, x)), app(s, y)) -> app(s, x)
app(app(app(if, false), app(s, x)), app(s, y)) -> app(s, y)
app(app(g, x), app(c, y)) -> app(c, app(app(g, x), y))
app(app(g, x), app(c, y)) -> app(app(g, x), app(app(app(if, app(f, x)), app(c, app(app(g, app(s, x)), y))), app(c, y)))


Strategy:

innermost



Innermost Termination of R could not be shown.
Duration:
0:03 minutes