MAYBE proof of input_9P6XHdgT9t.trs # AProVE Commit ID: aff8ecad908e01718a4c36e68d2e55d5e0f16e15 fuhs 20220216 unpublished The Runtime Complexity (parallel-innermost) of the given CpxTRS could be proven to be BOUNDS(1, INF). (0) CpxTRS (1) RenamingProof [BOTH BOUNDS(ID, ID), 0 ms] (2) CpxTRS (3) RelTrsToTrsProof [UPPER BOUND(ID), 0 ms] (4) CpxTRS (5) RelTrsToWeightedTrsProof [UPPER BOUND(ID), 0 ms] (6) CpxWeightedTrs (7) TypeInferenceProof [BOTH BOUNDS(ID, ID), 0 ms] (8) CpxTypedWeightedTrs (9) CompletionProof [UPPER BOUND(ID), 0 ms] (10) CpxTypedWeightedCompleteTrs (11) CpxTypedWeightedTrsToRntsProof [UPPER BOUND(ID), 0 ms] (12) CpxRNTS (13) CompletionProof [UPPER BOUND(ID), 0 ms] (14) CpxTypedWeightedCompleteTrs (15) NarrowingProof [BOTH BOUNDS(ID, ID), 0 ms] (16) CpxTypedWeightedCompleteTrs (17) CpxTypedWeightedTrsToRntsProof [UPPER BOUND(ID), 0 ms] (18) CpxRNTS (19) SimplificationProof [BOTH BOUNDS(ID, ID), 0 ms] (20) CpxRNTS (21) CpxRntsAnalysisOrderProof [BOTH BOUNDS(ID, ID), 0 ms] (22) CpxRNTS (23) ResultPropagationProof [UPPER BOUND(ID), 0 ms] (24) CpxRNTS (25) IntTrsBoundProof [UPPER BOUND(ID), 1266 ms] (26) CpxRNTS (27) IntTrsBoundProof [UPPER BOUND(ID), 332 ms] (28) CpxRNTS (29) CpxTrsToCdtProof [UPPER BOUND(ID), 0 ms] (30) CdtProblem (31) CdtLeafRemovalProof [ComplexityIfPolyImplication, 0 ms] (32) CdtProblem (33) CdtUsableRulesProof [BOTH BOUNDS(ID, ID), 0 ms] (34) CdtProblem ---------------------------------------- (0) Obligation: The Runtime Complexity (parallel-innermost) of the given CpxTRS could be proven to be BOUNDS(1, INF). The TRS R consists of the following rules: g(Cons(x, xs), y) -> Cons(x, xs) h(Nil, y) -> h(Nil, y) h(Cons(x, xs), y) -> f(Cons(x, xs), y) g(Nil, y) -> h(Nil, y) f(Nil, y) -> g(Nil, y) f(Cons(x, xs), y) -> h(Cons(x, xs), y) sp1(x, y) -> f(x, y) r(x, y) -> x S is empty. Rewrite Strategy: PARALLEL_INNERMOST ---------------------------------------- (1) RenamingProof (BOTH BOUNDS(ID, ID)) Renamed function symbols to avoid clashes with predefined symbol. ---------------------------------------- (2) Obligation: The Runtime Complexity (parallel-innermost) of the given CpxTRS could be proven to be BOUNDS(1, INF). The TRS R consists of the following rules: g(Cons(x, xs), y) -> Cons(x, xs) h(Nil, y) -> h(Nil, y) h(Cons(x, xs), y) -> f(Cons(x, xs), y) g(Nil, y) -> h(Nil, y) f(Nil, y) -> g(Nil, y) f(Cons(x, xs), y) -> h(Cons(x, xs), y) sp1(x, y) -> f(x, y) r(x, y) -> x S is empty. Rewrite Strategy: PARALLEL_INNERMOST ---------------------------------------- (3) RelTrsToTrsProof (UPPER BOUND(ID)) transformed relative TRS to TRS ---------------------------------------- (4) Obligation: The Runtime Complexity (parallel-innermost) of the given CpxTRS could be proven to be BOUNDS(1, INF). The TRS R consists of the following rules: g(Cons(x, xs), y) -> Cons(x, xs) h(Nil, y) -> h(Nil, y) h(Cons(x, xs), y) -> f(Cons(x, xs), y) g(Nil, y) -> h(Nil, y) f(Nil, y) -> g(Nil, y) f(Cons(x, xs), y) -> h(Cons(x, xs), y) sp1(x, y) -> f(x, y) r(x, y) -> x S is empty. Rewrite Strategy: PARALLEL_INNERMOST ---------------------------------------- (5) RelTrsToWeightedTrsProof (UPPER BOUND(ID)) Transformed relative TRS to weighted TRS ---------------------------------------- (6) Obligation: The Runtime Complexity (innermost) of the given CpxWeightedTrs could be proven to be BOUNDS(1, INF). The TRS R consists of the following rules: g(Cons(x, xs), y) -> Cons(x, xs) [1] h(Nil, y) -> h(Nil, y) [1] h(Cons(x, xs), y) -> f(Cons(x, xs), y) [1] g(Nil, y) -> h(Nil, y) [1] f(Nil, y) -> g(Nil, y) [1] f(Cons(x, xs), y) -> h(Cons(x, xs), y) [1] sp1(x, y) -> f(x, y) [1] r(x, y) -> x [1] Rewrite Strategy: INNERMOST ---------------------------------------- (7) TypeInferenceProof (BOTH BOUNDS(ID, ID)) Infered types. ---------------------------------------- (8) Obligation: Runtime Complexity Weighted TRS with Types. The TRS R consists of the following rules: g(Cons(x, xs), y) -> Cons(x, xs) [1] h(Nil, y) -> h(Nil, y) [1] h(Cons(x, xs), y) -> f(Cons(x, xs), y) [1] g(Nil, y) -> h(Nil, y) [1] f(Nil, y) -> g(Nil, y) [1] f(Cons(x, xs), y) -> h(Cons(x, xs), y) [1] sp1(x, y) -> f(x, y) [1] r(x, y) -> x [1] The TRS has the following type information: g :: Cons:Nil -> c -> Cons:Nil Cons :: a -> b -> Cons:Nil h :: Cons:Nil -> c -> Cons:Nil Nil :: Cons:Nil f :: Cons:Nil -> c -> Cons:Nil sp1 :: Cons:Nil -> c -> Cons:Nil r :: r -> d -> r Rewrite Strategy: INNERMOST ---------------------------------------- (9) CompletionProof (UPPER BOUND(ID)) The TRS is a completely defined constructor system, as every type has a constant constructor and the following rules were added: none And the following fresh constants: const, const1, const2, const3, const4 ---------------------------------------- (10) Obligation: Runtime Complexity Weighted TRS where all functions are completely defined. The underlying TRS is: Runtime Complexity Weighted TRS with Types. The TRS R consists of the following rules: g(Cons(x, xs), y) -> Cons(x, xs) [1] h(Nil, y) -> h(Nil, y) [1] h(Cons(x, xs), y) -> f(Cons(x, xs), y) [1] g(Nil, y) -> h(Nil, y) [1] f(Nil, y) -> g(Nil, y) [1] f(Cons(x, xs), y) -> h(Cons(x, xs), y) [1] sp1(x, y) -> f(x, y) [1] r(x, y) -> x [1] The TRS has the following type information: g :: Cons:Nil -> c -> Cons:Nil Cons :: a -> b -> Cons:Nil h :: Cons:Nil -> c -> Cons:Nil Nil :: Cons:Nil f :: Cons:Nil -> c -> Cons:Nil sp1 :: Cons:Nil -> c -> Cons:Nil r :: r -> d -> r const :: c const1 :: a const2 :: b const3 :: r const4 :: d Rewrite Strategy: INNERMOST ---------------------------------------- (11) CpxTypedWeightedTrsToRntsProof (UPPER BOUND(ID)) Transformed the TRS into an over-approximating RNTS by (improved) Size Abstraction. The constant constructors are abstracted as follows: Nil => 0 const => 0 const1 => 0 const2 => 0 const3 => 0 const4 => 0 ---------------------------------------- (12) Obligation: Complexity RNTS consisting of the following rules: f(z, z') -{ 1 }-> h(1 + x + xs, y) :|: z = 1 + x + xs, xs >= 0, x >= 0, y >= 0, z' = y f(z, z') -{ 1 }-> g(0, y) :|: y >= 0, z = 0, z' = y g(z, z') -{ 1 }-> h(0, y) :|: y >= 0, z = 0, z' = y g(z, z') -{ 1 }-> 1 + x + xs :|: z = 1 + x + xs, xs >= 0, x >= 0, y >= 0, z' = y h(z, z') -{ 1 }-> h(0, y) :|: y >= 0, z = 0, z' = y h(z, z') -{ 1 }-> f(1 + x + xs, y) :|: z = 1 + x + xs, xs >= 0, x >= 0, y >= 0, z' = y r(z, z') -{ 1 }-> x :|: x >= 0, y >= 0, z = x, z' = y sp1(z, z') -{ 1 }-> f(x, y) :|: x >= 0, y >= 0, z = x, z' = y Only complete derivations are relevant for the runtime complexity. ---------------------------------------- (13) CompletionProof (UPPER BOUND(ID)) The transformation into a RNTS is sound, since: (a) The obligation is a constructor system where every type has a constant constructor, (b) The following defined symbols do not have to be completely defined, as they can never occur inside other defined symbols: g_2 h_2 f_2 sp1_2 r_2 (c) The following functions are completely defined: none Due to the following rules being added: none And the following fresh constants: const, const1, const2, const3, const4 ---------------------------------------- (14) Obligation: Runtime Complexity Weighted TRS where critical functions are completely defined. The underlying TRS is: Runtime Complexity Weighted TRS with Types. The TRS R consists of the following rules: g(Cons(x, xs), y) -> Cons(x, xs) [1] h(Nil, y) -> h(Nil, y) [1] h(Cons(x, xs), y) -> f(Cons(x, xs), y) [1] g(Nil, y) -> h(Nil, y) [1] f(Nil, y) -> g(Nil, y) [1] f(Cons(x, xs), y) -> h(Cons(x, xs), y) [1] sp1(x, y) -> f(x, y) [1] r(x, y) -> x [1] The TRS has the following type information: g :: Cons:Nil -> c -> Cons:Nil Cons :: a -> b -> Cons:Nil h :: Cons:Nil -> c -> Cons:Nil Nil :: Cons:Nil f :: Cons:Nil -> c -> Cons:Nil sp1 :: Cons:Nil -> c -> Cons:Nil r :: r -> d -> r const :: c const1 :: a const2 :: b const3 :: r const4 :: d Rewrite Strategy: INNERMOST ---------------------------------------- (15) NarrowingProof (BOTH BOUNDS(ID, ID)) Narrowed the inner basic terms of all right-hand sides by a single narrowing step. ---------------------------------------- (16) Obligation: Runtime Complexity Weighted TRS where critical functions are completely defined. The underlying TRS is: Runtime Complexity Weighted TRS with Types. The TRS R consists of the following rules: g(Cons(x, xs), y) -> Cons(x, xs) [1] h(Nil, y) -> h(Nil, y) [1] h(Cons(x, xs), y) -> f(Cons(x, xs), y) [1] g(Nil, y) -> h(Nil, y) [1] f(Nil, y) -> g(Nil, y) [1] f(Cons(x, xs), y) -> h(Cons(x, xs), y) [1] sp1(x, y) -> f(x, y) [1] r(x, y) -> x [1] The TRS has the following type information: g :: Cons:Nil -> c -> Cons:Nil Cons :: a -> b -> Cons:Nil h :: Cons:Nil -> c -> Cons:Nil Nil :: Cons:Nil f :: Cons:Nil -> c -> Cons:Nil sp1 :: Cons:Nil -> c -> Cons:Nil r :: r -> d -> r const :: c const1 :: a const2 :: b const3 :: r const4 :: d Rewrite Strategy: INNERMOST ---------------------------------------- (17) CpxTypedWeightedTrsToRntsProof (UPPER BOUND(ID)) Transformed the TRS into an over-approximating RNTS by (improved) Size Abstraction. The constant constructors are abstracted as follows: Nil => 0 const => 0 const1 => 0 const2 => 0 const3 => 0 const4 => 0 ---------------------------------------- (18) Obligation: Complexity RNTS consisting of the following rules: f(z, z') -{ 1 }-> h(1 + x + xs, y) :|: z = 1 + x + xs, xs >= 0, x >= 0, y >= 0, z' = y f(z, z') -{ 1 }-> g(0, y) :|: y >= 0, z = 0, z' = y g(z, z') -{ 1 }-> h(0, y) :|: y >= 0, z = 0, z' = y g(z, z') -{ 1 }-> 1 + x + xs :|: z = 1 + x + xs, xs >= 0, x >= 0, y >= 0, z' = y h(z, z') -{ 1 }-> h(0, y) :|: y >= 0, z = 0, z' = y h(z, z') -{ 1 }-> f(1 + x + xs, y) :|: z = 1 + x + xs, xs >= 0, x >= 0, y >= 0, z' = y r(z, z') -{ 1 }-> x :|: x >= 0, y >= 0, z = x, z' = y sp1(z, z') -{ 1 }-> f(x, y) :|: x >= 0, y >= 0, z = x, z' = y ---------------------------------------- (19) SimplificationProof (BOTH BOUNDS(ID, ID)) Simplified the RNTS by moving equalities from the constraints into the right-hand sides. ---------------------------------------- (20) Obligation: Complexity RNTS consisting of the following rules: f(z, z') -{ 1 }-> h(1 + x + xs, z') :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 f(z, z') -{ 1 }-> g(0, z') :|: z' >= 0, z = 0 g(z, z') -{ 1 }-> h(0, z') :|: z' >= 0, z = 0 g(z, z') -{ 1 }-> 1 + x + xs :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 h(z, z') -{ 1 }-> h(0, z') :|: z' >= 0, z = 0 h(z, z') -{ 1 }-> f(1 + x + xs, z') :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 r(z, z') -{ 1 }-> z :|: z >= 0, z' >= 0 sp1(z, z') -{ 1 }-> f(z, z') :|: z >= 0, z' >= 0 ---------------------------------------- (21) CpxRntsAnalysisOrderProof (BOTH BOUNDS(ID, ID)) Found the following analysis order by SCC decomposition: { f, h, g } { r } { sp1 } ---------------------------------------- (22) Obligation: Complexity RNTS consisting of the following rules: f(z, z') -{ 1 }-> h(1 + x + xs, z') :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 f(z, z') -{ 1 }-> g(0, z') :|: z' >= 0, z = 0 g(z, z') -{ 1 }-> h(0, z') :|: z' >= 0, z = 0 g(z, z') -{ 1 }-> 1 + x + xs :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 h(z, z') -{ 1 }-> h(0, z') :|: z' >= 0, z = 0 h(z, z') -{ 1 }-> f(1 + x + xs, z') :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 r(z, z') -{ 1 }-> z :|: z >= 0, z' >= 0 sp1(z, z') -{ 1 }-> f(z, z') :|: z >= 0, z' >= 0 Function symbols to be analyzed: {f,h,g}, {r}, {sp1} ---------------------------------------- (23) ResultPropagationProof (UPPER BOUND(ID)) Applied inner abstraction using the recently inferred runtime/size bounds where possible. ---------------------------------------- (24) Obligation: Complexity RNTS consisting of the following rules: f(z, z') -{ 1 }-> h(1 + x + xs, z') :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 f(z, z') -{ 1 }-> g(0, z') :|: z' >= 0, z = 0 g(z, z') -{ 1 }-> h(0, z') :|: z' >= 0, z = 0 g(z, z') -{ 1 }-> 1 + x + xs :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 h(z, z') -{ 1 }-> h(0, z') :|: z' >= 0, z = 0 h(z, z') -{ 1 }-> f(1 + x + xs, z') :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 r(z, z') -{ 1 }-> z :|: z >= 0, z' >= 0 sp1(z, z') -{ 1 }-> f(z, z') :|: z >= 0, z' >= 0 Function symbols to be analyzed: {f,h,g}, {r}, {sp1} ---------------------------------------- (25) IntTrsBoundProof (UPPER BOUND(ID)) Computed SIZE bound using CoFloCo for: f after applying outer abstraction to obtain an ITS, resulting in: O(1) with polynomial bound: 0 Computed SIZE bound using CoFloCo for: h after applying outer abstraction to obtain an ITS, resulting in: O(1) with polynomial bound: 0 Computed SIZE bound using CoFloCo for: g after applying outer abstraction to obtain an ITS, resulting in: O(n^1) with polynomial bound: z ---------------------------------------- (26) Obligation: Complexity RNTS consisting of the following rules: f(z, z') -{ 1 }-> h(1 + x + xs, z') :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 f(z, z') -{ 1 }-> g(0, z') :|: z' >= 0, z = 0 g(z, z') -{ 1 }-> h(0, z') :|: z' >= 0, z = 0 g(z, z') -{ 1 }-> 1 + x + xs :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 h(z, z') -{ 1 }-> h(0, z') :|: z' >= 0, z = 0 h(z, z') -{ 1 }-> f(1 + x + xs, z') :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 r(z, z') -{ 1 }-> z :|: z >= 0, z' >= 0 sp1(z, z') -{ 1 }-> f(z, z') :|: z >= 0, z' >= 0 Function symbols to be analyzed: {f,h,g}, {r}, {sp1} Previous analysis results are: f: runtime: ?, size: O(1) [0] h: runtime: ?, size: O(1) [0] g: runtime: ?, size: O(n^1) [z] ---------------------------------------- (27) IntTrsBoundProof (UPPER BOUND(ID)) Computed RUNTIME bound using CoFloCo for: f after applying outer abstraction to obtain an ITS, resulting in: INF with polynomial bound: ? ---------------------------------------- (28) Obligation: Complexity RNTS consisting of the following rules: f(z, z') -{ 1 }-> h(1 + x + xs, z') :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 f(z, z') -{ 1 }-> g(0, z') :|: z' >= 0, z = 0 g(z, z') -{ 1 }-> h(0, z') :|: z' >= 0, z = 0 g(z, z') -{ 1 }-> 1 + x + xs :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 h(z, z') -{ 1 }-> h(0, z') :|: z' >= 0, z = 0 h(z, z') -{ 1 }-> f(1 + x + xs, z') :|: z = 1 + x + xs, xs >= 0, x >= 0, z' >= 0 r(z, z') -{ 1 }-> z :|: z >= 0, z' >= 0 sp1(z, z') -{ 1 }-> f(z, z') :|: z >= 0, z' >= 0 Function symbols to be analyzed: {f,h,g}, {r}, {sp1} Previous analysis results are: f: runtime: INF, size: O(1) [0] h: runtime: ?, size: O(1) [0] g: runtime: ?, size: O(n^1) [z] ---------------------------------------- (29) CpxTrsToCdtProof (UPPER BOUND(ID)) Converted Cpx (relative) TRS with rewrite strategy PARALLEL_INNERMOST to CDT ---------------------------------------- (30) Obligation: Complexity Dependency Tuples Problem Rules: g(Cons(z0, z1), z2) -> Cons(z0, z1) g(Nil, z0) -> h(Nil, z0) h(Nil, z0) -> h(Nil, z0) h(Cons(z0, z1), z2) -> f(Cons(z0, z1), z2) f(Nil, z0) -> g(Nil, z0) f(Cons(z0, z1), z2) -> h(Cons(z0, z1), z2) sp1(z0, z1) -> f(z0, z1) r(z0, z1) -> z0 Tuples: G(Cons(z0, z1), z2) -> c G(Nil, z0) -> c1(H(Nil, z0)) H(Nil, z0) -> c2(H(Nil, z0)) H(Cons(z0, z1), z2) -> c3(F(Cons(z0, z1), z2)) F(Nil, z0) -> c4(G(Nil, z0)) F(Cons(z0, z1), z2) -> c5(H(Cons(z0, z1), z2)) SP1(z0, z1) -> c6(F(z0, z1)) R(z0, z1) -> c7 S tuples: G(Cons(z0, z1), z2) -> c G(Nil, z0) -> c1(H(Nil, z0)) H(Nil, z0) -> c2(H(Nil, z0)) H(Cons(z0, z1), z2) -> c3(F(Cons(z0, z1), z2)) F(Nil, z0) -> c4(G(Nil, z0)) F(Cons(z0, z1), z2) -> c5(H(Cons(z0, z1), z2)) SP1(z0, z1) -> c6(F(z0, z1)) R(z0, z1) -> c7 K tuples:none Defined Rule Symbols: g_2, h_2, f_2, sp1_2, r_2 Defined Pair Symbols: G_2, H_2, F_2, SP1_2, R_2 Compound Symbols: c, c1_1, c2_1, c3_1, c4_1, c5_1, c6_1, c7 ---------------------------------------- (31) CdtLeafRemovalProof (ComplexityIfPolyImplication) Removed 3 leading nodes: SP1(z0, z1) -> c6(F(z0, z1)) F(Nil, z0) -> c4(G(Nil, z0)) G(Nil, z0) -> c1(H(Nil, z0)) Removed 2 trailing nodes: G(Cons(z0, z1), z2) -> c R(z0, z1) -> c7 ---------------------------------------- (32) Obligation: Complexity Dependency Tuples Problem Rules: g(Cons(z0, z1), z2) -> Cons(z0, z1) g(Nil, z0) -> h(Nil, z0) h(Nil, z0) -> h(Nil, z0) h(Cons(z0, z1), z2) -> f(Cons(z0, z1), z2) f(Nil, z0) -> g(Nil, z0) f(Cons(z0, z1), z2) -> h(Cons(z0, z1), z2) sp1(z0, z1) -> f(z0, z1) r(z0, z1) -> z0 Tuples: H(Nil, z0) -> c2(H(Nil, z0)) H(Cons(z0, z1), z2) -> c3(F(Cons(z0, z1), z2)) F(Cons(z0, z1), z2) -> c5(H(Cons(z0, z1), z2)) S tuples: H(Nil, z0) -> c2(H(Nil, z0)) H(Cons(z0, z1), z2) -> c3(F(Cons(z0, z1), z2)) F(Cons(z0, z1), z2) -> c5(H(Cons(z0, z1), z2)) K tuples:none Defined Rule Symbols: g_2, h_2, f_2, sp1_2, r_2 Defined Pair Symbols: H_2, F_2 Compound Symbols: c2_1, c3_1, c5_1 ---------------------------------------- (33) CdtUsableRulesProof (BOTH BOUNDS(ID, ID)) The following rules are not usable and were removed: g(Cons(z0, z1), z2) -> Cons(z0, z1) g(Nil, z0) -> h(Nil, z0) h(Nil, z0) -> h(Nil, z0) h(Cons(z0, z1), z2) -> f(Cons(z0, z1), z2) f(Nil, z0) -> g(Nil, z0) f(Cons(z0, z1), z2) -> h(Cons(z0, z1), z2) sp1(z0, z1) -> f(z0, z1) r(z0, z1) -> z0 ---------------------------------------- (34) Obligation: Complexity Dependency Tuples Problem Rules:none Tuples: H(Nil, z0) -> c2(H(Nil, z0)) H(Cons(z0, z1), z2) -> c3(F(Cons(z0, z1), z2)) F(Cons(z0, z1), z2) -> c5(H(Cons(z0, z1), z2)) S tuples: H(Nil, z0) -> c2(H(Nil, z0)) H(Cons(z0, z1), z2) -> c3(F(Cons(z0, z1), z2)) F(Cons(z0, z1), z2) -> c5(H(Cons(z0, z1), z2)) K tuples:none Defined Rule Symbols:none Defined Pair Symbols: H_2, F_2 Compound Symbols: c2_1, c3_1, c5_1