/export/starexec/sandbox/solver/bin/starexec_run_standard /export/starexec/sandbox/benchmark/theBenchmark.pl /export/starexec/sandbox/output/output_files -------------------------------------------------------------------------------- YES proof of /export/starexec/sandbox/benchmark/theBenchmark.pl # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty Left Termination of the query pattern drop(g,g,a) w.r.t. the given Prolog program could successfully be proven: (0) Prolog (1) UndefinedPredicateHandlerProof [SOUND, 0 ms] (2) Prolog (3) PrologToPiTRSProof [SOUND, 11 ms] (4) PiTRS (5) DependencyPairsProof [EQUIVALENT, 17 ms] (6) PiDP (7) DependencyGraphProof [EQUIVALENT, 0 ms] (8) PiDP (9) UsableRulesProof [EQUIVALENT, 0 ms] (10) PiDP (11) PiDPToQDPProof [SOUND, 0 ms] (12) QDP (13) QDPSizeChangeProof [EQUIVALENT, 5 ms] (14) YES ---------------------------------------- (0) Obligation: Clauses: drop(L1, N, L2) :- drop(L1, N, L2, N). drop([], X1, [], X2). drop(.(X3, Xs), N, Ys, 1) :- drop(Xs, N, Ys, N). drop(.(X, Xs), N, .(X, Ys), K) :- ','(>(K, 1), ','(is(K1, -(K, 1)), drop(Xs, N, Ys, K1))). Query: drop(g,g,a) ---------------------------------------- (1) UndefinedPredicateHandlerProof (SOUND) Added facts for all undefined predicates [PROLOG]. ---------------------------------------- (2) Obligation: Clauses: drop(L1, N, L2) :- drop(L1, N, L2, N). drop([], X1, [], X2). drop(.(X3, Xs), N, Ys, 1) :- drop(Xs, N, Ys, N). drop(.(X, Xs), N, .(X, Ys), K) :- ','(>(K, 1), ','(is(K1, -(K, 1)), drop(Xs, N, Ys, K1))). >(X0, X1). is(X0, X1). Query: drop(g,g,a) ---------------------------------------- (3) PrologToPiTRSProof (SOUND) We use the technique of [TOCL09]. With regard to the inferred argument filtering the predicates were used in the following modes: drop_in_3: (b,b,f) drop_in_4: (b,b,f,b) (b,b,f,f) Transforming Prolog into the following Term Rewriting System: Pi-finite rewrite system: The TRS R consists of the following rules: drop_in_gga(L1, N, L2) -> U1_gga(L1, N, L2, drop_in_ggag(L1, N, L2, N)) drop_in_ggag([], X1, [], X2) -> drop_out_ggag([], X1, [], X2) drop_in_ggag(.(X3, Xs), N, Ys, 1) -> U2_ggag(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) drop_in_ggag(.(X, Xs), N, .(X, Ys), K) -> U3_ggag(X, Xs, N, Ys, K, >_in_gg(K, 1)) >_in_gg(X0, X1) -> >_out_gg(X0, X1) U3_ggag(X, Xs, N, Ys, K, >_out_gg(K, 1)) -> U4_ggag(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U4_ggag(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_ggag(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) drop_in_ggaa([], X1, [], X2) -> drop_out_ggaa([], X1, [], X2) drop_in_ggaa(.(X3, Xs), N, Ys, 1) -> U2_ggaa(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) U2_ggaa(X3, Xs, N, Ys, drop_out_ggag(Xs, N, Ys, N)) -> drop_out_ggaa(.(X3, Xs), N, Ys, 1) drop_in_ggaa(.(X, Xs), N, .(X, Ys), K) -> U3_ggaa(X, Xs, N, Ys, K, >_in_ag(K, 1)) >_in_ag(X0, X1) -> >_out_ag(X0, X1) U3_ggaa(X, Xs, N, Ys, K, >_out_ag(K, 1)) -> U4_ggaa(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U4_ggaa(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_ggaa(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) U5_ggaa(X, Xs, N, Ys, K, drop_out_ggaa(Xs, N, Ys, K1)) -> drop_out_ggaa(.(X, Xs), N, .(X, Ys), K) U5_ggag(X, Xs, N, Ys, K, drop_out_ggaa(Xs, N, Ys, K1)) -> drop_out_ggag(.(X, Xs), N, .(X, Ys), K) U2_ggag(X3, Xs, N, Ys, drop_out_ggag(Xs, N, Ys, N)) -> drop_out_ggag(.(X3, Xs), N, Ys, 1) U1_gga(L1, N, L2, drop_out_ggag(L1, N, L2, N)) -> drop_out_gga(L1, N, L2) The argument filtering Pi contains the following mapping: drop_in_gga(x1, x2, x3) = drop_in_gga(x1, x2) U1_gga(x1, x2, x3, x4) = U1_gga(x4) drop_in_ggag(x1, x2, x3, x4) = drop_in_ggag(x1, x2, x4) [] = [] drop_out_ggag(x1, x2, x3, x4) = drop_out_ggag(x3) .(x1, x2) = .(x1, x2) 1 = 1 U2_ggag(x1, x2, x3, x4, x5) = U2_ggag(x5) U3_ggag(x1, x2, x3, x4, x5, x6) = U3_ggag(x1, x2, x3, x6) >_in_gg(x1, x2) = >_in_gg(x1, x2) >_out_gg(x1, x2) = >_out_gg U4_ggag(x1, x2, x3, x4, x5, x6) = U4_ggag(x1, x2, x3, x6) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag -(x1, x2) = -(x2) U5_ggag(x1, x2, x3, x4, x5, x6) = U5_ggag(x1, x6) drop_in_ggaa(x1, x2, x3, x4) = drop_in_ggaa(x1, x2) drop_out_ggaa(x1, x2, x3, x4) = drop_out_ggaa(x3) U2_ggaa(x1, x2, x3, x4, x5) = U2_ggaa(x5) U3_ggaa(x1, x2, x3, x4, x5, x6) = U3_ggaa(x1, x2, x3, x6) >_in_ag(x1, x2) = >_in_ag(x2) >_out_ag(x1, x2) = >_out_ag U4_ggaa(x1, x2, x3, x4, x5, x6) = U4_ggaa(x1, x2, x3, x6) U5_ggaa(x1, x2, x3, x4, x5, x6) = U5_ggaa(x1, x6) drop_out_gga(x1, x2, x3) = drop_out_gga(x3) Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog ---------------------------------------- (4) Obligation: Pi-finite rewrite system: The TRS R consists of the following rules: drop_in_gga(L1, N, L2) -> U1_gga(L1, N, L2, drop_in_ggag(L1, N, L2, N)) drop_in_ggag([], X1, [], X2) -> drop_out_ggag([], X1, [], X2) drop_in_ggag(.(X3, Xs), N, Ys, 1) -> U2_ggag(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) drop_in_ggag(.(X, Xs), N, .(X, Ys), K) -> U3_ggag(X, Xs, N, Ys, K, >_in_gg(K, 1)) >_in_gg(X0, X1) -> >_out_gg(X0, X1) U3_ggag(X, Xs, N, Ys, K, >_out_gg(K, 1)) -> U4_ggag(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U4_ggag(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_ggag(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) drop_in_ggaa([], X1, [], X2) -> drop_out_ggaa([], X1, [], X2) drop_in_ggaa(.(X3, Xs), N, Ys, 1) -> U2_ggaa(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) U2_ggaa(X3, Xs, N, Ys, drop_out_ggag(Xs, N, Ys, N)) -> drop_out_ggaa(.(X3, Xs), N, Ys, 1) drop_in_ggaa(.(X, Xs), N, .(X, Ys), K) -> U3_ggaa(X, Xs, N, Ys, K, >_in_ag(K, 1)) >_in_ag(X0, X1) -> >_out_ag(X0, X1) U3_ggaa(X, Xs, N, Ys, K, >_out_ag(K, 1)) -> U4_ggaa(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U4_ggaa(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_ggaa(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) U5_ggaa(X, Xs, N, Ys, K, drop_out_ggaa(Xs, N, Ys, K1)) -> drop_out_ggaa(.(X, Xs), N, .(X, Ys), K) U5_ggag(X, Xs, N, Ys, K, drop_out_ggaa(Xs, N, Ys, K1)) -> drop_out_ggag(.(X, Xs), N, .(X, Ys), K) U2_ggag(X3, Xs, N, Ys, drop_out_ggag(Xs, N, Ys, N)) -> drop_out_ggag(.(X3, Xs), N, Ys, 1) U1_gga(L1, N, L2, drop_out_ggag(L1, N, L2, N)) -> drop_out_gga(L1, N, L2) The argument filtering Pi contains the following mapping: drop_in_gga(x1, x2, x3) = drop_in_gga(x1, x2) U1_gga(x1, x2, x3, x4) = U1_gga(x4) drop_in_ggag(x1, x2, x3, x4) = drop_in_ggag(x1, x2, x4) [] = [] drop_out_ggag(x1, x2, x3, x4) = drop_out_ggag(x3) .(x1, x2) = .(x1, x2) 1 = 1 U2_ggag(x1, x2, x3, x4, x5) = U2_ggag(x5) U3_ggag(x1, x2, x3, x4, x5, x6) = U3_ggag(x1, x2, x3, x6) >_in_gg(x1, x2) = >_in_gg(x1, x2) >_out_gg(x1, x2) = >_out_gg U4_ggag(x1, x2, x3, x4, x5, x6) = U4_ggag(x1, x2, x3, x6) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag -(x1, x2) = -(x2) U5_ggag(x1, x2, x3, x4, x5, x6) = U5_ggag(x1, x6) drop_in_ggaa(x1, x2, x3, x4) = drop_in_ggaa(x1, x2) drop_out_ggaa(x1, x2, x3, x4) = drop_out_ggaa(x3) U2_ggaa(x1, x2, x3, x4, x5) = U2_ggaa(x5) U3_ggaa(x1, x2, x3, x4, x5, x6) = U3_ggaa(x1, x2, x3, x6) >_in_ag(x1, x2) = >_in_ag(x2) >_out_ag(x1, x2) = >_out_ag U4_ggaa(x1, x2, x3, x4, x5, x6) = U4_ggaa(x1, x2, x3, x6) U5_ggaa(x1, x2, x3, x4, x5, x6) = U5_ggaa(x1, x6) drop_out_gga(x1, x2, x3) = drop_out_gga(x3) ---------------------------------------- (5) DependencyPairsProof (EQUIVALENT) Using Dependency Pairs [AG00,LOPSTR] we result in the following initial DP problem: Pi DP problem: The TRS P consists of the following rules: DROP_IN_GGA(L1, N, L2) -> U1_GGA(L1, N, L2, drop_in_ggag(L1, N, L2, N)) DROP_IN_GGA(L1, N, L2) -> DROP_IN_GGAG(L1, N, L2, N) DROP_IN_GGAG(.(X3, Xs), N, Ys, 1) -> U2_GGAG(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) DROP_IN_GGAG(.(X3, Xs), N, Ys, 1) -> DROP_IN_GGAG(Xs, N, Ys, N) DROP_IN_GGAG(.(X, Xs), N, .(X, Ys), K) -> U3_GGAG(X, Xs, N, Ys, K, >_in_gg(K, 1)) DROP_IN_GGAG(.(X, Xs), N, .(X, Ys), K) -> >_IN_GG(K, 1) U3_GGAG(X, Xs, N, Ys, K, >_out_gg(K, 1)) -> U4_GGAG(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U3_GGAG(X, Xs, N, Ys, K, >_out_gg(K, 1)) -> IS_IN_AG(K1, -(K, 1)) U4_GGAG(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_GGAG(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) U4_GGAG(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> DROP_IN_GGAA(Xs, N, Ys, K1) DROP_IN_GGAA(.(X3, Xs), N, Ys, 1) -> U2_GGAA(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) DROP_IN_GGAA(.(X3, Xs), N, Ys, 1) -> DROP_IN_GGAG(Xs, N, Ys, N) DROP_IN_GGAA(.(X, Xs), N, .(X, Ys), K) -> U3_GGAA(X, Xs, N, Ys, K, >_in_ag(K, 1)) DROP_IN_GGAA(.(X, Xs), N, .(X, Ys), K) -> >_IN_AG(K, 1) U3_GGAA(X, Xs, N, Ys, K, >_out_ag(K, 1)) -> U4_GGAA(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U3_GGAA(X, Xs, N, Ys, K, >_out_ag(K, 1)) -> IS_IN_AG(K1, -(K, 1)) U4_GGAA(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_GGAA(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) U4_GGAA(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> DROP_IN_GGAA(Xs, N, Ys, K1) The TRS R consists of the following rules: drop_in_gga(L1, N, L2) -> U1_gga(L1, N, L2, drop_in_ggag(L1, N, L2, N)) drop_in_ggag([], X1, [], X2) -> drop_out_ggag([], X1, [], X2) drop_in_ggag(.(X3, Xs), N, Ys, 1) -> U2_ggag(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) drop_in_ggag(.(X, Xs), N, .(X, Ys), K) -> U3_ggag(X, Xs, N, Ys, K, >_in_gg(K, 1)) >_in_gg(X0, X1) -> >_out_gg(X0, X1) U3_ggag(X, Xs, N, Ys, K, >_out_gg(K, 1)) -> U4_ggag(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U4_ggag(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_ggag(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) drop_in_ggaa([], X1, [], X2) -> drop_out_ggaa([], X1, [], X2) drop_in_ggaa(.(X3, Xs), N, Ys, 1) -> U2_ggaa(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) U2_ggaa(X3, Xs, N, Ys, drop_out_ggag(Xs, N, Ys, N)) -> drop_out_ggaa(.(X3, Xs), N, Ys, 1) drop_in_ggaa(.(X, Xs), N, .(X, Ys), K) -> U3_ggaa(X, Xs, N, Ys, K, >_in_ag(K, 1)) >_in_ag(X0, X1) -> >_out_ag(X0, X1) U3_ggaa(X, Xs, N, Ys, K, >_out_ag(K, 1)) -> U4_ggaa(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U4_ggaa(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_ggaa(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) U5_ggaa(X, Xs, N, Ys, K, drop_out_ggaa(Xs, N, Ys, K1)) -> drop_out_ggaa(.(X, Xs), N, .(X, Ys), K) U5_ggag(X, Xs, N, Ys, K, drop_out_ggaa(Xs, N, Ys, K1)) -> drop_out_ggag(.(X, Xs), N, .(X, Ys), K) U2_ggag(X3, Xs, N, Ys, drop_out_ggag(Xs, N, Ys, N)) -> drop_out_ggag(.(X3, Xs), N, Ys, 1) U1_gga(L1, N, L2, drop_out_ggag(L1, N, L2, N)) -> drop_out_gga(L1, N, L2) The argument filtering Pi contains the following mapping: drop_in_gga(x1, x2, x3) = drop_in_gga(x1, x2) U1_gga(x1, x2, x3, x4) = U1_gga(x4) drop_in_ggag(x1, x2, x3, x4) = drop_in_ggag(x1, x2, x4) [] = [] drop_out_ggag(x1, x2, x3, x4) = drop_out_ggag(x3) .(x1, x2) = .(x1, x2) 1 = 1 U2_ggag(x1, x2, x3, x4, x5) = U2_ggag(x5) U3_ggag(x1, x2, x3, x4, x5, x6) = U3_ggag(x1, x2, x3, x6) >_in_gg(x1, x2) = >_in_gg(x1, x2) >_out_gg(x1, x2) = >_out_gg U4_ggag(x1, x2, x3, x4, x5, x6) = U4_ggag(x1, x2, x3, x6) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag -(x1, x2) = -(x2) U5_ggag(x1, x2, x3, x4, x5, x6) = U5_ggag(x1, x6) drop_in_ggaa(x1, x2, x3, x4) = drop_in_ggaa(x1, x2) drop_out_ggaa(x1, x2, x3, x4) = drop_out_ggaa(x3) U2_ggaa(x1, x2, x3, x4, x5) = U2_ggaa(x5) U3_ggaa(x1, x2, x3, x4, x5, x6) = U3_ggaa(x1, x2, x3, x6) >_in_ag(x1, x2) = >_in_ag(x2) >_out_ag(x1, x2) = >_out_ag U4_ggaa(x1, x2, x3, x4, x5, x6) = U4_ggaa(x1, x2, x3, x6) U5_ggaa(x1, x2, x3, x4, x5, x6) = U5_ggaa(x1, x6) drop_out_gga(x1, x2, x3) = drop_out_gga(x3) DROP_IN_GGA(x1, x2, x3) = DROP_IN_GGA(x1, x2) U1_GGA(x1, x2, x3, x4) = U1_GGA(x4) DROP_IN_GGAG(x1, x2, x3, x4) = DROP_IN_GGAG(x1, x2, x4) U2_GGAG(x1, x2, x3, x4, x5) = U2_GGAG(x5) U3_GGAG(x1, x2, x3, x4, x5, x6) = U3_GGAG(x1, x2, x3, x6) >_IN_GG(x1, x2) = >_IN_GG(x1, x2) U4_GGAG(x1, x2, x3, x4, x5, x6) = U4_GGAG(x1, x2, x3, x6) IS_IN_AG(x1, x2) = IS_IN_AG(x2) U5_GGAG(x1, x2, x3, x4, x5, x6) = U5_GGAG(x1, x6) DROP_IN_GGAA(x1, x2, x3, x4) = DROP_IN_GGAA(x1, x2) U2_GGAA(x1, x2, x3, x4, x5) = U2_GGAA(x5) U3_GGAA(x1, x2, x3, x4, x5, x6) = U3_GGAA(x1, x2, x3, x6) >_IN_AG(x1, x2) = >_IN_AG(x2) U4_GGAA(x1, x2, x3, x4, x5, x6) = U4_GGAA(x1, x2, x3, x6) U5_GGAA(x1, x2, x3, x4, x5, x6) = U5_GGAA(x1, x6) We have to consider all (P,R,Pi)-chains ---------------------------------------- (6) Obligation: Pi DP problem: The TRS P consists of the following rules: DROP_IN_GGA(L1, N, L2) -> U1_GGA(L1, N, L2, drop_in_ggag(L1, N, L2, N)) DROP_IN_GGA(L1, N, L2) -> DROP_IN_GGAG(L1, N, L2, N) DROP_IN_GGAG(.(X3, Xs), N, Ys, 1) -> U2_GGAG(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) DROP_IN_GGAG(.(X3, Xs), N, Ys, 1) -> DROP_IN_GGAG(Xs, N, Ys, N) DROP_IN_GGAG(.(X, Xs), N, .(X, Ys), K) -> U3_GGAG(X, Xs, N, Ys, K, >_in_gg(K, 1)) DROP_IN_GGAG(.(X, Xs), N, .(X, Ys), K) -> >_IN_GG(K, 1) U3_GGAG(X, Xs, N, Ys, K, >_out_gg(K, 1)) -> U4_GGAG(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U3_GGAG(X, Xs, N, Ys, K, >_out_gg(K, 1)) -> IS_IN_AG(K1, -(K, 1)) U4_GGAG(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_GGAG(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) U4_GGAG(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> DROP_IN_GGAA(Xs, N, Ys, K1) DROP_IN_GGAA(.(X3, Xs), N, Ys, 1) -> U2_GGAA(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) DROP_IN_GGAA(.(X3, Xs), N, Ys, 1) -> DROP_IN_GGAG(Xs, N, Ys, N) DROP_IN_GGAA(.(X, Xs), N, .(X, Ys), K) -> U3_GGAA(X, Xs, N, Ys, K, >_in_ag(K, 1)) DROP_IN_GGAA(.(X, Xs), N, .(X, Ys), K) -> >_IN_AG(K, 1) U3_GGAA(X, Xs, N, Ys, K, >_out_ag(K, 1)) -> U4_GGAA(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U3_GGAA(X, Xs, N, Ys, K, >_out_ag(K, 1)) -> IS_IN_AG(K1, -(K, 1)) U4_GGAA(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_GGAA(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) U4_GGAA(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> DROP_IN_GGAA(Xs, N, Ys, K1) The TRS R consists of the following rules: drop_in_gga(L1, N, L2) -> U1_gga(L1, N, L2, drop_in_ggag(L1, N, L2, N)) drop_in_ggag([], X1, [], X2) -> drop_out_ggag([], X1, [], X2) drop_in_ggag(.(X3, Xs), N, Ys, 1) -> U2_ggag(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) drop_in_ggag(.(X, Xs), N, .(X, Ys), K) -> U3_ggag(X, Xs, N, Ys, K, >_in_gg(K, 1)) >_in_gg(X0, X1) -> >_out_gg(X0, X1) U3_ggag(X, Xs, N, Ys, K, >_out_gg(K, 1)) -> U4_ggag(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U4_ggag(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_ggag(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) drop_in_ggaa([], X1, [], X2) -> drop_out_ggaa([], X1, [], X2) drop_in_ggaa(.(X3, Xs), N, Ys, 1) -> U2_ggaa(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) U2_ggaa(X3, Xs, N, Ys, drop_out_ggag(Xs, N, Ys, N)) -> drop_out_ggaa(.(X3, Xs), N, Ys, 1) drop_in_ggaa(.(X, Xs), N, .(X, Ys), K) -> U3_ggaa(X, Xs, N, Ys, K, >_in_ag(K, 1)) >_in_ag(X0, X1) -> >_out_ag(X0, X1) U3_ggaa(X, Xs, N, Ys, K, >_out_ag(K, 1)) -> U4_ggaa(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U4_ggaa(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_ggaa(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) U5_ggaa(X, Xs, N, Ys, K, drop_out_ggaa(Xs, N, Ys, K1)) -> drop_out_ggaa(.(X, Xs), N, .(X, Ys), K) U5_ggag(X, Xs, N, Ys, K, drop_out_ggaa(Xs, N, Ys, K1)) -> drop_out_ggag(.(X, Xs), N, .(X, Ys), K) U2_ggag(X3, Xs, N, Ys, drop_out_ggag(Xs, N, Ys, N)) -> drop_out_ggag(.(X3, Xs), N, Ys, 1) U1_gga(L1, N, L2, drop_out_ggag(L1, N, L2, N)) -> drop_out_gga(L1, N, L2) The argument filtering Pi contains the following mapping: drop_in_gga(x1, x2, x3) = drop_in_gga(x1, x2) U1_gga(x1, x2, x3, x4) = U1_gga(x4) drop_in_ggag(x1, x2, x3, x4) = drop_in_ggag(x1, x2, x4) [] = [] drop_out_ggag(x1, x2, x3, x4) = drop_out_ggag(x3) .(x1, x2) = .(x1, x2) 1 = 1 U2_ggag(x1, x2, x3, x4, x5) = U2_ggag(x5) U3_ggag(x1, x2, x3, x4, x5, x6) = U3_ggag(x1, x2, x3, x6) >_in_gg(x1, x2) = >_in_gg(x1, x2) >_out_gg(x1, x2) = >_out_gg U4_ggag(x1, x2, x3, x4, x5, x6) = U4_ggag(x1, x2, x3, x6) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag -(x1, x2) = -(x2) U5_ggag(x1, x2, x3, x4, x5, x6) = U5_ggag(x1, x6) drop_in_ggaa(x1, x2, x3, x4) = drop_in_ggaa(x1, x2) drop_out_ggaa(x1, x2, x3, x4) = drop_out_ggaa(x3) U2_ggaa(x1, x2, x3, x4, x5) = U2_ggaa(x5) U3_ggaa(x1, x2, x3, x4, x5, x6) = U3_ggaa(x1, x2, x3, x6) >_in_ag(x1, x2) = >_in_ag(x2) >_out_ag(x1, x2) = >_out_ag U4_ggaa(x1, x2, x3, x4, x5, x6) = U4_ggaa(x1, x2, x3, x6) U5_ggaa(x1, x2, x3, x4, x5, x6) = U5_ggaa(x1, x6) drop_out_gga(x1, x2, x3) = drop_out_gga(x3) DROP_IN_GGA(x1, x2, x3) = DROP_IN_GGA(x1, x2) U1_GGA(x1, x2, x3, x4) = U1_GGA(x4) DROP_IN_GGAG(x1, x2, x3, x4) = DROP_IN_GGAG(x1, x2, x4) U2_GGAG(x1, x2, x3, x4, x5) = U2_GGAG(x5) U3_GGAG(x1, x2, x3, x4, x5, x6) = U3_GGAG(x1, x2, x3, x6) >_IN_GG(x1, x2) = >_IN_GG(x1, x2) U4_GGAG(x1, x2, x3, x4, x5, x6) = U4_GGAG(x1, x2, x3, x6) IS_IN_AG(x1, x2) = IS_IN_AG(x2) U5_GGAG(x1, x2, x3, x4, x5, x6) = U5_GGAG(x1, x6) DROP_IN_GGAA(x1, x2, x3, x4) = DROP_IN_GGAA(x1, x2) U2_GGAA(x1, x2, x3, x4, x5) = U2_GGAA(x5) U3_GGAA(x1, x2, x3, x4, x5, x6) = U3_GGAA(x1, x2, x3, x6) >_IN_AG(x1, x2) = >_IN_AG(x2) U4_GGAA(x1, x2, x3, x4, x5, x6) = U4_GGAA(x1, x2, x3, x6) U5_GGAA(x1, x2, x3, x4, x5, x6) = U5_GGAA(x1, x6) We have to consider all (P,R,Pi)-chains ---------------------------------------- (7) DependencyGraphProof (EQUIVALENT) The approximation of the Dependency Graph [LOPSTR] contains 1 SCC with 10 less nodes. ---------------------------------------- (8) Obligation: Pi DP problem: The TRS P consists of the following rules: DROP_IN_GGAG(.(X, Xs), N, .(X, Ys), K) -> U3_GGAG(X, Xs, N, Ys, K, >_in_gg(K, 1)) U3_GGAG(X, Xs, N, Ys, K, >_out_gg(K, 1)) -> U4_GGAG(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U4_GGAG(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> DROP_IN_GGAA(Xs, N, Ys, K1) DROP_IN_GGAA(.(X3, Xs), N, Ys, 1) -> DROP_IN_GGAG(Xs, N, Ys, N) DROP_IN_GGAG(.(X3, Xs), N, Ys, 1) -> DROP_IN_GGAG(Xs, N, Ys, N) DROP_IN_GGAA(.(X, Xs), N, .(X, Ys), K) -> U3_GGAA(X, Xs, N, Ys, K, >_in_ag(K, 1)) U3_GGAA(X, Xs, N, Ys, K, >_out_ag(K, 1)) -> U4_GGAA(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U4_GGAA(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> DROP_IN_GGAA(Xs, N, Ys, K1) The TRS R consists of the following rules: drop_in_gga(L1, N, L2) -> U1_gga(L1, N, L2, drop_in_ggag(L1, N, L2, N)) drop_in_ggag([], X1, [], X2) -> drop_out_ggag([], X1, [], X2) drop_in_ggag(.(X3, Xs), N, Ys, 1) -> U2_ggag(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) drop_in_ggag(.(X, Xs), N, .(X, Ys), K) -> U3_ggag(X, Xs, N, Ys, K, >_in_gg(K, 1)) >_in_gg(X0, X1) -> >_out_gg(X0, X1) U3_ggag(X, Xs, N, Ys, K, >_out_gg(K, 1)) -> U4_ggag(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U4_ggag(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_ggag(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) drop_in_ggaa([], X1, [], X2) -> drop_out_ggaa([], X1, [], X2) drop_in_ggaa(.(X3, Xs), N, Ys, 1) -> U2_ggaa(X3, Xs, N, Ys, drop_in_ggag(Xs, N, Ys, N)) U2_ggaa(X3, Xs, N, Ys, drop_out_ggag(Xs, N, Ys, N)) -> drop_out_ggaa(.(X3, Xs), N, Ys, 1) drop_in_ggaa(.(X, Xs), N, .(X, Ys), K) -> U3_ggaa(X, Xs, N, Ys, K, >_in_ag(K, 1)) >_in_ag(X0, X1) -> >_out_ag(X0, X1) U3_ggaa(X, Xs, N, Ys, K, >_out_ag(K, 1)) -> U4_ggaa(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U4_ggaa(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> U5_ggaa(X, Xs, N, Ys, K, drop_in_ggaa(Xs, N, Ys, K1)) U5_ggaa(X, Xs, N, Ys, K, drop_out_ggaa(Xs, N, Ys, K1)) -> drop_out_ggaa(.(X, Xs), N, .(X, Ys), K) U5_ggag(X, Xs, N, Ys, K, drop_out_ggaa(Xs, N, Ys, K1)) -> drop_out_ggag(.(X, Xs), N, .(X, Ys), K) U2_ggag(X3, Xs, N, Ys, drop_out_ggag(Xs, N, Ys, N)) -> drop_out_ggag(.(X3, Xs), N, Ys, 1) U1_gga(L1, N, L2, drop_out_ggag(L1, N, L2, N)) -> drop_out_gga(L1, N, L2) The argument filtering Pi contains the following mapping: drop_in_gga(x1, x2, x3) = drop_in_gga(x1, x2) U1_gga(x1, x2, x3, x4) = U1_gga(x4) drop_in_ggag(x1, x2, x3, x4) = drop_in_ggag(x1, x2, x4) [] = [] drop_out_ggag(x1, x2, x3, x4) = drop_out_ggag(x3) .(x1, x2) = .(x1, x2) 1 = 1 U2_ggag(x1, x2, x3, x4, x5) = U2_ggag(x5) U3_ggag(x1, x2, x3, x4, x5, x6) = U3_ggag(x1, x2, x3, x6) >_in_gg(x1, x2) = >_in_gg(x1, x2) >_out_gg(x1, x2) = >_out_gg U4_ggag(x1, x2, x3, x4, x5, x6) = U4_ggag(x1, x2, x3, x6) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag -(x1, x2) = -(x2) U5_ggag(x1, x2, x3, x4, x5, x6) = U5_ggag(x1, x6) drop_in_ggaa(x1, x2, x3, x4) = drop_in_ggaa(x1, x2) drop_out_ggaa(x1, x2, x3, x4) = drop_out_ggaa(x3) U2_ggaa(x1, x2, x3, x4, x5) = U2_ggaa(x5) U3_ggaa(x1, x2, x3, x4, x5, x6) = U3_ggaa(x1, x2, x3, x6) >_in_ag(x1, x2) = >_in_ag(x2) >_out_ag(x1, x2) = >_out_ag U4_ggaa(x1, x2, x3, x4, x5, x6) = U4_ggaa(x1, x2, x3, x6) U5_ggaa(x1, x2, x3, x4, x5, x6) = U5_ggaa(x1, x6) drop_out_gga(x1, x2, x3) = drop_out_gga(x3) DROP_IN_GGAG(x1, x2, x3, x4) = DROP_IN_GGAG(x1, x2, x4) U3_GGAG(x1, x2, x3, x4, x5, x6) = U3_GGAG(x1, x2, x3, x6) U4_GGAG(x1, x2, x3, x4, x5, x6) = U4_GGAG(x1, x2, x3, x6) DROP_IN_GGAA(x1, x2, x3, x4) = DROP_IN_GGAA(x1, x2) U3_GGAA(x1, x2, x3, x4, x5, x6) = U3_GGAA(x1, x2, x3, x6) U4_GGAA(x1, x2, x3, x4, x5, x6) = U4_GGAA(x1, x2, x3, x6) We have to consider all (P,R,Pi)-chains ---------------------------------------- (9) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (10) Obligation: Pi DP problem: The TRS P consists of the following rules: DROP_IN_GGAG(.(X, Xs), N, .(X, Ys), K) -> U3_GGAG(X, Xs, N, Ys, K, >_in_gg(K, 1)) U3_GGAG(X, Xs, N, Ys, K, >_out_gg(K, 1)) -> U4_GGAG(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U4_GGAG(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> DROP_IN_GGAA(Xs, N, Ys, K1) DROP_IN_GGAA(.(X3, Xs), N, Ys, 1) -> DROP_IN_GGAG(Xs, N, Ys, N) DROP_IN_GGAG(.(X3, Xs), N, Ys, 1) -> DROP_IN_GGAG(Xs, N, Ys, N) DROP_IN_GGAA(.(X, Xs), N, .(X, Ys), K) -> U3_GGAA(X, Xs, N, Ys, K, >_in_ag(K, 1)) U3_GGAA(X, Xs, N, Ys, K, >_out_ag(K, 1)) -> U4_GGAA(X, Xs, N, Ys, K, is_in_ag(K1, -(K, 1))) U4_GGAA(X, Xs, N, Ys, K, is_out_ag(K1, -(K, 1))) -> DROP_IN_GGAA(Xs, N, Ys, K1) The TRS R consists of the following rules: >_in_gg(X0, X1) -> >_out_gg(X0, X1) is_in_ag(X0, X1) -> is_out_ag(X0, X1) >_in_ag(X0, X1) -> >_out_ag(X0, X1) The argument filtering Pi contains the following mapping: .(x1, x2) = .(x1, x2) 1 = 1 >_in_gg(x1, x2) = >_in_gg(x1, x2) >_out_gg(x1, x2) = >_out_gg is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag -(x1, x2) = -(x2) >_in_ag(x1, x2) = >_in_ag(x2) >_out_ag(x1, x2) = >_out_ag DROP_IN_GGAG(x1, x2, x3, x4) = DROP_IN_GGAG(x1, x2, x4) U3_GGAG(x1, x2, x3, x4, x5, x6) = U3_GGAG(x1, x2, x3, x6) U4_GGAG(x1, x2, x3, x4, x5, x6) = U4_GGAG(x1, x2, x3, x6) DROP_IN_GGAA(x1, x2, x3, x4) = DROP_IN_GGAA(x1, x2) U3_GGAA(x1, x2, x3, x4, x5, x6) = U3_GGAA(x1, x2, x3, x6) U4_GGAA(x1, x2, x3, x4, x5, x6) = U4_GGAA(x1, x2, x3, x6) We have to consider all (P,R,Pi)-chains ---------------------------------------- (11) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (12) Obligation: Q DP problem: The TRS P consists of the following rules: DROP_IN_GGAG(.(X, Xs), N, K) -> U3_GGAG(X, Xs, N, >_in_gg(K, 1)) U3_GGAG(X, Xs, N, >_out_gg) -> U4_GGAG(X, Xs, N, is_in_ag(-(1))) U4_GGAG(X, Xs, N, is_out_ag) -> DROP_IN_GGAA(Xs, N) DROP_IN_GGAA(.(X3, Xs), N) -> DROP_IN_GGAG(Xs, N, N) DROP_IN_GGAG(.(X3, Xs), N, 1) -> DROP_IN_GGAG(Xs, N, N) DROP_IN_GGAA(.(X, Xs), N) -> U3_GGAA(X, Xs, N, >_in_ag(1)) U3_GGAA(X, Xs, N, >_out_ag) -> U4_GGAA(X, Xs, N, is_in_ag(-(1))) U4_GGAA(X, Xs, N, is_out_ag) -> DROP_IN_GGAA(Xs, N) The TRS R consists of the following rules: >_in_gg(X0, X1) -> >_out_gg is_in_ag(X1) -> is_out_ag >_in_ag(X1) -> >_out_ag The set Q consists of the following terms: >_in_gg(x0, x1) is_in_ag(x0) >_in_ag(x0) We have to consider all (P,Q,R)-chains. ---------------------------------------- (13) QDPSizeChangeProof (EQUIVALENT) By using the subterm criterion [SUBTERM_CRITERION] together with the size-change analysis [AAECC05] we have proven that there are no infinite chains for this DP problem. From the DPs we obtained the following set of size-change graphs: *U3_GGAG(X, Xs, N, >_out_gg) -> U4_GGAG(X, Xs, N, is_in_ag(-(1))) The graph contains the following edges 1 >= 1, 2 >= 2, 3 >= 3 *U4_GGAG(X, Xs, N, is_out_ag) -> DROP_IN_GGAA(Xs, N) The graph contains the following edges 2 >= 1, 3 >= 2 *DROP_IN_GGAG(.(X, Xs), N, K) -> U3_GGAG(X, Xs, N, >_in_gg(K, 1)) The graph contains the following edges 1 > 1, 1 > 2, 2 >= 3 *DROP_IN_GGAA(.(X3, Xs), N) -> DROP_IN_GGAG(Xs, N, N) The graph contains the following edges 1 > 1, 2 >= 2, 2 >= 3 *DROP_IN_GGAG(.(X3, Xs), N, 1) -> DROP_IN_GGAG(Xs, N, N) The graph contains the following edges 1 > 1, 2 >= 2, 2 >= 3 *DROP_IN_GGAA(.(X, Xs), N) -> U3_GGAA(X, Xs, N, >_in_ag(1)) The graph contains the following edges 1 > 1, 1 > 2, 2 >= 3 *U4_GGAA(X, Xs, N, is_out_ag) -> DROP_IN_GGAA(Xs, N) The graph contains the following edges 2 >= 1, 3 >= 2 *U3_GGAA(X, Xs, N, >_out_ag) -> U4_GGAA(X, Xs, N, is_in_ag(-(1))) The graph contains the following edges 1 >= 1, 2 >= 2, 3 >= 3 ---------------------------------------- (14) YES