644.36/291.47 WORST_CASE(Omega(n^2), ?) 644.36/291.47 proof of /export/starexec/sandbox/benchmark/theBenchmark.xml 644.36/291.47 # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty 644.36/291.47 644.36/291.47 644.36/291.47 The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(n^2, INF). 644.36/291.47 644.36/291.47 (0) CpxTRS 644.36/291.47 (1) RenamingProof [BOTH BOUNDS(ID, ID), 0 ms] 644.36/291.47 (2) CpxTRS 644.36/291.47 (3) TypeInferenceProof [BOTH BOUNDS(ID, ID), 0 ms] 644.36/291.47 (4) typed CpxTrs 644.36/291.47 (5) OrderProof [LOWER BOUND(ID), 0 ms] 644.36/291.47 (6) typed CpxTrs 644.36/291.47 (7) RewriteLemmaProof [LOWER BOUND(ID), 265 ms] 644.36/291.47 (8) BEST 644.36/291.47 (9) proven lower bound 644.36/291.47 (10) LowerBoundPropagationProof [FINISHED, 0 ms] 644.36/291.47 (11) BOUNDS(n^1, INF) 644.36/291.47 (12) typed CpxTrs 644.36/291.47 (13) RewriteLemmaProof [LOWER BOUND(ID), 52 ms] 644.36/291.47 (14) BEST 644.36/291.47 (15) proven lower bound 644.36/291.47 (16) LowerBoundPropagationProof [FINISHED, 0 ms] 644.36/291.47 (17) BOUNDS(n^2, INF) 644.36/291.47 (18) typed CpxTrs 644.36/291.47 (19) RewriteLemmaProof [LOWER BOUND(ID), 698 ms] 644.36/291.47 (20) BOUNDS(1, INF) 644.36/291.47 644.36/291.47 644.36/291.47 ---------------------------------------- 644.36/291.47 644.36/291.47 (0) 644.36/291.47 Obligation: 644.36/291.47 The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(n^2, INF). 644.36/291.47 644.36/291.47 644.36/291.47 The TRS R consists of the following rules: 644.36/291.47 644.36/291.47 p(s(x)) -> x 644.36/291.47 fact(0) -> s(0) 644.36/291.47 fact(s(x)) -> *(s(x), fact(p(s(x)))) 644.36/291.47 *(0, y) -> 0 644.36/291.47 *(s(x), y) -> +(*(x, y), y) 644.36/291.47 +(x, 0) -> x 644.36/291.47 +(x, s(y)) -> s(+(x, y)) 644.36/291.47 644.36/291.47 S is empty. 644.36/291.47 Rewrite Strategy: INNERMOST 644.36/291.47 ---------------------------------------- 644.36/291.47 644.36/291.47 (1) RenamingProof (BOTH BOUNDS(ID, ID)) 644.36/291.47 Renamed function symbols to avoid clashes with predefined symbol. 644.36/291.47 ---------------------------------------- 644.36/291.47 644.36/291.47 (2) 644.36/291.47 Obligation: 644.36/291.47 The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(n^2, INF). 644.36/291.47 644.36/291.47 644.36/291.47 The TRS R consists of the following rules: 644.36/291.47 644.36/291.47 p(s(x)) -> x 644.36/291.47 fact(0') -> s(0') 644.36/291.47 fact(s(x)) -> *'(s(x), fact(p(s(x)))) 644.36/291.47 *'(0', y) -> 0' 644.36/291.47 *'(s(x), y) -> +'(*'(x, y), y) 644.36/291.47 +'(x, 0') -> x 644.36/291.47 +'(x, s(y)) -> s(+'(x, y)) 644.36/291.47 644.36/291.47 S is empty. 644.36/291.47 Rewrite Strategy: INNERMOST 644.36/291.47 ---------------------------------------- 644.36/291.47 644.36/291.47 (3) TypeInferenceProof (BOTH BOUNDS(ID, ID)) 644.36/291.47 Infered types. 644.36/291.47 ---------------------------------------- 644.36/291.47 644.36/291.47 (4) 644.36/291.47 Obligation: 644.36/291.47 Innermost TRS: 644.36/291.47 Rules: 644.36/291.47 p(s(x)) -> x 644.36/291.47 fact(0') -> s(0') 644.36/291.47 fact(s(x)) -> *'(s(x), fact(p(s(x)))) 644.36/291.47 *'(0', y) -> 0' 644.36/291.47 *'(s(x), y) -> +'(*'(x, y), y) 644.36/291.47 +'(x, 0') -> x 644.36/291.47 +'(x, s(y)) -> s(+'(x, y)) 644.36/291.47 644.36/291.47 Types: 644.36/291.47 p :: s:0' -> s:0' 644.36/291.47 s :: s:0' -> s:0' 644.36/291.47 fact :: s:0' -> s:0' 644.36/291.47 0' :: s:0' 644.36/291.47 *' :: s:0' -> s:0' -> s:0' 644.36/291.47 +' :: s:0' -> s:0' -> s:0' 644.36/291.47 hole_s:0'1_0 :: s:0' 644.36/291.47 gen_s:0'2_0 :: Nat -> s:0' 644.36/291.47 644.36/291.47 ---------------------------------------- 644.36/291.47 644.36/291.47 (5) OrderProof (LOWER BOUND(ID)) 644.36/291.47 Heuristically decided to analyse the following defined symbols: 644.36/291.47 fact, *', +' 644.36/291.47 644.36/291.47 They will be analysed ascendingly in the following order: 644.36/291.47 *' < fact 644.36/291.47 +' < *' 644.36/291.47 644.36/291.47 ---------------------------------------- 644.36/291.47 644.36/291.47 (6) 644.36/291.47 Obligation: 644.36/291.47 Innermost TRS: 644.36/291.47 Rules: 644.36/291.47 p(s(x)) -> x 644.36/291.47 fact(0') -> s(0') 644.36/291.47 fact(s(x)) -> *'(s(x), fact(p(s(x)))) 644.36/291.47 *'(0', y) -> 0' 644.36/291.47 *'(s(x), y) -> +'(*'(x, y), y) 644.36/291.47 +'(x, 0') -> x 644.36/291.47 +'(x, s(y)) -> s(+'(x, y)) 644.36/291.47 644.36/291.47 Types: 644.36/291.47 p :: s:0' -> s:0' 644.36/291.47 s :: s:0' -> s:0' 644.36/291.47 fact :: s:0' -> s:0' 644.36/291.47 0' :: s:0' 644.36/291.47 *' :: s:0' -> s:0' -> s:0' 644.36/291.47 +' :: s:0' -> s:0' -> s:0' 644.36/291.47 hole_s:0'1_0 :: s:0' 644.36/291.47 gen_s:0'2_0 :: Nat -> s:0' 644.36/291.47 644.36/291.47 644.36/291.47 Generator Equations: 644.36/291.47 gen_s:0'2_0(0) <=> 0' 644.36/291.47 gen_s:0'2_0(+(x, 1)) <=> s(gen_s:0'2_0(x)) 644.36/291.47 644.36/291.47 644.36/291.47 The following defined symbols remain to be analysed: 644.36/291.47 +', fact, *' 644.36/291.47 644.36/291.47 They will be analysed ascendingly in the following order: 644.36/291.47 *' < fact 644.36/291.47 +' < *' 644.36/291.47 644.36/291.47 ---------------------------------------- 644.36/291.47 644.36/291.47 (7) RewriteLemmaProof (LOWER BOUND(ID)) 644.36/291.47 Proved the following rewrite lemma: 644.36/291.47 +'(gen_s:0'2_0(a), gen_s:0'2_0(n4_0)) -> gen_s:0'2_0(+(n4_0, a)), rt in Omega(1 + n4_0) 644.36/291.47 644.36/291.47 Induction Base: 644.36/291.47 +'(gen_s:0'2_0(a), gen_s:0'2_0(0)) ->_R^Omega(1) 644.36/291.47 gen_s:0'2_0(a) 644.36/291.47 644.36/291.47 Induction Step: 644.36/291.47 +'(gen_s:0'2_0(a), gen_s:0'2_0(+(n4_0, 1))) ->_R^Omega(1) 644.36/291.47 s(+'(gen_s:0'2_0(a), gen_s:0'2_0(n4_0))) ->_IH 644.36/291.47 s(gen_s:0'2_0(+(a, c5_0))) 644.36/291.47 644.36/291.47 We have rt in Omega(n^1) and sz in O(n). Thus, we have irc_R in Omega(n). 644.36/291.47 ---------------------------------------- 644.36/291.47 644.36/291.47 (8) 644.36/291.47 Complex Obligation (BEST) 644.36/291.47 644.36/291.47 ---------------------------------------- 644.36/291.47 644.36/291.47 (9) 644.36/291.47 Obligation: 644.36/291.47 Proved the lower bound n^1 for the following obligation: 644.36/291.47 644.36/291.47 Innermost TRS: 644.36/291.47 Rules: 644.36/291.47 p(s(x)) -> x 644.36/291.47 fact(0') -> s(0') 644.36/291.48 fact(s(x)) -> *'(s(x), fact(p(s(x)))) 644.36/291.48 *'(0', y) -> 0' 644.36/291.48 *'(s(x), y) -> +'(*'(x, y), y) 644.36/291.48 +'(x, 0') -> x 644.36/291.48 +'(x, s(y)) -> s(+'(x, y)) 644.36/291.48 644.36/291.48 Types: 644.36/291.48 p :: s:0' -> s:0' 644.36/291.48 s :: s:0' -> s:0' 644.36/291.48 fact :: s:0' -> s:0' 644.36/291.48 0' :: s:0' 644.36/291.48 *' :: s:0' -> s:0' -> s:0' 644.36/291.48 +' :: s:0' -> s:0' -> s:0' 644.36/291.48 hole_s:0'1_0 :: s:0' 644.36/291.48 gen_s:0'2_0 :: Nat -> s:0' 644.36/291.48 644.36/291.48 644.36/291.48 Generator Equations: 644.36/291.48 gen_s:0'2_0(0) <=> 0' 644.36/291.48 gen_s:0'2_0(+(x, 1)) <=> s(gen_s:0'2_0(x)) 644.36/291.48 644.36/291.48 644.36/291.48 The following defined symbols remain to be analysed: 644.36/291.48 +', fact, *' 644.36/291.48 644.36/291.48 They will be analysed ascendingly in the following order: 644.36/291.48 *' < fact 644.36/291.48 +' < *' 644.36/291.48 644.36/291.48 ---------------------------------------- 644.36/291.48 644.36/291.48 (10) LowerBoundPropagationProof (FINISHED) 644.36/291.48 Propagated lower bound. 644.36/291.48 ---------------------------------------- 644.36/291.48 644.36/291.48 (11) 644.36/291.48 BOUNDS(n^1, INF) 644.36/291.48 644.36/291.48 ---------------------------------------- 644.36/291.48 644.36/291.48 (12) 644.36/291.48 Obligation: 644.36/291.48 Innermost TRS: 644.36/291.48 Rules: 644.36/291.48 p(s(x)) -> x 644.36/291.48 fact(0') -> s(0') 644.36/291.48 fact(s(x)) -> *'(s(x), fact(p(s(x)))) 644.36/291.48 *'(0', y) -> 0' 644.36/291.48 *'(s(x), y) -> +'(*'(x, y), y) 644.36/291.48 +'(x, 0') -> x 644.36/291.48 +'(x, s(y)) -> s(+'(x, y)) 644.36/291.48 644.36/291.48 Types: 644.36/291.48 p :: s:0' -> s:0' 644.36/291.48 s :: s:0' -> s:0' 644.36/291.48 fact :: s:0' -> s:0' 644.36/291.48 0' :: s:0' 644.36/291.48 *' :: s:0' -> s:0' -> s:0' 644.36/291.48 +' :: s:0' -> s:0' -> s:0' 644.36/291.48 hole_s:0'1_0 :: s:0' 644.36/291.48 gen_s:0'2_0 :: Nat -> s:0' 644.36/291.48 644.36/291.48 644.36/291.48 Lemmas: 644.36/291.48 +'(gen_s:0'2_0(a), gen_s:0'2_0(n4_0)) -> gen_s:0'2_0(+(n4_0, a)), rt in Omega(1 + n4_0) 644.36/291.48 644.36/291.48 644.36/291.48 Generator Equations: 644.36/291.48 gen_s:0'2_0(0) <=> 0' 644.36/291.48 gen_s:0'2_0(+(x, 1)) <=> s(gen_s:0'2_0(x)) 644.36/291.48 644.36/291.48 644.36/291.48 The following defined symbols remain to be analysed: 644.36/291.48 *', fact 644.36/291.48 644.36/291.48 They will be analysed ascendingly in the following order: 644.36/291.48 *' < fact 644.36/291.48 644.36/291.48 ---------------------------------------- 644.36/291.48 644.36/291.48 (13) RewriteLemmaProof (LOWER BOUND(ID)) 644.36/291.48 Proved the following rewrite lemma: 644.36/291.48 *'(gen_s:0'2_0(n513_0), gen_s:0'2_0(b)) -> gen_s:0'2_0(*(n513_0, b)), rt in Omega(1 + b*n513_0 + n513_0) 644.36/291.48 644.36/291.48 Induction Base: 644.36/291.48 *'(gen_s:0'2_0(0), gen_s:0'2_0(b)) ->_R^Omega(1) 644.36/291.48 0' 644.36/291.48 644.36/291.48 Induction Step: 644.36/291.48 *'(gen_s:0'2_0(+(n513_0, 1)), gen_s:0'2_0(b)) ->_R^Omega(1) 644.36/291.48 +'(*'(gen_s:0'2_0(n513_0), gen_s:0'2_0(b)), gen_s:0'2_0(b)) ->_IH 644.36/291.48 +'(gen_s:0'2_0(*(c514_0, b)), gen_s:0'2_0(b)) ->_L^Omega(1 + b) 644.36/291.48 gen_s:0'2_0(+(b, *(n513_0, b))) 644.36/291.48 644.36/291.48 We have rt in Omega(n^2) and sz in O(n). Thus, we have irc_R in Omega(n^2). 644.36/291.48 ---------------------------------------- 644.36/291.48 644.36/291.48 (14) 644.36/291.48 Complex Obligation (BEST) 644.36/291.48 644.36/291.48 ---------------------------------------- 644.36/291.48 644.36/291.48 (15) 644.36/291.48 Obligation: 644.36/291.48 Proved the lower bound n^2 for the following obligation: 644.36/291.48 644.36/291.48 Innermost TRS: 644.36/291.48 Rules: 644.36/291.48 p(s(x)) -> x 644.36/291.48 fact(0') -> s(0') 644.36/291.48 fact(s(x)) -> *'(s(x), fact(p(s(x)))) 644.36/291.48 *'(0', y) -> 0' 644.36/291.48 *'(s(x), y) -> +'(*'(x, y), y) 644.36/291.48 +'(x, 0') -> x 644.36/291.48 +'(x, s(y)) -> s(+'(x, y)) 644.36/291.48 644.36/291.48 Types: 644.36/291.48 p :: s:0' -> s:0' 644.36/291.48 s :: s:0' -> s:0' 644.36/291.48 fact :: s:0' -> s:0' 644.36/291.48 0' :: s:0' 644.36/291.48 *' :: s:0' -> s:0' -> s:0' 644.36/291.48 +' :: s:0' -> s:0' -> s:0' 644.36/291.48 hole_s:0'1_0 :: s:0' 644.36/291.48 gen_s:0'2_0 :: Nat -> s:0' 644.36/291.48 644.36/291.48 644.36/291.48 Lemmas: 644.36/291.48 +'(gen_s:0'2_0(a), gen_s:0'2_0(n4_0)) -> gen_s:0'2_0(+(n4_0, a)), rt in Omega(1 + n4_0) 644.36/291.48 644.36/291.48 644.36/291.48 Generator Equations: 644.36/291.48 gen_s:0'2_0(0) <=> 0' 644.36/291.48 gen_s:0'2_0(+(x, 1)) <=> s(gen_s:0'2_0(x)) 644.36/291.48 644.36/291.48 644.36/291.48 The following defined symbols remain to be analysed: 644.36/291.48 *', fact 644.36/291.48 644.36/291.48 They will be analysed ascendingly in the following order: 644.36/291.48 *' < fact 644.36/291.48 644.36/291.48 ---------------------------------------- 644.36/291.48 644.36/291.48 (16) LowerBoundPropagationProof (FINISHED) 644.36/291.48 Propagated lower bound. 644.36/291.48 ---------------------------------------- 644.36/291.48 644.36/291.48 (17) 644.36/291.48 BOUNDS(n^2, INF) 644.36/291.48 644.36/291.48 ---------------------------------------- 644.36/291.48 644.36/291.48 (18) 644.36/291.48 Obligation: 644.36/291.48 Innermost TRS: 644.36/291.48 Rules: 644.36/291.48 p(s(x)) -> x 644.36/291.48 fact(0') -> s(0') 644.36/291.48 fact(s(x)) -> *'(s(x), fact(p(s(x)))) 644.36/291.48 *'(0', y) -> 0' 644.36/291.48 *'(s(x), y) -> +'(*'(x, y), y) 644.36/291.48 +'(x, 0') -> x 644.36/291.48 +'(x, s(y)) -> s(+'(x, y)) 644.36/291.48 644.36/291.48 Types: 644.36/291.48 p :: s:0' -> s:0' 644.36/291.48 s :: s:0' -> s:0' 644.36/291.48 fact :: s:0' -> s:0' 644.36/291.48 0' :: s:0' 644.36/291.48 *' :: s:0' -> s:0' -> s:0' 644.36/291.48 +' :: s:0' -> s:0' -> s:0' 644.36/291.48 hole_s:0'1_0 :: s:0' 644.36/291.48 gen_s:0'2_0 :: Nat -> s:0' 644.36/291.48 644.36/291.48 644.36/291.48 Lemmas: 644.36/291.48 +'(gen_s:0'2_0(a), gen_s:0'2_0(n4_0)) -> gen_s:0'2_0(+(n4_0, a)), rt in Omega(1 + n4_0) 644.36/291.48 *'(gen_s:0'2_0(n513_0), gen_s:0'2_0(b)) -> gen_s:0'2_0(*(n513_0, b)), rt in Omega(1 + b*n513_0 + n513_0) 644.36/291.48 644.36/291.48 644.36/291.48 Generator Equations: 644.36/291.48 gen_s:0'2_0(0) <=> 0' 644.36/291.48 gen_s:0'2_0(+(x, 1)) <=> s(gen_s:0'2_0(x)) 644.36/291.48 644.36/291.48 644.36/291.48 The following defined symbols remain to be analysed: 644.36/291.48 fact 644.36/291.48 ---------------------------------------- 644.36/291.48 644.36/291.48 (19) RewriteLemmaProof (LOWER BOUND(ID)) 644.36/291.48 Proved the following rewrite lemma: 644.36/291.48 fact(gen_s:0'2_0(n1126_0)) -> *3_0, rt in Omega(n1126_0) 644.36/291.48 644.36/291.48 Induction Base: 644.36/291.48 fact(gen_s:0'2_0(0)) 644.36/291.48 644.36/291.48 Induction Step: 644.36/291.48 fact(gen_s:0'2_0(+(n1126_0, 1))) ->_R^Omega(1) 644.36/291.48 *'(s(gen_s:0'2_0(n1126_0)), fact(p(s(gen_s:0'2_0(n1126_0))))) ->_R^Omega(1) 644.36/291.48 *'(s(gen_s:0'2_0(n1126_0)), fact(gen_s:0'2_0(n1126_0))) ->_IH 644.36/291.48 *'(s(gen_s:0'2_0(n1126_0)), *3_0) 644.36/291.48 644.36/291.48 We have rt in Omega(n^1) and sz in O(n). Thus, we have irc_R in Omega(n). 644.36/291.48 ---------------------------------------- 644.36/291.48 644.36/291.48 (20) 644.36/291.48 BOUNDS(1, INF) 644.45/291.52 EOF