YES

We show the termination of the TRS R:

  O(|0|()) -> |0|()
  +(|0|(),x) -> x
  +(x,|0|()) -> x
  +(O(x),O(y)) -> O(+(x,y))
  +(O(x),I(y)) -> I(+(x,y))
  +(I(x),O(y)) -> I(+(x,y))
  +(I(x),I(y)) -> O(+(+(x,y),I(|0|())))
  *(|0|(),x) -> |0|()
  *(x,|0|()) -> |0|()
  *(O(x),y) -> O(*(x,y))
  *(I(x),y) -> +(O(*(x,y)),y)
  -(x,|0|()) -> x
  -(|0|(),x) -> |0|()
  -(O(x),O(y)) -> O(-(x,y))
  -(O(x),I(y)) -> I(-(-(x,y),I(|1|())))
  -(I(x),O(y)) -> I(-(x,y))
  -(I(x),I(y)) -> O(-(x,y))

-- SCC decomposition.

Consider the dependency pair problem (P, R), where P consists of

p1: +#(O(x),O(y)) -> O#(+(x,y))
p2: +#(O(x),O(y)) -> +#(x,y)
p3: +#(O(x),I(y)) -> +#(x,y)
p4: +#(I(x),O(y)) -> +#(x,y)
p5: +#(I(x),I(y)) -> O#(+(+(x,y),I(|0|())))
p6: +#(I(x),I(y)) -> +#(+(x,y),I(|0|()))
p7: +#(I(x),I(y)) -> +#(x,y)
p8: *#(O(x),y) -> O#(*(x,y))
p9: *#(O(x),y) -> *#(x,y)
p10: *#(I(x),y) -> +#(O(*(x,y)),y)
p11: *#(I(x),y) -> O#(*(x,y))
p12: *#(I(x),y) -> *#(x,y)
p13: -#(O(x),O(y)) -> O#(-(x,y))
p14: -#(O(x),O(y)) -> -#(x,y)
p15: -#(O(x),I(y)) -> -#(-(x,y),I(|1|()))
p16: -#(O(x),I(y)) -> -#(x,y)
p17: -#(I(x),O(y)) -> -#(x,y)
p18: -#(I(x),I(y)) -> O#(-(x,y))
p19: -#(I(x),I(y)) -> -#(x,y)

and R consists of:

r1: O(|0|()) -> |0|()
r2: +(|0|(),x) -> x
r3: +(x,|0|()) -> x
r4: +(O(x),O(y)) -> O(+(x,y))
r5: +(O(x),I(y)) -> I(+(x,y))
r6: +(I(x),O(y)) -> I(+(x,y))
r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|())))
r8: *(|0|(),x) -> |0|()
r9: *(x,|0|()) -> |0|()
r10: *(O(x),y) -> O(*(x,y))
r11: *(I(x),y) -> +(O(*(x,y)),y)
r12: -(x,|0|()) -> x
r13: -(|0|(),x) -> |0|()
r14: -(O(x),O(y)) -> O(-(x,y))
r15: -(O(x),I(y)) -> I(-(-(x,y),I(|1|())))
r16: -(I(x),O(y)) -> I(-(x,y))
r17: -(I(x),I(y)) -> O(-(x,y))

The estimated dependency graph contains the following SCCs:

  {p9, p12}
  {p2, p3, p4, p6, p7}
  {p14, p15, p16, p17, p19}


-- Reduction pair.

Consider the dependency pair problem (P, R), where P consists of

p1: *#(I(x),y) -> *#(x,y)
p2: *#(O(x),y) -> *#(x,y)

and R consists of:

r1: O(|0|()) -> |0|()
r2: +(|0|(),x) -> x
r3: +(x,|0|()) -> x
r4: +(O(x),O(y)) -> O(+(x,y))
r5: +(O(x),I(y)) -> I(+(x,y))
r6: +(I(x),O(y)) -> I(+(x,y))
r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|())))
r8: *(|0|(),x) -> |0|()
r9: *(x,|0|()) -> |0|()
r10: *(O(x),y) -> O(*(x,y))
r11: *(I(x),y) -> +(O(*(x,y)),y)
r12: -(x,|0|()) -> x
r13: -(|0|(),x) -> |0|()
r14: -(O(x),O(y)) -> O(-(x,y))
r15: -(O(x),I(y)) -> I(-(-(x,y),I(|1|())))
r16: -(I(x),O(y)) -> I(-(x,y))
r17: -(I(x),I(y)) -> O(-(x,y))

The set of usable rules consists of

  (no rules)

Take the reduction pair:

  matrix interpretations:
  
    carrier: N^1
    order: standard order
    interpretations:
      *#_A(x1,x2) = x1
      I_A(x1) = x1 + 1
      O_A(x1) = x1

The next rules are strictly ordered:

  p1

We remove them from the problem.

-- SCC decomposition.

Consider the dependency pair problem (P, R), where P consists of

p1: *#(O(x),y) -> *#(x,y)

and R consists of:

r1: O(|0|()) -> |0|()
r2: +(|0|(),x) -> x
r3: +(x,|0|()) -> x
r4: +(O(x),O(y)) -> O(+(x,y))
r5: +(O(x),I(y)) -> I(+(x,y))
r6: +(I(x),O(y)) -> I(+(x,y))
r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|())))
r8: *(|0|(),x) -> |0|()
r9: *(x,|0|()) -> |0|()
r10: *(O(x),y) -> O(*(x,y))
r11: *(I(x),y) -> +(O(*(x,y)),y)
r12: -(x,|0|()) -> x
r13: -(|0|(),x) -> |0|()
r14: -(O(x),O(y)) -> O(-(x,y))
r15: -(O(x),I(y)) -> I(-(-(x,y),I(|1|())))
r16: -(I(x),O(y)) -> I(-(x,y))
r17: -(I(x),I(y)) -> O(-(x,y))

The estimated dependency graph contains the following SCCs:

  {p1}


-- Reduction pair.

Consider the dependency pair problem (P, R), where P consists of

p1: *#(O(x),y) -> *#(x,y)

and R consists of:

r1: O(|0|()) -> |0|()
r2: +(|0|(),x) -> x
r3: +(x,|0|()) -> x
r4: +(O(x),O(y)) -> O(+(x,y))
r5: +(O(x),I(y)) -> I(+(x,y))
r6: +(I(x),O(y)) -> I(+(x,y))
r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|())))
r8: *(|0|(),x) -> |0|()
r9: *(x,|0|()) -> |0|()
r10: *(O(x),y) -> O(*(x,y))
r11: *(I(x),y) -> +(O(*(x,y)),y)
r12: -(x,|0|()) -> x
r13: -(|0|(),x) -> |0|()
r14: -(O(x),O(y)) -> O(-(x,y))
r15: -(O(x),I(y)) -> I(-(-(x,y),I(|1|())))
r16: -(I(x),O(y)) -> I(-(x,y))
r17: -(I(x),I(y)) -> O(-(x,y))

The set of usable rules consists of

  (no rules)

Take the reduction pair:

  matrix interpretations:
  
    carrier: N^1
    order: standard order
    interpretations:
      *#_A(x1,x2) = x1
      O_A(x1) = x1 + 1

The next rules are strictly ordered:

  p1

We remove them from the problem.  Then no dependency pair remains.

-- Reduction pair.

Consider the dependency pair problem (P, R), where P consists of

p1: +#(O(x),O(y)) -> +#(x,y)
p2: +#(I(x),I(y)) -> +#(x,y)
p3: +#(I(x),I(y)) -> +#(+(x,y),I(|0|()))
p4: +#(O(x),I(y)) -> +#(x,y)
p5: +#(I(x),O(y)) -> +#(x,y)

and R consists of:

r1: O(|0|()) -> |0|()
r2: +(|0|(),x) -> x
r3: +(x,|0|()) -> x
r4: +(O(x),O(y)) -> O(+(x,y))
r5: +(O(x),I(y)) -> I(+(x,y))
r6: +(I(x),O(y)) -> I(+(x,y))
r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|())))
r8: *(|0|(),x) -> |0|()
r9: *(x,|0|()) -> |0|()
r10: *(O(x),y) -> O(*(x,y))
r11: *(I(x),y) -> +(O(*(x,y)),y)
r12: -(x,|0|()) -> x
r13: -(|0|(),x) -> |0|()
r14: -(O(x),O(y)) -> O(-(x,y))
r15: -(O(x),I(y)) -> I(-(-(x,y),I(|1|())))
r16: -(I(x),O(y)) -> I(-(x,y))
r17: -(I(x),I(y)) -> O(-(x,y))

The set of usable rules consists of

  r1, r2, r3, r4, r5, r6, r7

Take the reduction pair:

  matrix interpretations:
  
    carrier: N^1
    order: standard order
    interpretations:
      +#_A(x1,x2) = x2
      O_A(x1) = x1
      I_A(x1) = x1 + 1
      +_A(x1,x2) = x1 + x2 + 1
      |0|_A() = 0

The next rules are strictly ordered:

  p2, p4

We remove them from the problem.

-- SCC decomposition.

Consider the dependency pair problem (P, R), where P consists of

p1: +#(O(x),O(y)) -> +#(x,y)
p2: +#(I(x),I(y)) -> +#(+(x,y),I(|0|()))
p3: +#(I(x),O(y)) -> +#(x,y)

and R consists of:

r1: O(|0|()) -> |0|()
r2: +(|0|(),x) -> x
r3: +(x,|0|()) -> x
r4: +(O(x),O(y)) -> O(+(x,y))
r5: +(O(x),I(y)) -> I(+(x,y))
r6: +(I(x),O(y)) -> I(+(x,y))
r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|())))
r8: *(|0|(),x) -> |0|()
r9: *(x,|0|()) -> |0|()
r10: *(O(x),y) -> O(*(x,y))
r11: *(I(x),y) -> +(O(*(x,y)),y)
r12: -(x,|0|()) -> x
r13: -(|0|(),x) -> |0|()
r14: -(O(x),O(y)) -> O(-(x,y))
r15: -(O(x),I(y)) -> I(-(-(x,y),I(|1|())))
r16: -(I(x),O(y)) -> I(-(x,y))
r17: -(I(x),I(y)) -> O(-(x,y))

The estimated dependency graph contains the following SCCs:

  {p1, p3}
  {p2}


-- Reduction pair.

Consider the dependency pair problem (P, R), where P consists of

p1: +#(O(x),O(y)) -> +#(x,y)
p2: +#(I(x),O(y)) -> +#(x,y)

and R consists of:

r1: O(|0|()) -> |0|()
r2: +(|0|(),x) -> x
r3: +(x,|0|()) -> x
r4: +(O(x),O(y)) -> O(+(x,y))
r5: +(O(x),I(y)) -> I(+(x,y))
r6: +(I(x),O(y)) -> I(+(x,y))
r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|())))
r8: *(|0|(),x) -> |0|()
r9: *(x,|0|()) -> |0|()
r10: *(O(x),y) -> O(*(x,y))
r11: *(I(x),y) -> +(O(*(x,y)),y)
r12: -(x,|0|()) -> x
r13: -(|0|(),x) -> |0|()
r14: -(O(x),O(y)) -> O(-(x,y))
r15: -(O(x),I(y)) -> I(-(-(x,y),I(|1|())))
r16: -(I(x),O(y)) -> I(-(x,y))
r17: -(I(x),I(y)) -> O(-(x,y))

The set of usable rules consists of

  (no rules)

Take the monotone reduction pair:

  matrix interpretations:
  
    carrier: N^1
    order: standard order
    interpretations:
      +#_A(x1,x2) = x1 + x2
      O_A(x1) = x1
      I_A(x1) = x1 + 1

The next rules are strictly ordered:

  p2
  r1, r2, r3, r4, r5, r6, r7, r8, r9, r10, r11, r12, r13, r14, r15, r16, r17

We remove them from the problem.

-- SCC decomposition.

Consider the dependency pair problem (P, R), where P consists of

p1: +#(O(x),O(y)) -> +#(x,y)

and R consists of:

  (no rules)

The estimated dependency graph contains the following SCCs:

  {p1}


-- Reduction pair.

Consider the dependency pair problem (P, R), where P consists of

p1: +#(O(x),O(y)) -> +#(x,y)

and R consists of:

  (no rules)

The set of usable rules consists of

  (no rules)

Take the monotone reduction pair:

  matrix interpretations:
  
    carrier: N^1
    order: standard order
    interpretations:
      +#_A(x1,x2) = x1 + x2
      O_A(x1) = x1 + 1

The next rules are strictly ordered:

  p1

We remove them from the problem.  Then no dependency pair remains.

-- Reduction pair.

Consider the dependency pair problem (P, R), where P consists of

p1: +#(I(x),I(y)) -> +#(+(x,y),I(|0|()))

and R consists of:

r1: O(|0|()) -> |0|()
r2: +(|0|(),x) -> x
r3: +(x,|0|()) -> x
r4: +(O(x),O(y)) -> O(+(x,y))
r5: +(O(x),I(y)) -> I(+(x,y))
r6: +(I(x),O(y)) -> I(+(x,y))
r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|())))
r8: *(|0|(),x) -> |0|()
r9: *(x,|0|()) -> |0|()
r10: *(O(x),y) -> O(*(x,y))
r11: *(I(x),y) -> +(O(*(x,y)),y)
r12: -(x,|0|()) -> x
r13: -(|0|(),x) -> |0|()
r14: -(O(x),O(y)) -> O(-(x,y))
r15: -(O(x),I(y)) -> I(-(-(x,y),I(|1|())))
r16: -(I(x),O(y)) -> I(-(x,y))
r17: -(I(x),I(y)) -> O(-(x,y))

The set of usable rules consists of

  r1, r2, r3, r4, r5, r6, r7

Take the monotone reduction pair:

  matrix interpretations:
  
    carrier: N^1
    order: standard order
    interpretations:
      +#_A(x1,x2) = x1 + x2
      I_A(x1) = x1 + 1
      +_A(x1,x2) = x1 + x2
      |0|_A() = 0
      O_A(x1) = x1

The next rules are strictly ordered:

  p1
  r7, r8, r9, r10, r11, r12, r13, r14, r15, r16, r17

We remove them from the problem.  Then no dependency pair remains.

-- Reduction pair.

Consider the dependency pair problem (P, R), where P consists of

p1: -#(O(x),O(y)) -> -#(x,y)
p2: -#(I(x),I(y)) -> -#(x,y)
p3: -#(I(x),O(y)) -> -#(x,y)
p4: -#(O(x),I(y)) -> -#(x,y)
p5: -#(O(x),I(y)) -> -#(-(x,y),I(|1|()))

and R consists of:

r1: O(|0|()) -> |0|()
r2: +(|0|(),x) -> x
r3: +(x,|0|()) -> x
r4: +(O(x),O(y)) -> O(+(x,y))
r5: +(O(x),I(y)) -> I(+(x,y))
r6: +(I(x),O(y)) -> I(+(x,y))
r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|())))
r8: *(|0|(),x) -> |0|()
r9: *(x,|0|()) -> |0|()
r10: *(O(x),y) -> O(*(x,y))
r11: *(I(x),y) -> +(O(*(x,y)),y)
r12: -(x,|0|()) -> x
r13: -(|0|(),x) -> |0|()
r14: -(O(x),O(y)) -> O(-(x,y))
r15: -(O(x),I(y)) -> I(-(-(x,y),I(|1|())))
r16: -(I(x),O(y)) -> I(-(x,y))
r17: -(I(x),I(y)) -> O(-(x,y))

The set of usable rules consists of

  r1, r12, r13, r14, r15, r16, r17

Take the monotone reduction pair:

  matrix interpretations:
  
    carrier: N^1
    order: standard order
    interpretations:
      -#_A(x1,x2) = x1 + x2
      O_A(x1) = x1 + 4
      I_A(x1) = x1 + 2
      -_A(x1,x2) = x1 + x2 + 1
      |1|_A() = 1
      |0|_A() = 1

The next rules are strictly ordered:

  p1, p2, p3, p4, p5
  r1, r2, r3, r4, r5, r6, r7, r8, r9, r10, r11, r12, r13, r14, r16

We remove them from the problem.  Then no dependency pair remains.