YES Termination proof of AG_#3.7_rand.trs

(0) Obligation:

Relative term rewrite system:
The relative TRS consists of the following R rules:

half(0) → 0
half(s(s(x))) → s(half(x))
log(s(0)) → 0
log(s(s(x))) → s(log(s(half(x))))

The relative TRS consists of the following S rules:

rand(x) → rand(s(x))
rand(x) → x

(1) RelTRStoRelADPProof (EQUIVALENT transformation)

We upgrade the RelTRS problem to an equivalent Relative ADP Problem [IJCAR24].

(2) Obligation:

Relative ADP Problem with
absolute ADPs:

half(0) → 0
half(s(s(x))) → s(HALF(x))
log(s(0)) → 0
log(s(s(x))) → s(LOG(s(half(x))))
log(s(s(x))) → s(log(s(HALF(x))))

and relative ADPs:

rand(x) → RAND(s(x))
rand(x) → x

(3) RelADPDepGraphProof (EQUIVALENT transformation)

We use the relative dependency graph processor [IJCAR24].
The approximation of the Relative Dependency Graph contains:
2 SCCs with nodes from P_abs,
0 Lassos,
Result: This relative DT problem is equivalent to 2 subproblems.

(4) Complex Obligation (AND)

(5) Obligation:

Relative ADP Problem with
absolute ADPs:

half(s(s(x))) → s(HALF(x))
log(s(0)) → 0
half(0) → 0
log(s(s(x))) → s(log(s(half(x))))

and relative ADPs:

rand(x) → rand(s(x))
rand(x) → x

(6) RelADPCleverAfsProof (SOUND transformation)

We use the first derelatifying processor [IJCAR24].
There are no annotations in relative ADPs, so the relative ADP problem can be transformed into a non-relative DP problem.

Furthermore, We use an argument filter [LPAR04].
Filtering:s_1 = half_1 = log_1 = 0 = rand_1 = HALF_1 =
Found this filtering by looking at the following order that orders at least one DP strictly:Combined order from the following AFS and order.
HALF(x1)  =  HALF(x1)
s(x1)  =  s(x1)
log(x1)  =  log(x1)
0  =  0
half(x1)  =  x1

Recursive path order with status [RPO].
Quasi-Precedence:

HALF1 > s1
[log1, 0] > s1

Status:
HALF1: [1]
s1: multiset
log1: multiset
0: multiset

(7) Obligation:

Q DP problem:
The TRS P consists of the following rules:

HALF0(s0(s0(x))) → HALF0(x)

The TRS R consists of the following rules:

log0(s0(00)) → 00
half0(s0(s0(x))) → s0(half0(x))
half0(00) → 00
log0(s0(s0(x))) → s0(log0(s0(half0(x))))
rand0(x) → rand0(s0(x))
rand0(x) → x

Q is empty.
We have to consider all (P,Q,R)-chains.

(8) MRRProof (EQUIVALENT transformation)

By using the rule removal processor [LPAR04] with the following ordering, at least one Dependency Pair or term rewrite system rule of this QDP problem can be strictly oriented.

Strictly oriented rules of the TRS R:

log0(s0(00)) → 00
rand0(x) → x

Used ordering: Polynomial interpretation [POLO]:

POL(00) = 1   
POL(HALF0(x1)) = x1   
POL(half0(x1)) = x1   
POL(log0(x1)) = 2 + x1   
POL(rand0(x1)) = 2 + x1   
POL(s0(x1)) = x1   

(9) Obligation:

Q DP problem:
The TRS P consists of the following rules:

HALF0(s0(s0(x))) → HALF0(x)

The TRS R consists of the following rules:

half0(s0(s0(x))) → s0(half0(x))
half0(00) → 00
log0(s0(s0(x))) → s0(log0(s0(half0(x))))
rand0(x) → rand0(s0(x))

Q is empty.
We have to consider all (P,Q,R)-chains.

(10) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04,JAR06].


The following pairs can be oriented strictly and are deleted.


HALF0(s0(s0(x))) → HALF0(x)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
HALF0(x1)  =  HALF0(x1)
s0(x1)  =  s0(x1)
half0(x1)  =  x1
00  =  00
log0(x1)  =  log0(x1)
rand0(x1)  =  rand0

Recursive path order with status [RPO].
Quasi-Precedence:
rand0 > [s01, log01]

Status:
HALF01: [1]
s01: [1]
00: multiset
log01: [1]
rand0: multiset


The following usable rules [FROCOS05] with respect to the argument filtering of the ordering [JAR06] were oriented:

half0(s0(s0(x))) → s0(half0(x))
half0(00) → 00
log0(s0(s0(x))) → s0(log0(s0(half0(x))))
rand0(x) → rand0(s0(x))

(11) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

half0(s0(s0(x))) → s0(half0(x))
half0(00) → 00
log0(s0(s0(x))) → s0(log0(s0(half0(x))))
rand0(x) → rand0(s0(x))

Q is empty.
We have to consider all (P,Q,R)-chains.

(12) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(13) YES

(14) Obligation:

Relative ADP Problem with
absolute ADPs:

log(s(0)) → 0
half(s(s(x))) → s(half(x))
half(0) → 0
log(s(s(x))) → s(log(s(half(x))))
log(s(s(x))) → s(LOG(s(half(x))))

and relative ADPs:

rand(x) → rand(s(x))
rand(x) → x

(15) RelADPCleverAfsProof (SOUND transformation)

We use the first derelatifying processor [IJCAR24].
There are no annotations in relative ADPs, so the relative ADP problem can be transformed into a non-relative DP problem.

Furthermore, We use an argument filter [LPAR04].
Filtering:s_1 = half_1 = log_1 = 0 = rand_1 = LOG_1 =
Found this filtering by looking at the following order that orders at least one DP strictly:Combined order from the following AFS and order.
LOG(x1)  =  LOG(x1)
s(x1)  =  s(x1)
half(x1)  =  x1
log(x1)  =  log(x1)
0  =  0

Recursive path order with status [RPO].
Quasi-Precedence:

0 > [LOG1, s1, log1]

Status:
LOG1: multiset
s1: multiset
log1: multiset
0: multiset

(16) Obligation:

Q DP problem:
The TRS P consists of the following rules:

LOG0(s0(s0(x))) → LOG0(s0(half0(x)))

The TRS R consists of the following rules:

log0(s0(00)) → 00
half0(s0(s0(x))) → s0(half0(x))
half0(00) → 00
log0(s0(s0(x))) → s0(log0(s0(half0(x))))
rand0(x) → rand0(s0(x))
rand0(x) → x

Q is empty.
We have to consider all (P,Q,R)-chains.

(17) MRRProof (EQUIVALENT transformation)

By using the rule removal processor [LPAR04] with the following ordering, at least one Dependency Pair or term rewrite system rule of this QDP problem can be strictly oriented.

Strictly oriented rules of the TRS R:

log0(s0(00)) → 00
rand0(x) → x

Used ordering: Polynomial interpretation [POLO]:

POL(00) = 1   
POL(LOG0(x1)) = x1   
POL(half0(x1)) = x1   
POL(log0(x1)) = 2 + x1   
POL(rand0(x1)) = 2 + x1   
POL(s0(x1)) = x1   

(18) Obligation:

Q DP problem:
The TRS P consists of the following rules:

LOG0(s0(s0(x))) → LOG0(s0(half0(x)))

The TRS R consists of the following rules:

half0(s0(s0(x))) → s0(half0(x))
half0(00) → 00
log0(s0(s0(x))) → s0(log0(s0(half0(x))))
rand0(x) → rand0(s0(x))

Q is empty.
We have to consider all (P,Q,R)-chains.

(19) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04,JAR06].


The following pairs can be oriented strictly and are deleted.


LOG0(s0(s0(x))) → LOG0(s0(half0(x)))
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
LOG0(x1)  =  LOG0(x1)
s0(x1)  =  s0(x1)
half0(x1)  =  x1
00  =  00
log0(x1)  =  log0(x1)
rand0(x1)  =  rand0

Recursive path order with status [RPO].
Quasi-Precedence:
LOG01 > [s01, log01]
rand0 > [s01, log01]

Status:
LOG01: [1]
s01: multiset
00: multiset
log01: multiset
rand0: multiset


The following usable rules [FROCOS05] with respect to the argument filtering of the ordering [JAR06] were oriented:

half0(s0(s0(x))) → s0(half0(x))
half0(00) → 00
log0(s0(s0(x))) → s0(log0(s0(half0(x))))
rand0(x) → rand0(s0(x))

(20) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

half0(s0(s0(x))) → s0(half0(x))
half0(00) → 00
log0(s0(s0(x))) → s0(log0(s0(half0(x))))
rand0(x) → rand0(s0(x))

Q is empty.
We have to consider all (P,Q,R)-chains.

(21) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(22) YES