/export/starexec/sandbox/solver/bin/starexec_run_standard /export/starexec/sandbox/benchmark/theBenchmark.pl /export/starexec/sandbox/output/output_files -------------------------------------------------------------------------------- MAYBE proof of /export/starexec/sandbox/benchmark/theBenchmark.pl # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty Left Termination of the query pattern find(g,g) w.r.t. the given Prolog program could not be shown: (0) Prolog (1) IntegerArithmeticTransformerProof [SOUND, 0 ms] (2) Prolog (3) CutEliminatorProof [SOUND, 0 ms] (4) Prolog (5) UnifyTransformerProof [EQUIVALENT, 0 ms] (6) Prolog (7) OrTransformerProof [EQUIVALENT, 0 ms] (8) Prolog (9) PrologToPiTRSProof [SOUND, 1 ms] (10) PiTRS (11) DependencyPairsProof [EQUIVALENT, 49 ms] (12) PiDP (13) DependencyGraphProof [EQUIVALENT, 0 ms] (14) AND (15) PiDP (16) UsableRulesProof [EQUIVALENT, 0 ms] (17) PiDP (18) PiDPToQDPProof [EQUIVALENT, 0 ms] (19) QDP (20) QDPSizeChangeProof [EQUIVALENT, 0 ms] (21) YES (22) PiDP (23) UsableRulesProof [EQUIVALENT, 0 ms] (24) PiDP (25) PiDPToQDPProof [EQUIVALENT, 0 ms] (26) QDP (27) QDPSizeChangeProof [EQUIVALENT, 0 ms] (28) YES (29) PiDP (30) UsableRulesProof [EQUIVALENT, 0 ms] (31) PiDP (32) PiDPToQDPProof [SOUND, 0 ms] (33) QDP (34) QDPSizeChangeProof [EQUIVALENT, 0 ms] (35) YES (36) PiDP (37) UsableRulesProof [EQUIVALENT, 0 ms] (38) PiDP (39) PiDPToQDPProof [SOUND, 0 ms] (40) QDP (41) QDPSizeChangeProof [EQUIVALENT, 0 ms] (42) YES (43) PiDP (44) UsableRulesProof [EQUIVALENT, 0 ms] (45) PiDP (46) PiDPToQDPProof [SOUND, 0 ms] (47) QDP (48) PrologToPiTRSProof [SOUND, 0 ms] (49) PiTRS (50) DependencyPairsProof [EQUIVALENT, 19 ms] (51) PiDP (52) DependencyGraphProof [EQUIVALENT, 0 ms] (53) AND (54) PiDP (55) UsableRulesProof [EQUIVALENT, 0 ms] (56) PiDP (57) PiDPToQDPProof [EQUIVALENT, 0 ms] (58) QDP (59) QDPSizeChangeProof [EQUIVALENT, 0 ms] (60) YES (61) PiDP (62) UsableRulesProof [EQUIVALENT, 0 ms] (63) PiDP (64) PiDPToQDPProof [EQUIVALENT, 0 ms] (65) QDP (66) QDPSizeChangeProof [EQUIVALENT, 0 ms] (67) YES (68) PiDP (69) UsableRulesProof [EQUIVALENT, 0 ms] (70) PiDP (71) PiDPToQDPProof [SOUND, 0 ms] (72) QDP (73) QDPSizeChangeProof [EQUIVALENT, 0 ms] (74) YES (75) PiDP (76) UsableRulesProof [EQUIVALENT, 0 ms] (77) PiDP (78) PiDPToQDPProof [SOUND, 0 ms] (79) QDP (80) QDPSizeChangeProof [EQUIVALENT, 0 ms] (81) YES (82) PiDP (83) UsableRulesProof [EQUIVALENT, 0 ms] (84) PiDP (85) PiDPToQDPProof [SOUND, 0 ms] (86) QDP (87) CutEliminatorProof [SOUND, 0 ms] (88) Prolog (89) UndefinedPredicateHandlerProof [SOUND, 0 ms] (90) Prolog (91) PrologToPiTRSProof [SOUND, 0 ms] (92) PiTRS (93) DependencyPairsProof [EQUIVALENT, 0 ms] (94) PiDP (95) DependencyGraphProof [EQUIVALENT, 0 ms] (96) AND (97) PiDP (98) UsableRulesProof [EQUIVALENT, 0 ms] (99) PiDP (100) PiDPToQDPProof [SOUND, 0 ms] (101) QDP (102) QDPSizeChangeProof [EQUIVALENT, 0 ms] (103) YES (104) PiDP (105) UsableRulesProof [EQUIVALENT, 0 ms] (106) PiDP (107) PiDPToQDPProof [SOUND, 0 ms] (108) QDP (109) PrologToPiTRSProof [SOUND, 0 ms] (110) PiTRS (111) DependencyPairsProof [EQUIVALENT, 0 ms] (112) PiDP (113) DependencyGraphProof [EQUIVALENT, 0 ms] (114) AND (115) PiDP (116) UsableRulesProof [EQUIVALENT, 0 ms] (117) PiDP (118) PiDPToQDPProof [SOUND, 0 ms] (119) QDP (120) QDPSizeChangeProof [EQUIVALENT, 0 ms] (121) YES (122) PiDP (123) UsableRulesProof [EQUIVALENT, 1 ms] (124) PiDP (125) PiDPToQDPProof [SOUND, 0 ms] (126) QDP (127) TransformationProof [EQUIVALENT, 0 ms] (128) QDP (129) UsableRulesProof [EQUIVALENT, 0 ms] (130) QDP (131) QReductionProof [EQUIVALENT, 0 ms] (132) QDP (133) PrologToDTProblemTransformerProof [SOUND, 44 ms] (134) TRIPLES (135) TriplesToPiDPProof [SOUND, 0 ms] (136) PiDP (137) DependencyGraphProof [EQUIVALENT, 0 ms] (138) PiDP (139) PiDPToQDPProof [SOUND, 0 ms] (140) QDP (141) PrologToIRSwTTransformerProof [SOUND, 42 ms] (142) IRSwT (143) IRSwTSimpleDependencyGraphProof [EQUIVALENT, 0 ms] (144) IRSwT (145) IntTRSCompressionProof [EQUIVALENT, 53 ms] (146) IRSwT (147) IRSFormatTransformerProof [EQUIVALENT, 0 ms] (148) IRSwT (149) IRSwTTerminationDigraphProof [EQUIVALENT, 6 ms] (150) IRSwT (151) FilterProof [EQUIVALENT, 2 ms] (152) IntTRS (153) IntTRSPeriodicNontermProof [COMPLETE, 0 ms] (154) NO ---------------------------------------- (0) Obligation: Clauses: find([], X1) :- !. find(Vec, Val) :- find(Vec, Val, Vec). find([], Val, Start) :- ','(addOne(Start, StartPlusOne), find(StartPlusOne, Val)). find(.(X, X2), Val, X3) :- ','(>=(X, Val), !). find(.(X, Xs), Val, Start) :- ','(<(X, Val), ','(!, find(Xs, Val, Start))). addOne([], []). addOne(.(X, Xs), .(Y, Ys)) :- ','(is(Y, +(X, 1)), addOne(Xs, Ys)). Query: find(g,g) ---------------------------------------- (1) IntegerArithmeticTransformerProof (SOUND) Added definitions of predefined predicates [PROLOG]. ---------------------------------------- (2) Obligation: Clauses: find([], X1) :- !. find(Vec, Val) :- find(Vec, Val, Vec). find([], Val, Start) :- ','(addOne(Start, StartPlusOne), find(StartPlusOne, Val)). find(.(X, X2), Val, X3) :- ','(=(X1, X), ','(=(X4, Val), ','(;(isGreater(X1, X4), =(X1, X4)), !))). find(.(X, Xs), Val, Start) :- ','(=(X1, X), ','(=(X2, Val), ','(isLess(X1, X2), ','(!, find(Xs, Val, Start))))). addOne([], []). addOne(.(X, Xs), .(Y, Ys)) :- ','(isPlus(X, succ(zero), U), ','(=(Y, U), addOne(Xs, Ys))). isPlus(zero, X, X). isPlus(succ(X), zero, succ(X)). isPlus(succ(X), succ(Y), succ(succ(Z))) :- isPlus(X, Y, Z). isPlus(succ(X), pred(Y), Z) :- isPlus(X, Y, Z). isPlus(pred(X), zero, pred(X)). isPlus(pred(X), succ(Y), Z) :- isPlus(X, Y, Z). isPlus(pred(X), pred(Y), pred(pred(Z))) :- isPlus(X, Y, Z). isMinus(X, zero, X). isMinus(zero, succ(Y), pred(Z)) :- isMinus(zero, Y, Z). isMinus(zero, pred(Y), succ(Z)) :- isMinus(zero, Y, Z). isMinus(succ(X), succ(Y), Z) :- isMinus(X, Y, Z). isMinus(succ(X), pred(Y), succ(succ(Z))) :- isMinus(X, Y, Z). isMinus(pred(X), succ(Y), pred(pred(Z))) :- isMinus(X, Y, Z). isMinus(pred(X), pred(Y), Z) :- isMinus(X, Y, Z). isTimes(X, zero, zero). isTimes(zero, succ(Y), zero). isTimes(zero, pred(Y), zero). isTimes(succ(X), succ(Y), Z) :- ','(isTimes(succ(X), Y, A), isPlus(A, succ(X), Z)). isTimes(succ(X), pred(Y), Z) :- ','(isTimes(succ(X), Y, A), isMinus(A, succ(X), Z)). isTimes(pred(X), succ(Y), Z) :- ','(isTimes(pred(X), Y, A), isPlus(A, pred(X), Z)). isTimes(pred(X), pred(Y), Z) :- ','(isTimes(pred(X), Y, A), isMinus(A, pred(X), Z)). isDiv(zero, succ(Y), zero). isDiv(zero, pred(Y), zero). isDiv(succ(X), succ(Y), zero) :- isMinus(succ(X), succ(Y), pred(Z)). isDiv(succ(X), succ(Y), succ(Z)) :- ','(isMinus(succ(X), succ(Y), A), isDiv(A, succ(Y), Z)). isDiv(succ(X), pred(Y), Z) :- ','(isMinus(zero, pred(Y), A), ','(isDiv(succ(X), A, B), isMinus(zero, B, Z))). isDiv(pred(X), pred(Y), zero) :- isMinus(pred(X), pred(Y), succ(Z)). isDiv(pred(X), pred(Y), succ(Z)) :- ','(isMinus(pred(X), pred(Y), A), isDiv(A, pred(Y), Z)). isDiv(pred(X), succ(Y), Z) :- ','(isMinus(zero, pred(X), A), ','(isDiv(A, succ(Y), B), isMinus(zero, B, Z))). isModulo(X, Y, Z) :- ','(isDiv(X, Y, A), ','(isTimes(A, Y, B), isMinus(X, B, Z))). isGreater(succ(X), zero). isGreater(succ(X), pred(Y)). isGreater(succ(X), succ(Y)) :- isGreater(X, Y). isGreater(zero, pred(Y)). isGreater(pred(X), pred(Y)) :- isGreater(X, Y). isLess(pred(X), zero). isLess(pred(X), succ(Y)). isLess(pred(X), pred(Y)) :- isLess(X, Y). isLess(zero, succ(Y)). isLess(succ(X), succ(Y)) :- isLess(X, Y). Query: find(g,g) ---------------------------------------- (3) CutEliminatorProof (SOUND) Eliminated all cuts by simply ignoring them[PROLOG]. ---------------------------------------- (4) Obligation: Clauses: find([], X1). find(Vec, Val) :- find(Vec, Val, Vec). find([], Val, Start) :- ','(addOne(Start, StartPlusOne), find(StartPlusOne, Val)). find(.(X, X2), Val, X3) :- ','(=(X1, X), ','(=(X4, Val), ;(isGreater(X1, X4), =(X1, X4)))). find(.(X, Xs), Val, Start) :- ','(=(X1, X), ','(=(X2, Val), ','(isLess(X1, X2), find(Xs, Val, Start)))). addOne([], []). addOne(.(X, Xs), .(Y, Ys)) :- ','(isPlus(X, succ(zero), U), ','(=(Y, U), addOne(Xs, Ys))). isPlus(zero, X, X). isPlus(succ(X), zero, succ(X)). isPlus(succ(X), succ(Y), succ(succ(Z))) :- isPlus(X, Y, Z). isPlus(succ(X), pred(Y), Z) :- isPlus(X, Y, Z). isPlus(pred(X), zero, pred(X)). isPlus(pred(X), succ(Y), Z) :- isPlus(X, Y, Z). isPlus(pred(X), pred(Y), pred(pred(Z))) :- isPlus(X, Y, Z). isMinus(X, zero, X). isMinus(zero, succ(Y), pred(Z)) :- isMinus(zero, Y, Z). isMinus(zero, pred(Y), succ(Z)) :- isMinus(zero, Y, Z). isMinus(succ(X), succ(Y), Z) :- isMinus(X, Y, Z). isMinus(succ(X), pred(Y), succ(succ(Z))) :- isMinus(X, Y, Z). isMinus(pred(X), succ(Y), pred(pred(Z))) :- isMinus(X, Y, Z). isMinus(pred(X), pred(Y), Z) :- isMinus(X, Y, Z). isTimes(X, zero, zero). isTimes(zero, succ(Y), zero). isTimes(zero, pred(Y), zero). isTimes(succ(X), succ(Y), Z) :- ','(isTimes(succ(X), Y, A), isPlus(A, succ(X), Z)). isTimes(succ(X), pred(Y), Z) :- ','(isTimes(succ(X), Y, A), isMinus(A, succ(X), Z)). isTimes(pred(X), succ(Y), Z) :- ','(isTimes(pred(X), Y, A), isPlus(A, pred(X), Z)). isTimes(pred(X), pred(Y), Z) :- ','(isTimes(pred(X), Y, A), isMinus(A, pred(X), Z)). isDiv(zero, succ(Y), zero). isDiv(zero, pred(Y), zero). isDiv(succ(X), succ(Y), zero) :- isMinus(succ(X), succ(Y), pred(Z)). isDiv(succ(X), succ(Y), succ(Z)) :- ','(isMinus(succ(X), succ(Y), A), isDiv(A, succ(Y), Z)). isDiv(succ(X), pred(Y), Z) :- ','(isMinus(zero, pred(Y), A), ','(isDiv(succ(X), A, B), isMinus(zero, B, Z))). isDiv(pred(X), pred(Y), zero) :- isMinus(pred(X), pred(Y), succ(Z)). isDiv(pred(X), pred(Y), succ(Z)) :- ','(isMinus(pred(X), pred(Y), A), isDiv(A, pred(Y), Z)). isDiv(pred(X), succ(Y), Z) :- ','(isMinus(zero, pred(X), A), ','(isDiv(A, succ(Y), B), isMinus(zero, B, Z))). isModulo(X, Y, Z) :- ','(isDiv(X, Y, A), ','(isTimes(A, Y, B), isMinus(X, B, Z))). isGreater(succ(X), zero). isGreater(succ(X), pred(Y)). isGreater(succ(X), succ(Y)) :- isGreater(X, Y). isGreater(zero, pred(Y)). isGreater(pred(X), pred(Y)) :- isGreater(X, Y). isLess(pred(X), zero). isLess(pred(X), succ(Y)). isLess(pred(X), pred(Y)) :- isLess(X, Y). isLess(zero, succ(Y)). isLess(succ(X), succ(Y)) :- isLess(X, Y). Query: find(g,g) ---------------------------------------- (5) UnifyTransformerProof (EQUIVALENT) Added a fact for the built-in = predicate [PROLOG]. ---------------------------------------- (6) Obligation: Clauses: find([], X1). find(Vec, Val) :- find(Vec, Val, Vec). find([], Val, Start) :- ','(addOne(Start, StartPlusOne), find(StartPlusOne, Val)). find(.(X, X2), Val, X3) :- ','(=(X1, X), ','(=(X4, Val), ;(isGreater(X1, X4), =(X1, X4)))). find(.(X, Xs), Val, Start) :- ','(=(X1, X), ','(=(X2, Val), ','(isLess(X1, X2), find(Xs, Val, Start)))). addOne([], []). addOne(.(X, Xs), .(Y, Ys)) :- ','(isPlus(X, succ(zero), U), ','(=(Y, U), addOne(Xs, Ys))). isPlus(zero, X, X). isPlus(succ(X), zero, succ(X)). isPlus(succ(X), succ(Y), succ(succ(Z))) :- isPlus(X, Y, Z). isPlus(succ(X), pred(Y), Z) :- isPlus(X, Y, Z). isPlus(pred(X), zero, pred(X)). isPlus(pred(X), succ(Y), Z) :- isPlus(X, Y, Z). isPlus(pred(X), pred(Y), pred(pred(Z))) :- isPlus(X, Y, Z). isMinus(X, zero, X). isMinus(zero, succ(Y), pred(Z)) :- isMinus(zero, Y, Z). isMinus(zero, pred(Y), succ(Z)) :- isMinus(zero, Y, Z). isMinus(succ(X), succ(Y), Z) :- isMinus(X, Y, Z). isMinus(succ(X), pred(Y), succ(succ(Z))) :- isMinus(X, Y, Z). isMinus(pred(X), succ(Y), pred(pred(Z))) :- isMinus(X, Y, Z). isMinus(pred(X), pred(Y), Z) :- isMinus(X, Y, Z). isTimes(X, zero, zero). isTimes(zero, succ(Y), zero). isTimes(zero, pred(Y), zero). isTimes(succ(X), succ(Y), Z) :- ','(isTimes(succ(X), Y, A), isPlus(A, succ(X), Z)). isTimes(succ(X), pred(Y), Z) :- ','(isTimes(succ(X), Y, A), isMinus(A, succ(X), Z)). isTimes(pred(X), succ(Y), Z) :- ','(isTimes(pred(X), Y, A), isPlus(A, pred(X), Z)). isTimes(pred(X), pred(Y), Z) :- ','(isTimes(pred(X), Y, A), isMinus(A, pred(X), Z)). isDiv(zero, succ(Y), zero). isDiv(zero, pred(Y), zero). isDiv(succ(X), succ(Y), zero) :- isMinus(succ(X), succ(Y), pred(Z)). isDiv(succ(X), succ(Y), succ(Z)) :- ','(isMinus(succ(X), succ(Y), A), isDiv(A, succ(Y), Z)). isDiv(succ(X), pred(Y), Z) :- ','(isMinus(zero, pred(Y), A), ','(isDiv(succ(X), A, B), isMinus(zero, B, Z))). isDiv(pred(X), pred(Y), zero) :- isMinus(pred(X), pred(Y), succ(Z)). isDiv(pred(X), pred(Y), succ(Z)) :- ','(isMinus(pred(X), pred(Y), A), isDiv(A, pred(Y), Z)). isDiv(pred(X), succ(Y), Z) :- ','(isMinus(zero, pred(X), A), ','(isDiv(A, succ(Y), B), isMinus(zero, B, Z))). isModulo(X, Y, Z) :- ','(isDiv(X, Y, A), ','(isTimes(A, Y, B), isMinus(X, B, Z))). isGreater(succ(X), zero). isGreater(succ(X), pred(Y)). isGreater(succ(X), succ(Y)) :- isGreater(X, Y). isGreater(zero, pred(Y)). isGreater(pred(X), pred(Y)) :- isGreater(X, Y). isLess(pred(X), zero). isLess(pred(X), succ(Y)). isLess(pred(X), pred(Y)) :- isLess(X, Y). isLess(zero, succ(Y)). isLess(succ(X), succ(Y)) :- isLess(X, Y). =(X, X). Query: find(g,g) ---------------------------------------- (7) OrTransformerProof (EQUIVALENT) Transformed all or-constructs[PROLOG]. ---------------------------------------- (8) Obligation: Clauses: find([], X1). find(Vec, Val) :- find(Vec, Val, Vec). find([], Val, Start) :- ','(addOne(Start, StartPlusOne), find(StartPlusOne, Val)). find(.(X, X2), Val, X3) :- ','(=(X1, X), ','(=(X4, Val), isGreater(X1, X4))). find(.(X, X2), Val, X3) :- ','(=(X1, X), ','(=(X4, Val), =(X1, X4))). find(.(X, Xs), Val, Start) :- ','(=(X1, X), ','(=(X2, Val), ','(isLess(X1, X2), find(Xs, Val, Start)))). addOne([], []). addOne(.(X, Xs), .(Y, Ys)) :- ','(isPlus(X, succ(zero), U), ','(=(Y, U), addOne(Xs, Ys))). isPlus(zero, X, X). isPlus(succ(X), zero, succ(X)). isPlus(succ(X), succ(Y), succ(succ(Z))) :- isPlus(X, Y, Z). isPlus(succ(X), pred(Y), Z) :- isPlus(X, Y, Z). isPlus(pred(X), zero, pred(X)). isPlus(pred(X), succ(Y), Z) :- isPlus(X, Y, Z). isPlus(pred(X), pred(Y), pred(pred(Z))) :- isPlus(X, Y, Z). isMinus(X, zero, X). isMinus(zero, succ(Y), pred(Z)) :- isMinus(zero, Y, Z). isMinus(zero, pred(Y), succ(Z)) :- isMinus(zero, Y, Z). isMinus(succ(X), succ(Y), Z) :- isMinus(X, Y, Z). isMinus(succ(X), pred(Y), succ(succ(Z))) :- isMinus(X, Y, Z). isMinus(pred(X), succ(Y), pred(pred(Z))) :- isMinus(X, Y, Z). isMinus(pred(X), pred(Y), Z) :- isMinus(X, Y, Z). isTimes(X, zero, zero). isTimes(zero, succ(Y), zero). isTimes(zero, pred(Y), zero). isTimes(succ(X), succ(Y), Z) :- ','(isTimes(succ(X), Y, A), isPlus(A, succ(X), Z)). isTimes(succ(X), pred(Y), Z) :- ','(isTimes(succ(X), Y, A), isMinus(A, succ(X), Z)). isTimes(pred(X), succ(Y), Z) :- ','(isTimes(pred(X), Y, A), isPlus(A, pred(X), Z)). isTimes(pred(X), pred(Y), Z) :- ','(isTimes(pred(X), Y, A), isMinus(A, pred(X), Z)). isDiv(zero, succ(Y), zero). isDiv(zero, pred(Y), zero). isDiv(succ(X), succ(Y), zero) :- isMinus(succ(X), succ(Y), pred(Z)). isDiv(succ(X), succ(Y), succ(Z)) :- ','(isMinus(succ(X), succ(Y), A), isDiv(A, succ(Y), Z)). isDiv(succ(X), pred(Y), Z) :- ','(isMinus(zero, pred(Y), A), ','(isDiv(succ(X), A, B), isMinus(zero, B, Z))). isDiv(pred(X), pred(Y), zero) :- isMinus(pred(X), pred(Y), succ(Z)). isDiv(pred(X), pred(Y), succ(Z)) :- ','(isMinus(pred(X), pred(Y), A), isDiv(A, pred(Y), Z)). isDiv(pred(X), succ(Y), Z) :- ','(isMinus(zero, pred(X), A), ','(isDiv(A, succ(Y), B), isMinus(zero, B, Z))). isModulo(X, Y, Z) :- ','(isDiv(X, Y, A), ','(isTimes(A, Y, B), isMinus(X, B, Z))). isGreater(succ(X), zero). isGreater(succ(X), pred(Y)). isGreater(succ(X), succ(Y)) :- isGreater(X, Y). isGreater(zero, pred(Y)). isGreater(pred(X), pred(Y)) :- isGreater(X, Y). isLess(pred(X), zero). isLess(pred(X), succ(Y)). isLess(pred(X), pred(Y)) :- isLess(X, Y). isLess(zero, succ(Y)). isLess(succ(X), succ(Y)) :- isLess(X, Y). =(X, X). Query: find(g,g) ---------------------------------------- (9) PrologToPiTRSProof (SOUND) We use the technique of [TOCL09]. With regard to the inferred argument filtering the predicates were used in the following modes: find_in_2: (b,b) find_in_3: (b,b,b) addOne_in_2: (b,f) isPlus_in_3: (b,b,f) isGreater_in_2: (b,b) isLess_in_2: (b,b) Transforming Prolog into the following Term Rewriting System: Pi-finite rewrite system: The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x4) U17_gga(x1, x2, x3, x4) = U17_gga(x4) U18_gga(x1, x2, x3, x4) = U18_gga(x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x3, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg U48_gg(x1, x2, x3) = U48_gg(x3) U49_gg(x1, x2, x3) = U49_gg(x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg U50_gg(x1, x2, x3) = U50_gg(x3) U51_gg(x1, x2, x3) = U51_gg(x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x5) Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog ---------------------------------------- (10) Obligation: Pi-finite rewrite system: The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x4) U17_gga(x1, x2, x3, x4) = U17_gga(x4) U18_gga(x1, x2, x3, x4) = U18_gga(x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x3, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg U48_gg(x1, x2, x3) = U48_gg(x3) U49_gg(x1, x2, x3) = U49_gg(x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg U50_gg(x1, x2, x3) = U50_gg(x3) U51_gg(x1, x2, x3) = U51_gg(x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x5) ---------------------------------------- (11) 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: FIND_IN_GG(Vec, Val) -> U1_GG(Vec, Val, find_in_ggg(Vec, Val, Vec)) FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) FIND_IN_GGG([], Val, Start) -> ADDONE_IN_GA(Start, StartPlusOne) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U12_GA(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> ISPLUS_IN_GGA(X, succ(zero), U) ISPLUS_IN_GGA(succ(X), succ(Y), succ(succ(Z))) -> U15_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(succ(X), succ(Y), succ(succ(Z))) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(succ(X), pred(Y), Z) -> U16_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(succ(X), pred(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), succ(Y), Z) -> U17_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(pred(X), succ(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), pred(Y), pred(pred(Z))) -> U18_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(pred(X), pred(Y), pred(pred(Z))) -> ISPLUS_IN_GGA(X, Y, Z) U12_GA(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_GA(X, Xs, Y, Ys, =_in_ag(Y, U)) U12_GA(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> =_IN_AG(Y, U) U13_GA(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_GA(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U13_GA(X, Xs, Y, Ys, =_out_ag(Y, U)) -> ADDONE_IN_GA(Xs, Ys) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_GGG(Val, Start, find_in_gg(StartPlusOne, Val)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, X2), Val, X3) -> U4_GGG(X, X2, Val, X3, =_in_ag(X1, X)) FIND_IN_GGG(.(X, X2), Val, X3) -> =_IN_AG(X1, X) U4_GGG(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_GGG(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U4_GGG(X, X2, Val, X3, =_out_ag(X1, X)) -> =_IN_AG(X4, Val) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_GGG(X, X2, Val, X3, isGreater_in_gg(X1, X4)) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> ISGREATER_IN_GG(X1, X4) ISGREATER_IN_GG(succ(X), succ(Y)) -> U48_GG(X, Y, isGreater_in_gg(X, Y)) ISGREATER_IN_GG(succ(X), succ(Y)) -> ISGREATER_IN_GG(X, Y) ISGREATER_IN_GG(pred(X), pred(Y)) -> U49_GG(X, Y, isGreater_in_gg(X, Y)) ISGREATER_IN_GG(pred(X), pred(Y)) -> ISGREATER_IN_GG(X, Y) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_GGG(X, X2, Val, X3, =_in_gg(X1, X4)) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> =_IN_GG(X1, X4) FIND_IN_GGG(.(X, Xs), Val, Start) -> U8_GGG(X, Xs, Val, Start, =_in_ag(X1, X)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_GGG(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> =_IN_AG(X2, Val) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_GGG(X, Xs, Val, Start, isLess_in_gg(X1, X2)) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> ISLESS_IN_GG(X1, X2) ISLESS_IN_GG(pred(X), pred(Y)) -> U50_GG(X, Y, isLess_in_gg(X, Y)) ISLESS_IN_GG(pred(X), pred(Y)) -> ISLESS_IN_GG(X, Y) ISLESS_IN_GG(succ(X), succ(Y)) -> U51_GG(X, Y, isLess_in_gg(X, Y)) ISLESS_IN_GG(succ(X), succ(Y)) -> ISLESS_IN_GG(X, Y) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_GGG(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x4) U17_gga(x1, x2, x3, x4) = U17_gga(x4) U18_gga(x1, x2, x3, x4) = U18_gga(x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x3, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg U48_gg(x1, x2, x3) = U48_gg(x3) U49_gg(x1, x2, x3) = U49_gg(x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg U50_gg(x1, x2, x3) = U50_gg(x3) U51_gg(x1, x2, x3) = U51_gg(x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x5) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) U1_GG(x1, x2, x3) = U1_GG(x3) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x3) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U12_GA(x1, x2, x3, x4, x5) = U12_GA(x2, x5) ISPLUS_IN_GGA(x1, x2, x3) = ISPLUS_IN_GGA(x1, x2) U15_GGA(x1, x2, x3, x4) = U15_GGA(x4) U16_GGA(x1, x2, x3, x4) = U16_GGA(x4) U17_GGA(x1, x2, x3, x4) = U17_GGA(x4) U18_GGA(x1, x2, x3, x4) = U18_GGA(x4) U13_GA(x1, x2, x3, x4, x5) = U13_GA(x2, x5) =_IN_AG(x1, x2) = =_IN_AG(x2) U14_GA(x1, x2, x3, x4, x5) = U14_GA(x3, x5) U3_GGG(x1, x2, x3) = U3_GGG(x3) U4_GGG(x1, x2, x3, x4, x5) = U4_GGG(x3, x5) U5_GGG(x1, x2, x3, x4, x5, x6) = U5_GGG(x5, x6) U6_GGG(x1, x2, x3, x4, x5) = U6_GGG(x5) ISGREATER_IN_GG(x1, x2) = ISGREATER_IN_GG(x1, x2) U48_GG(x1, x2, x3) = U48_GG(x3) U49_GG(x1, x2, x3) = U49_GG(x3) U7_GGG(x1, x2, x3, x4, x5) = U7_GGG(x5) =_IN_GG(x1, x2) = =_IN_GG(x1, x2) U8_GGG(x1, x2, x3, x4, x5) = U8_GGG(x2, x3, x4, x5) U9_GGG(x1, x2, x3, x4, x5, x6) = U9_GGG(x2, x3, x4, x5, x6) U10_GGG(x1, x2, x3, x4, x5) = U10_GGG(x2, x3, x4, x5) ISLESS_IN_GG(x1, x2) = ISLESS_IN_GG(x1, x2) U50_GG(x1, x2, x3) = U50_GG(x3) U51_GG(x1, x2, x3) = U51_GG(x3) U11_GGG(x1, x2, x3, x4, x5) = U11_GGG(x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (12) Obligation: Pi DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> U1_GG(Vec, Val, find_in_ggg(Vec, Val, Vec)) FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) FIND_IN_GGG([], Val, Start) -> ADDONE_IN_GA(Start, StartPlusOne) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U12_GA(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> ISPLUS_IN_GGA(X, succ(zero), U) ISPLUS_IN_GGA(succ(X), succ(Y), succ(succ(Z))) -> U15_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(succ(X), succ(Y), succ(succ(Z))) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(succ(X), pred(Y), Z) -> U16_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(succ(X), pred(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), succ(Y), Z) -> U17_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(pred(X), succ(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), pred(Y), pred(pred(Z))) -> U18_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(pred(X), pred(Y), pred(pred(Z))) -> ISPLUS_IN_GGA(X, Y, Z) U12_GA(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_GA(X, Xs, Y, Ys, =_in_ag(Y, U)) U12_GA(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> =_IN_AG(Y, U) U13_GA(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_GA(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U13_GA(X, Xs, Y, Ys, =_out_ag(Y, U)) -> ADDONE_IN_GA(Xs, Ys) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_GGG(Val, Start, find_in_gg(StartPlusOne, Val)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, X2), Val, X3) -> U4_GGG(X, X2, Val, X3, =_in_ag(X1, X)) FIND_IN_GGG(.(X, X2), Val, X3) -> =_IN_AG(X1, X) U4_GGG(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_GGG(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U4_GGG(X, X2, Val, X3, =_out_ag(X1, X)) -> =_IN_AG(X4, Val) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_GGG(X, X2, Val, X3, isGreater_in_gg(X1, X4)) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> ISGREATER_IN_GG(X1, X4) ISGREATER_IN_GG(succ(X), succ(Y)) -> U48_GG(X, Y, isGreater_in_gg(X, Y)) ISGREATER_IN_GG(succ(X), succ(Y)) -> ISGREATER_IN_GG(X, Y) ISGREATER_IN_GG(pred(X), pred(Y)) -> U49_GG(X, Y, isGreater_in_gg(X, Y)) ISGREATER_IN_GG(pred(X), pred(Y)) -> ISGREATER_IN_GG(X, Y) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_GGG(X, X2, Val, X3, =_in_gg(X1, X4)) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> =_IN_GG(X1, X4) FIND_IN_GGG(.(X, Xs), Val, Start) -> U8_GGG(X, Xs, Val, Start, =_in_ag(X1, X)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_GGG(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> =_IN_AG(X2, Val) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_GGG(X, Xs, Val, Start, isLess_in_gg(X1, X2)) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> ISLESS_IN_GG(X1, X2) ISLESS_IN_GG(pred(X), pred(Y)) -> U50_GG(X, Y, isLess_in_gg(X, Y)) ISLESS_IN_GG(pred(X), pred(Y)) -> ISLESS_IN_GG(X, Y) ISLESS_IN_GG(succ(X), succ(Y)) -> U51_GG(X, Y, isLess_in_gg(X, Y)) ISLESS_IN_GG(succ(X), succ(Y)) -> ISLESS_IN_GG(X, Y) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_GGG(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x4) U17_gga(x1, x2, x3, x4) = U17_gga(x4) U18_gga(x1, x2, x3, x4) = U18_gga(x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x3, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg U48_gg(x1, x2, x3) = U48_gg(x3) U49_gg(x1, x2, x3) = U49_gg(x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg U50_gg(x1, x2, x3) = U50_gg(x3) U51_gg(x1, x2, x3) = U51_gg(x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x5) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) U1_GG(x1, x2, x3) = U1_GG(x3) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x3) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U12_GA(x1, x2, x3, x4, x5) = U12_GA(x2, x5) ISPLUS_IN_GGA(x1, x2, x3) = ISPLUS_IN_GGA(x1, x2) U15_GGA(x1, x2, x3, x4) = U15_GGA(x4) U16_GGA(x1, x2, x3, x4) = U16_GGA(x4) U17_GGA(x1, x2, x3, x4) = U17_GGA(x4) U18_GGA(x1, x2, x3, x4) = U18_GGA(x4) U13_GA(x1, x2, x3, x4, x5) = U13_GA(x2, x5) =_IN_AG(x1, x2) = =_IN_AG(x2) U14_GA(x1, x2, x3, x4, x5) = U14_GA(x3, x5) U3_GGG(x1, x2, x3) = U3_GGG(x3) U4_GGG(x1, x2, x3, x4, x5) = U4_GGG(x3, x5) U5_GGG(x1, x2, x3, x4, x5, x6) = U5_GGG(x5, x6) U6_GGG(x1, x2, x3, x4, x5) = U6_GGG(x5) ISGREATER_IN_GG(x1, x2) = ISGREATER_IN_GG(x1, x2) U48_GG(x1, x2, x3) = U48_GG(x3) U49_GG(x1, x2, x3) = U49_GG(x3) U7_GGG(x1, x2, x3, x4, x5) = U7_GGG(x5) =_IN_GG(x1, x2) = =_IN_GG(x1, x2) U8_GGG(x1, x2, x3, x4, x5) = U8_GGG(x2, x3, x4, x5) U9_GGG(x1, x2, x3, x4, x5, x6) = U9_GGG(x2, x3, x4, x5, x6) U10_GGG(x1, x2, x3, x4, x5) = U10_GGG(x2, x3, x4, x5) ISLESS_IN_GG(x1, x2) = ISLESS_IN_GG(x1, x2) U50_GG(x1, x2, x3) = U50_GG(x3) U51_GG(x1, x2, x3) = U51_GG(x3) U11_GGG(x1, x2, x3, x4, x5) = U11_GGG(x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (13) DependencyGraphProof (EQUIVALENT) The approximation of the Dependency Graph [LOPSTR] contains 5 SCCs with 25 less nodes. ---------------------------------------- (14) Complex Obligation (AND) ---------------------------------------- (15) Obligation: Pi DP problem: The TRS P consists of the following rules: ISLESS_IN_GG(succ(X), succ(Y)) -> ISLESS_IN_GG(X, Y) ISLESS_IN_GG(pred(X), pred(Y)) -> ISLESS_IN_GG(X, Y) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x4) U17_gga(x1, x2, x3, x4) = U17_gga(x4) U18_gga(x1, x2, x3, x4) = U18_gga(x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x3, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg U48_gg(x1, x2, x3) = U48_gg(x3) U49_gg(x1, x2, x3) = U49_gg(x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg U50_gg(x1, x2, x3) = U50_gg(x3) U51_gg(x1, x2, x3) = U51_gg(x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x5) ISLESS_IN_GG(x1, x2) = ISLESS_IN_GG(x1, x2) We have to consider all (P,R,Pi)-chains ---------------------------------------- (16) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (17) Obligation: Pi DP problem: The TRS P consists of the following rules: ISLESS_IN_GG(succ(X), succ(Y)) -> ISLESS_IN_GG(X, Y) ISLESS_IN_GG(pred(X), pred(Y)) -> ISLESS_IN_GG(X, Y) R is empty. Pi is empty. We have to consider all (P,R,Pi)-chains ---------------------------------------- (18) PiDPToQDPProof (EQUIVALENT) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (19) Obligation: Q DP problem: The TRS P consists of the following rules: ISLESS_IN_GG(succ(X), succ(Y)) -> ISLESS_IN_GG(X, Y) ISLESS_IN_GG(pred(X), pred(Y)) -> ISLESS_IN_GG(X, Y) R is empty. Q is empty. We have to consider all (P,Q,R)-chains. ---------------------------------------- (20) 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: *ISLESS_IN_GG(succ(X), succ(Y)) -> ISLESS_IN_GG(X, Y) The graph contains the following edges 1 > 1, 2 > 2 *ISLESS_IN_GG(pred(X), pred(Y)) -> ISLESS_IN_GG(X, Y) The graph contains the following edges 1 > 1, 2 > 2 ---------------------------------------- (21) YES ---------------------------------------- (22) Obligation: Pi DP problem: The TRS P consists of the following rules: ISGREATER_IN_GG(pred(X), pred(Y)) -> ISGREATER_IN_GG(X, Y) ISGREATER_IN_GG(succ(X), succ(Y)) -> ISGREATER_IN_GG(X, Y) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x4) U17_gga(x1, x2, x3, x4) = U17_gga(x4) U18_gga(x1, x2, x3, x4) = U18_gga(x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x3, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg U48_gg(x1, x2, x3) = U48_gg(x3) U49_gg(x1, x2, x3) = U49_gg(x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg U50_gg(x1, x2, x3) = U50_gg(x3) U51_gg(x1, x2, x3) = U51_gg(x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x5) ISGREATER_IN_GG(x1, x2) = ISGREATER_IN_GG(x1, x2) We have to consider all (P,R,Pi)-chains ---------------------------------------- (23) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (24) Obligation: Pi DP problem: The TRS P consists of the following rules: ISGREATER_IN_GG(pred(X), pred(Y)) -> ISGREATER_IN_GG(X, Y) ISGREATER_IN_GG(succ(X), succ(Y)) -> ISGREATER_IN_GG(X, Y) R is empty. Pi is empty. We have to consider all (P,R,Pi)-chains ---------------------------------------- (25) PiDPToQDPProof (EQUIVALENT) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (26) Obligation: Q DP problem: The TRS P consists of the following rules: ISGREATER_IN_GG(pred(X), pred(Y)) -> ISGREATER_IN_GG(X, Y) ISGREATER_IN_GG(succ(X), succ(Y)) -> ISGREATER_IN_GG(X, Y) R is empty. Q is empty. We have to consider all (P,Q,R)-chains. ---------------------------------------- (27) 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: *ISGREATER_IN_GG(pred(X), pred(Y)) -> ISGREATER_IN_GG(X, Y) The graph contains the following edges 1 > 1, 2 > 2 *ISGREATER_IN_GG(succ(X), succ(Y)) -> ISGREATER_IN_GG(X, Y) The graph contains the following edges 1 > 1, 2 > 2 ---------------------------------------- (28) YES ---------------------------------------- (29) Obligation: Pi DP problem: The TRS P consists of the following rules: ISPLUS_IN_GGA(succ(X), pred(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(succ(X), succ(Y), succ(succ(Z))) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), succ(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), pred(Y), pred(pred(Z))) -> ISPLUS_IN_GGA(X, Y, Z) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x4) U17_gga(x1, x2, x3, x4) = U17_gga(x4) U18_gga(x1, x2, x3, x4) = U18_gga(x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x3, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg U48_gg(x1, x2, x3) = U48_gg(x3) U49_gg(x1, x2, x3) = U49_gg(x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg U50_gg(x1, x2, x3) = U50_gg(x3) U51_gg(x1, x2, x3) = U51_gg(x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x5) ISPLUS_IN_GGA(x1, x2, x3) = ISPLUS_IN_GGA(x1, x2) We have to consider all (P,R,Pi)-chains ---------------------------------------- (30) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (31) Obligation: Pi DP problem: The TRS P consists of the following rules: ISPLUS_IN_GGA(succ(X), pred(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(succ(X), succ(Y), succ(succ(Z))) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), succ(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), pred(Y), pred(pred(Z))) -> ISPLUS_IN_GGA(X, Y, Z) R is empty. The argument filtering Pi contains the following mapping: succ(x1) = succ(x1) pred(x1) = pred(x1) ISPLUS_IN_GGA(x1, x2, x3) = ISPLUS_IN_GGA(x1, x2) We have to consider all (P,R,Pi)-chains ---------------------------------------- (32) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (33) Obligation: Q DP problem: The TRS P consists of the following rules: ISPLUS_IN_GGA(succ(X), pred(Y)) -> ISPLUS_IN_GGA(X, Y) ISPLUS_IN_GGA(succ(X), succ(Y)) -> ISPLUS_IN_GGA(X, Y) ISPLUS_IN_GGA(pred(X), succ(Y)) -> ISPLUS_IN_GGA(X, Y) ISPLUS_IN_GGA(pred(X), pred(Y)) -> ISPLUS_IN_GGA(X, Y) R is empty. Q is empty. We have to consider all (P,Q,R)-chains. ---------------------------------------- (34) 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: *ISPLUS_IN_GGA(succ(X), pred(Y)) -> ISPLUS_IN_GGA(X, Y) The graph contains the following edges 1 > 1, 2 > 2 *ISPLUS_IN_GGA(succ(X), succ(Y)) -> ISPLUS_IN_GGA(X, Y) The graph contains the following edges 1 > 1, 2 > 2 *ISPLUS_IN_GGA(pred(X), succ(Y)) -> ISPLUS_IN_GGA(X, Y) The graph contains the following edges 1 > 1, 2 > 2 *ISPLUS_IN_GGA(pred(X), pred(Y)) -> ISPLUS_IN_GGA(X, Y) The graph contains the following edges 1 > 1, 2 > 2 ---------------------------------------- (35) YES ---------------------------------------- (36) Obligation: Pi DP problem: The TRS P consists of the following rules: U12_GA(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_GA(X, Xs, Y, Ys, =_in_ag(Y, U)) U13_GA(X, Xs, Y, Ys, =_out_ag(Y, U)) -> ADDONE_IN_GA(Xs, Ys) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U12_GA(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x4) U17_gga(x1, x2, x3, x4) = U17_gga(x4) U18_gga(x1, x2, x3, x4) = U18_gga(x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x3, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg U48_gg(x1, x2, x3) = U48_gg(x3) U49_gg(x1, x2, x3) = U49_gg(x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg U50_gg(x1, x2, x3) = U50_gg(x3) U51_gg(x1, x2, x3) = U51_gg(x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x5) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U12_GA(x1, x2, x3, x4, x5) = U12_GA(x2, x5) U13_GA(x1, x2, x3, x4, x5) = U13_GA(x2, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (37) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (38) Obligation: Pi DP problem: The TRS P consists of the following rules: U12_GA(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_GA(X, Xs, Y, Ys, =_in_ag(Y, U)) U13_GA(X, Xs, Y, Ys, =_out_ag(Y, U)) -> ADDONE_IN_GA(Xs, Ys) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U12_GA(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) The TRS R consists of the following rules: =_in_ag(X, X) -> =_out_ag(X, X) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) The argument filtering Pi contains the following mapping: .(x1, x2) = .(x1, x2) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x4) U17_gga(x1, x2, x3, x4) = U17_gga(x4) U18_gga(x1, x2, x3, x4) = U18_gga(x4) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U12_GA(x1, x2, x3, x4, x5) = U12_GA(x2, x5) U13_GA(x1, x2, x3, x4, x5) = U13_GA(x2, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (39) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (40) Obligation: Q DP problem: The TRS P consists of the following rules: U12_GA(Xs, isPlus_out_gga(U)) -> U13_GA(Xs, =_in_ag(U)) U13_GA(Xs, =_out_ag(Y)) -> ADDONE_IN_GA(Xs) ADDONE_IN_GA(.(X, Xs)) -> U12_GA(Xs, isPlus_in_gga(X, succ(zero))) The TRS R consists of the following rules: =_in_ag(X) -> =_out_ag(X) isPlus_in_gga(zero, X) -> isPlus_out_gga(X) isPlus_in_gga(succ(X), succ(Y)) -> U15_gga(isPlus_in_gga(X, Y)) isPlus_in_gga(pred(X), succ(Y)) -> U17_gga(isPlus_in_gga(X, Y)) U15_gga(isPlus_out_gga(Z)) -> isPlus_out_gga(succ(succ(Z))) U17_gga(isPlus_out_gga(Z)) -> isPlus_out_gga(Z) isPlus_in_gga(succ(X), zero) -> isPlus_out_gga(succ(X)) isPlus_in_gga(succ(X), pred(Y)) -> U16_gga(isPlus_in_gga(X, Y)) isPlus_in_gga(pred(X), zero) -> isPlus_out_gga(pred(X)) isPlus_in_gga(pred(X), pred(Y)) -> U18_gga(isPlus_in_gga(X, Y)) U16_gga(isPlus_out_gga(Z)) -> isPlus_out_gga(Z) U18_gga(isPlus_out_gga(Z)) -> isPlus_out_gga(pred(pred(Z))) The set Q consists of the following terms: =_in_ag(x0) isPlus_in_gga(x0, x1) U15_gga(x0) U17_gga(x0) U16_gga(x0) U18_gga(x0) We have to consider all (P,Q,R)-chains. ---------------------------------------- (41) 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: *U13_GA(Xs, =_out_ag(Y)) -> ADDONE_IN_GA(Xs) The graph contains the following edges 1 >= 1 *ADDONE_IN_GA(.(X, Xs)) -> U12_GA(Xs, isPlus_in_gga(X, succ(zero))) The graph contains the following edges 1 > 1 *U12_GA(Xs, isPlus_out_gga(U)) -> U13_GA(Xs, =_in_ag(U)) The graph contains the following edges 1 >= 1 ---------------------------------------- (42) YES ---------------------------------------- (43) Obligation: Pi DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U8_GGG(X, Xs, Val, Start, =_in_ag(X1, X)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_GGG(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_GGG(X, Xs, Val, Start, isLess_in_gg(X1, X2)) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x4) U17_gga(x1, x2, x3, x4) = U17_gga(x4) U18_gga(x1, x2, x3, x4) = U18_gga(x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x3, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg U48_gg(x1, x2, x3) = U48_gg(x3) U49_gg(x1, x2, x3) = U49_gg(x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg U50_gg(x1, x2, x3) = U50_gg(x3) U51_gg(x1, x2, x3) = U51_gg(x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x5) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x3) U8_GGG(x1, x2, x3, x4, x5) = U8_GGG(x2, x3, x4, x5) U9_GGG(x1, x2, x3, x4, x5, x6) = U9_GGG(x2, x3, x4, x5, x6) U10_GGG(x1, x2, x3, x4, x5) = U10_GGG(x2, x3, x4, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (44) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (45) Obligation: Pi DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U8_GGG(X, Xs, Val, Start, =_in_ag(X1, X)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_GGG(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_GGG(X, Xs, Val, Start, isLess_in_gg(X1, X2)) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) =_in_ag(X, X) -> =_out_ag(X, X) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) The argument filtering Pi contains the following mapping: [] = [] addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x4) U17_gga(x1, x2, x3, x4) = U17_gga(x4) U18_gga(x1, x2, x3, x4) = U18_gga(x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x3, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg U50_gg(x1, x2, x3) = U50_gg(x3) U51_gg(x1, x2, x3) = U51_gg(x3) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x3) U8_GGG(x1, x2, x3, x4, x5) = U8_GGG(x2, x3, x4, x5) U9_GGG(x1, x2, x3, x4, x5, x6) = U9_GGG(x2, x3, x4, x5, x6) U10_GGG(x1, x2, x3, x4, x5) = U10_GGG(x2, x3, x4, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (46) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (47) Obligation: Q DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, addOne_in_ga(Start)) U2_GGG(Val, addOne_out_ga(StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U8_GGG(Xs, Val, Start, =_in_ag(X)) U8_GGG(Xs, Val, Start, =_out_ag(X1)) -> U9_GGG(Xs, Val, Start, X1, =_in_ag(Val)) U9_GGG(Xs, Val, Start, X1, =_out_ag(X2)) -> U10_GGG(Xs, Val, Start, isLess_in_gg(X1, X2)) U10_GGG(Xs, Val, Start, isLess_out_gg) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: addOne_in_ga([]) -> addOne_out_ga([]) addOne_in_ga(.(X, Xs)) -> U12_ga(Xs, isPlus_in_gga(X, succ(zero))) =_in_ag(X) -> =_out_ag(X) isLess_in_gg(pred(X), zero) -> isLess_out_gg isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg isLess_in_gg(pred(X), pred(Y)) -> U50_gg(isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg isLess_in_gg(succ(X), succ(Y)) -> U51_gg(isLess_in_gg(X, Y)) U12_ga(Xs, isPlus_out_gga(U)) -> U13_ga(Xs, =_in_ag(U)) U50_gg(isLess_out_gg) -> isLess_out_gg U51_gg(isLess_out_gg) -> isLess_out_gg isPlus_in_gga(zero, X) -> isPlus_out_gga(X) isPlus_in_gga(succ(X), succ(Y)) -> U15_gga(isPlus_in_gga(X, Y)) isPlus_in_gga(pred(X), succ(Y)) -> U17_gga(isPlus_in_gga(X, Y)) U13_ga(Xs, =_out_ag(Y)) -> U14_ga(Y, addOne_in_ga(Xs)) U15_gga(isPlus_out_gga(Z)) -> isPlus_out_gga(succ(succ(Z))) U17_gga(isPlus_out_gga(Z)) -> isPlus_out_gga(Z) U14_ga(Y, addOne_out_ga(Ys)) -> addOne_out_ga(.(Y, Ys)) isPlus_in_gga(succ(X), zero) -> isPlus_out_gga(succ(X)) isPlus_in_gga(succ(X), pred(Y)) -> U16_gga(isPlus_in_gga(X, Y)) isPlus_in_gga(pred(X), zero) -> isPlus_out_gga(pred(X)) isPlus_in_gga(pred(X), pred(Y)) -> U18_gga(isPlus_in_gga(X, Y)) U16_gga(isPlus_out_gga(Z)) -> isPlus_out_gga(Z) U18_gga(isPlus_out_gga(Z)) -> isPlus_out_gga(pred(pred(Z))) The set Q consists of the following terms: addOne_in_ga(x0) =_in_ag(x0) isLess_in_gg(x0, x1) U12_ga(x0, x1) U50_gg(x0) U51_gg(x0) isPlus_in_gga(x0, x1) U13_ga(x0, x1) U15_gga(x0) U17_gga(x0) U14_ga(x0, x1) U16_gga(x0) U18_gga(x0) We have to consider all (P,Q,R)-chains. ---------------------------------------- (48) PrologToPiTRSProof (SOUND) We use the technique of [TOCL09]. With regard to the inferred argument filtering the predicates were used in the following modes: find_in_2: (b,b) find_in_3: (b,b,b) addOne_in_2: (b,f) isPlus_in_3: (b,b,f) isGreater_in_2: (b,b) isLess_in_2: (b,b) Transforming Prolog into the following Term Rewriting System: Pi-finite rewrite system: The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x1, x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x1, x2, x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x1, x2, x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x1, x2, x4) U17_gga(x1, x2, x3, x4) = U17_gga(x1, x2, x4) U18_gga(x1, x2, x3, x4) = U18_gga(x1, x2, x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x1, x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1, x2) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x1, x2, x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x1, x2, x3, x4, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x1, x2, x3, x4, x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x1, x2, x3, x4, x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg(x1, x2) U48_gg(x1, x2, x3) = U48_gg(x1, x2, x3) U49_gg(x1, x2, x3) = U49_gg(x1, x2, x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x1, x2, x3, x4, x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg(x1, x2) U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x1, x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x1, x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x1, x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg(x1, x2) U50_gg(x1, x2, x3) = U50_gg(x1, x2, x3) U51_gg(x1, x2, x3) = U51_gg(x1, x2, x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x1, x2, x3, x4, x5) Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog ---------------------------------------- (49) Obligation: Pi-finite rewrite system: The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x1, x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x1, x2, x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x1, x2, x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x1, x2, x4) U17_gga(x1, x2, x3, x4) = U17_gga(x1, x2, x4) U18_gga(x1, x2, x3, x4) = U18_gga(x1, x2, x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x1, x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1, x2) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x1, x2, x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x1, x2, x3, x4, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x1, x2, x3, x4, x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x1, x2, x3, x4, x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg(x1, x2) U48_gg(x1, x2, x3) = U48_gg(x1, x2, x3) U49_gg(x1, x2, x3) = U49_gg(x1, x2, x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x1, x2, x3, x4, x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg(x1, x2) U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x1, x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x1, x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x1, x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg(x1, x2) U50_gg(x1, x2, x3) = U50_gg(x1, x2, x3) U51_gg(x1, x2, x3) = U51_gg(x1, x2, x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x1, x2, x3, x4, x5) ---------------------------------------- (50) 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: FIND_IN_GG(Vec, Val) -> U1_GG(Vec, Val, find_in_ggg(Vec, Val, Vec)) FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) FIND_IN_GGG([], Val, Start) -> ADDONE_IN_GA(Start, StartPlusOne) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U12_GA(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> ISPLUS_IN_GGA(X, succ(zero), U) ISPLUS_IN_GGA(succ(X), succ(Y), succ(succ(Z))) -> U15_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(succ(X), succ(Y), succ(succ(Z))) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(succ(X), pred(Y), Z) -> U16_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(succ(X), pred(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), succ(Y), Z) -> U17_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(pred(X), succ(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), pred(Y), pred(pred(Z))) -> U18_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(pred(X), pred(Y), pred(pred(Z))) -> ISPLUS_IN_GGA(X, Y, Z) U12_GA(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_GA(X, Xs, Y, Ys, =_in_ag(Y, U)) U12_GA(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> =_IN_AG(Y, U) U13_GA(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_GA(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U13_GA(X, Xs, Y, Ys, =_out_ag(Y, U)) -> ADDONE_IN_GA(Xs, Ys) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_GGG(Val, Start, find_in_gg(StartPlusOne, Val)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, X2), Val, X3) -> U4_GGG(X, X2, Val, X3, =_in_ag(X1, X)) FIND_IN_GGG(.(X, X2), Val, X3) -> =_IN_AG(X1, X) U4_GGG(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_GGG(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U4_GGG(X, X2, Val, X3, =_out_ag(X1, X)) -> =_IN_AG(X4, Val) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_GGG(X, X2, Val, X3, isGreater_in_gg(X1, X4)) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> ISGREATER_IN_GG(X1, X4) ISGREATER_IN_GG(succ(X), succ(Y)) -> U48_GG(X, Y, isGreater_in_gg(X, Y)) ISGREATER_IN_GG(succ(X), succ(Y)) -> ISGREATER_IN_GG(X, Y) ISGREATER_IN_GG(pred(X), pred(Y)) -> U49_GG(X, Y, isGreater_in_gg(X, Y)) ISGREATER_IN_GG(pred(X), pred(Y)) -> ISGREATER_IN_GG(X, Y) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_GGG(X, X2, Val, X3, =_in_gg(X1, X4)) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> =_IN_GG(X1, X4) FIND_IN_GGG(.(X, Xs), Val, Start) -> U8_GGG(X, Xs, Val, Start, =_in_ag(X1, X)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_GGG(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> =_IN_AG(X2, Val) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_GGG(X, Xs, Val, Start, isLess_in_gg(X1, X2)) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> ISLESS_IN_GG(X1, X2) ISLESS_IN_GG(pred(X), pred(Y)) -> U50_GG(X, Y, isLess_in_gg(X, Y)) ISLESS_IN_GG(pred(X), pred(Y)) -> ISLESS_IN_GG(X, Y) ISLESS_IN_GG(succ(X), succ(Y)) -> U51_GG(X, Y, isLess_in_gg(X, Y)) ISLESS_IN_GG(succ(X), succ(Y)) -> ISLESS_IN_GG(X, Y) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_GGG(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x1, x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x1, x2, x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x1, x2, x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x1, x2, x4) U17_gga(x1, x2, x3, x4) = U17_gga(x1, x2, x4) U18_gga(x1, x2, x3, x4) = U18_gga(x1, x2, x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x1, x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1, x2) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x1, x2, x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x1, x2, x3, x4, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x1, x2, x3, x4, x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x1, x2, x3, x4, x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg(x1, x2) U48_gg(x1, x2, x3) = U48_gg(x1, x2, x3) U49_gg(x1, x2, x3) = U49_gg(x1, x2, x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x1, x2, x3, x4, x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg(x1, x2) U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x1, x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x1, x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x1, x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg(x1, x2) U50_gg(x1, x2, x3) = U50_gg(x1, x2, x3) U51_gg(x1, x2, x3) = U51_gg(x1, x2, x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x1, x2, x3, x4, x5) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) U1_GG(x1, x2, x3) = U1_GG(x1, x2, x3) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x2, x3) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U12_GA(x1, x2, x3, x4, x5) = U12_GA(x1, x2, x5) ISPLUS_IN_GGA(x1, x2, x3) = ISPLUS_IN_GGA(x1, x2) U15_GGA(x1, x2, x3, x4) = U15_GGA(x1, x2, x4) U16_GGA(x1, x2, x3, x4) = U16_GGA(x1, x2, x4) U17_GGA(x1, x2, x3, x4) = U17_GGA(x1, x2, x4) U18_GGA(x1, x2, x3, x4) = U18_GGA(x1, x2, x4) U13_GA(x1, x2, x3, x4, x5) = U13_GA(x1, x2, x5) =_IN_AG(x1, x2) = =_IN_AG(x2) U14_GA(x1, x2, x3, x4, x5) = U14_GA(x1, x2, x3, x5) U3_GGG(x1, x2, x3) = U3_GGG(x1, x2, x3) U4_GGG(x1, x2, x3, x4, x5) = U4_GGG(x1, x2, x3, x4, x5) U5_GGG(x1, x2, x3, x4, x5, x6) = U5_GGG(x1, x2, x3, x4, x5, x6) U6_GGG(x1, x2, x3, x4, x5) = U6_GGG(x1, x2, x3, x4, x5) ISGREATER_IN_GG(x1, x2) = ISGREATER_IN_GG(x1, x2) U48_GG(x1, x2, x3) = U48_GG(x1, x2, x3) U49_GG(x1, x2, x3) = U49_GG(x1, x2, x3) U7_GGG(x1, x2, x3, x4, x5) = U7_GGG(x1, x2, x3, x4, x5) =_IN_GG(x1, x2) = =_IN_GG(x1, x2) U8_GGG(x1, x2, x3, x4, x5) = U8_GGG(x1, x2, x3, x4, x5) U9_GGG(x1, x2, x3, x4, x5, x6) = U9_GGG(x1, x2, x3, x4, x5, x6) U10_GGG(x1, x2, x3, x4, x5) = U10_GGG(x1, x2, x3, x4, x5) ISLESS_IN_GG(x1, x2) = ISLESS_IN_GG(x1, x2) U50_GG(x1, x2, x3) = U50_GG(x1, x2, x3) U51_GG(x1, x2, x3) = U51_GG(x1, x2, x3) U11_GGG(x1, x2, x3, x4, x5) = U11_GGG(x1, x2, x3, x4, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (51) Obligation: Pi DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> U1_GG(Vec, Val, find_in_ggg(Vec, Val, Vec)) FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) FIND_IN_GGG([], Val, Start) -> ADDONE_IN_GA(Start, StartPlusOne) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U12_GA(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> ISPLUS_IN_GGA(X, succ(zero), U) ISPLUS_IN_GGA(succ(X), succ(Y), succ(succ(Z))) -> U15_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(succ(X), succ(Y), succ(succ(Z))) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(succ(X), pred(Y), Z) -> U16_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(succ(X), pred(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), succ(Y), Z) -> U17_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(pred(X), succ(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), pred(Y), pred(pred(Z))) -> U18_GGA(X, Y, Z, isPlus_in_gga(X, Y, Z)) ISPLUS_IN_GGA(pred(X), pred(Y), pred(pred(Z))) -> ISPLUS_IN_GGA(X, Y, Z) U12_GA(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_GA(X, Xs, Y, Ys, =_in_ag(Y, U)) U12_GA(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> =_IN_AG(Y, U) U13_GA(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_GA(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U13_GA(X, Xs, Y, Ys, =_out_ag(Y, U)) -> ADDONE_IN_GA(Xs, Ys) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_GGG(Val, Start, find_in_gg(StartPlusOne, Val)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, X2), Val, X3) -> U4_GGG(X, X2, Val, X3, =_in_ag(X1, X)) FIND_IN_GGG(.(X, X2), Val, X3) -> =_IN_AG(X1, X) U4_GGG(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_GGG(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U4_GGG(X, X2, Val, X3, =_out_ag(X1, X)) -> =_IN_AG(X4, Val) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_GGG(X, X2, Val, X3, isGreater_in_gg(X1, X4)) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> ISGREATER_IN_GG(X1, X4) ISGREATER_IN_GG(succ(X), succ(Y)) -> U48_GG(X, Y, isGreater_in_gg(X, Y)) ISGREATER_IN_GG(succ(X), succ(Y)) -> ISGREATER_IN_GG(X, Y) ISGREATER_IN_GG(pred(X), pred(Y)) -> U49_GG(X, Y, isGreater_in_gg(X, Y)) ISGREATER_IN_GG(pred(X), pred(Y)) -> ISGREATER_IN_GG(X, Y) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_GGG(X, X2, Val, X3, =_in_gg(X1, X4)) U5_GGG(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> =_IN_GG(X1, X4) FIND_IN_GGG(.(X, Xs), Val, Start) -> U8_GGG(X, Xs, Val, Start, =_in_ag(X1, X)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_GGG(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> =_IN_AG(X2, Val) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_GGG(X, Xs, Val, Start, isLess_in_gg(X1, X2)) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> ISLESS_IN_GG(X1, X2) ISLESS_IN_GG(pred(X), pred(Y)) -> U50_GG(X, Y, isLess_in_gg(X, Y)) ISLESS_IN_GG(pred(X), pred(Y)) -> ISLESS_IN_GG(X, Y) ISLESS_IN_GG(succ(X), succ(Y)) -> U51_GG(X, Y, isLess_in_gg(X, Y)) ISLESS_IN_GG(succ(X), succ(Y)) -> ISLESS_IN_GG(X, Y) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_GGG(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x1, x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x1, x2, x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x1, x2, x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x1, x2, x4) U17_gga(x1, x2, x3, x4) = U17_gga(x1, x2, x4) U18_gga(x1, x2, x3, x4) = U18_gga(x1, x2, x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x1, x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1, x2) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x1, x2, x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x1, x2, x3, x4, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x1, x2, x3, x4, x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x1, x2, x3, x4, x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg(x1, x2) U48_gg(x1, x2, x3) = U48_gg(x1, x2, x3) U49_gg(x1, x2, x3) = U49_gg(x1, x2, x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x1, x2, x3, x4, x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg(x1, x2) U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x1, x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x1, x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x1, x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg(x1, x2) U50_gg(x1, x2, x3) = U50_gg(x1, x2, x3) U51_gg(x1, x2, x3) = U51_gg(x1, x2, x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x1, x2, x3, x4, x5) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) U1_GG(x1, x2, x3) = U1_GG(x1, x2, x3) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x2, x3) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U12_GA(x1, x2, x3, x4, x5) = U12_GA(x1, x2, x5) ISPLUS_IN_GGA(x1, x2, x3) = ISPLUS_IN_GGA(x1, x2) U15_GGA(x1, x2, x3, x4) = U15_GGA(x1, x2, x4) U16_GGA(x1, x2, x3, x4) = U16_GGA(x1, x2, x4) U17_GGA(x1, x2, x3, x4) = U17_GGA(x1, x2, x4) U18_GGA(x1, x2, x3, x4) = U18_GGA(x1, x2, x4) U13_GA(x1, x2, x3, x4, x5) = U13_GA(x1, x2, x5) =_IN_AG(x1, x2) = =_IN_AG(x2) U14_GA(x1, x2, x3, x4, x5) = U14_GA(x1, x2, x3, x5) U3_GGG(x1, x2, x3) = U3_GGG(x1, x2, x3) U4_GGG(x1, x2, x3, x4, x5) = U4_GGG(x1, x2, x3, x4, x5) U5_GGG(x1, x2, x3, x4, x5, x6) = U5_GGG(x1, x2, x3, x4, x5, x6) U6_GGG(x1, x2, x3, x4, x5) = U6_GGG(x1, x2, x3, x4, x5) ISGREATER_IN_GG(x1, x2) = ISGREATER_IN_GG(x1, x2) U48_GG(x1, x2, x3) = U48_GG(x1, x2, x3) U49_GG(x1, x2, x3) = U49_GG(x1, x2, x3) U7_GGG(x1, x2, x3, x4, x5) = U7_GGG(x1, x2, x3, x4, x5) =_IN_GG(x1, x2) = =_IN_GG(x1, x2) U8_GGG(x1, x2, x3, x4, x5) = U8_GGG(x1, x2, x3, x4, x5) U9_GGG(x1, x2, x3, x4, x5, x6) = U9_GGG(x1, x2, x3, x4, x5, x6) U10_GGG(x1, x2, x3, x4, x5) = U10_GGG(x1, x2, x3, x4, x5) ISLESS_IN_GG(x1, x2) = ISLESS_IN_GG(x1, x2) U50_GG(x1, x2, x3) = U50_GG(x1, x2, x3) U51_GG(x1, x2, x3) = U51_GG(x1, x2, x3) U11_GGG(x1, x2, x3, x4, x5) = U11_GGG(x1, x2, x3, x4, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (52) DependencyGraphProof (EQUIVALENT) The approximation of the Dependency Graph [LOPSTR] contains 5 SCCs with 25 less nodes. ---------------------------------------- (53) Complex Obligation (AND) ---------------------------------------- (54) Obligation: Pi DP problem: The TRS P consists of the following rules: ISLESS_IN_GG(succ(X), succ(Y)) -> ISLESS_IN_GG(X, Y) ISLESS_IN_GG(pred(X), pred(Y)) -> ISLESS_IN_GG(X, Y) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x1, x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x1, x2, x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x1, x2, x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x1, x2, x4) U17_gga(x1, x2, x3, x4) = U17_gga(x1, x2, x4) U18_gga(x1, x2, x3, x4) = U18_gga(x1, x2, x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x1, x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1, x2) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x1, x2, x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x1, x2, x3, x4, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x1, x2, x3, x4, x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x1, x2, x3, x4, x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg(x1, x2) U48_gg(x1, x2, x3) = U48_gg(x1, x2, x3) U49_gg(x1, x2, x3) = U49_gg(x1, x2, x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x1, x2, x3, x4, x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg(x1, x2) U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x1, x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x1, x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x1, x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg(x1, x2) U50_gg(x1, x2, x3) = U50_gg(x1, x2, x3) U51_gg(x1, x2, x3) = U51_gg(x1, x2, x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x1, x2, x3, x4, x5) ISLESS_IN_GG(x1, x2) = ISLESS_IN_GG(x1, x2) We have to consider all (P,R,Pi)-chains ---------------------------------------- (55) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (56) Obligation: Pi DP problem: The TRS P consists of the following rules: ISLESS_IN_GG(succ(X), succ(Y)) -> ISLESS_IN_GG(X, Y) ISLESS_IN_GG(pred(X), pred(Y)) -> ISLESS_IN_GG(X, Y) R is empty. Pi is empty. We have to consider all (P,R,Pi)-chains ---------------------------------------- (57) PiDPToQDPProof (EQUIVALENT) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (58) Obligation: Q DP problem: The TRS P consists of the following rules: ISLESS_IN_GG(succ(X), succ(Y)) -> ISLESS_IN_GG(X, Y) ISLESS_IN_GG(pred(X), pred(Y)) -> ISLESS_IN_GG(X, Y) R is empty. Q is empty. We have to consider all (P,Q,R)-chains. ---------------------------------------- (59) 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: *ISLESS_IN_GG(succ(X), succ(Y)) -> ISLESS_IN_GG(X, Y) The graph contains the following edges 1 > 1, 2 > 2 *ISLESS_IN_GG(pred(X), pred(Y)) -> ISLESS_IN_GG(X, Y) The graph contains the following edges 1 > 1, 2 > 2 ---------------------------------------- (60) YES ---------------------------------------- (61) Obligation: Pi DP problem: The TRS P consists of the following rules: ISGREATER_IN_GG(pred(X), pred(Y)) -> ISGREATER_IN_GG(X, Y) ISGREATER_IN_GG(succ(X), succ(Y)) -> ISGREATER_IN_GG(X, Y) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x1, x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x1, x2, x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x1, x2, x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x1, x2, x4) U17_gga(x1, x2, x3, x4) = U17_gga(x1, x2, x4) U18_gga(x1, x2, x3, x4) = U18_gga(x1, x2, x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x1, x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1, x2) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x1, x2, x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x1, x2, x3, x4, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x1, x2, x3, x4, x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x1, x2, x3, x4, x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg(x1, x2) U48_gg(x1, x2, x3) = U48_gg(x1, x2, x3) U49_gg(x1, x2, x3) = U49_gg(x1, x2, x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x1, x2, x3, x4, x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg(x1, x2) U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x1, x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x1, x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x1, x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg(x1, x2) U50_gg(x1, x2, x3) = U50_gg(x1, x2, x3) U51_gg(x1, x2, x3) = U51_gg(x1, x2, x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x1, x2, x3, x4, x5) ISGREATER_IN_GG(x1, x2) = ISGREATER_IN_GG(x1, x2) We have to consider all (P,R,Pi)-chains ---------------------------------------- (62) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (63) Obligation: Pi DP problem: The TRS P consists of the following rules: ISGREATER_IN_GG(pred(X), pred(Y)) -> ISGREATER_IN_GG(X, Y) ISGREATER_IN_GG(succ(X), succ(Y)) -> ISGREATER_IN_GG(X, Y) R is empty. Pi is empty. We have to consider all (P,R,Pi)-chains ---------------------------------------- (64) PiDPToQDPProof (EQUIVALENT) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (65) Obligation: Q DP problem: The TRS P consists of the following rules: ISGREATER_IN_GG(pred(X), pred(Y)) -> ISGREATER_IN_GG(X, Y) ISGREATER_IN_GG(succ(X), succ(Y)) -> ISGREATER_IN_GG(X, Y) R is empty. Q is empty. We have to consider all (P,Q,R)-chains. ---------------------------------------- (66) 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: *ISGREATER_IN_GG(pred(X), pred(Y)) -> ISGREATER_IN_GG(X, Y) The graph contains the following edges 1 > 1, 2 > 2 *ISGREATER_IN_GG(succ(X), succ(Y)) -> ISGREATER_IN_GG(X, Y) The graph contains the following edges 1 > 1, 2 > 2 ---------------------------------------- (67) YES ---------------------------------------- (68) Obligation: Pi DP problem: The TRS P consists of the following rules: ISPLUS_IN_GGA(succ(X), pred(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(succ(X), succ(Y), succ(succ(Z))) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), succ(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), pred(Y), pred(pred(Z))) -> ISPLUS_IN_GGA(X, Y, Z) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x1, x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x1, x2, x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x1, x2, x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x1, x2, x4) U17_gga(x1, x2, x3, x4) = U17_gga(x1, x2, x4) U18_gga(x1, x2, x3, x4) = U18_gga(x1, x2, x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x1, x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1, x2) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x1, x2, x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x1, x2, x3, x4, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x1, x2, x3, x4, x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x1, x2, x3, x4, x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg(x1, x2) U48_gg(x1, x2, x3) = U48_gg(x1, x2, x3) U49_gg(x1, x2, x3) = U49_gg(x1, x2, x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x1, x2, x3, x4, x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg(x1, x2) U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x1, x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x1, x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x1, x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg(x1, x2) U50_gg(x1, x2, x3) = U50_gg(x1, x2, x3) U51_gg(x1, x2, x3) = U51_gg(x1, x2, x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x1, x2, x3, x4, x5) ISPLUS_IN_GGA(x1, x2, x3) = ISPLUS_IN_GGA(x1, x2) We have to consider all (P,R,Pi)-chains ---------------------------------------- (69) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (70) Obligation: Pi DP problem: The TRS P consists of the following rules: ISPLUS_IN_GGA(succ(X), pred(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(succ(X), succ(Y), succ(succ(Z))) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), succ(Y), Z) -> ISPLUS_IN_GGA(X, Y, Z) ISPLUS_IN_GGA(pred(X), pred(Y), pred(pred(Z))) -> ISPLUS_IN_GGA(X, Y, Z) R is empty. The argument filtering Pi contains the following mapping: succ(x1) = succ(x1) pred(x1) = pred(x1) ISPLUS_IN_GGA(x1, x2, x3) = ISPLUS_IN_GGA(x1, x2) We have to consider all (P,R,Pi)-chains ---------------------------------------- (71) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (72) Obligation: Q DP problem: The TRS P consists of the following rules: ISPLUS_IN_GGA(succ(X), pred(Y)) -> ISPLUS_IN_GGA(X, Y) ISPLUS_IN_GGA(succ(X), succ(Y)) -> ISPLUS_IN_GGA(X, Y) ISPLUS_IN_GGA(pred(X), succ(Y)) -> ISPLUS_IN_GGA(X, Y) ISPLUS_IN_GGA(pred(X), pred(Y)) -> ISPLUS_IN_GGA(X, Y) R is empty. Q is empty. We have to consider all (P,Q,R)-chains. ---------------------------------------- (73) 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: *ISPLUS_IN_GGA(succ(X), pred(Y)) -> ISPLUS_IN_GGA(X, Y) The graph contains the following edges 1 > 1, 2 > 2 *ISPLUS_IN_GGA(succ(X), succ(Y)) -> ISPLUS_IN_GGA(X, Y) The graph contains the following edges 1 > 1, 2 > 2 *ISPLUS_IN_GGA(pred(X), succ(Y)) -> ISPLUS_IN_GGA(X, Y) The graph contains the following edges 1 > 1, 2 > 2 *ISPLUS_IN_GGA(pred(X), pred(Y)) -> ISPLUS_IN_GGA(X, Y) The graph contains the following edges 1 > 1, 2 > 2 ---------------------------------------- (74) YES ---------------------------------------- (75) Obligation: Pi DP problem: The TRS P consists of the following rules: U12_GA(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_GA(X, Xs, Y, Ys, =_in_ag(Y, U)) U13_GA(X, Xs, Y, Ys, =_out_ag(Y, U)) -> ADDONE_IN_GA(Xs, Ys) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U12_GA(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x1, x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x1, x2, x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x1, x2, x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x1, x2, x4) U17_gga(x1, x2, x3, x4) = U17_gga(x1, x2, x4) U18_gga(x1, x2, x3, x4) = U18_gga(x1, x2, x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x1, x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1, x2) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x1, x2, x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x1, x2, x3, x4, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x1, x2, x3, x4, x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x1, x2, x3, x4, x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg(x1, x2) U48_gg(x1, x2, x3) = U48_gg(x1, x2, x3) U49_gg(x1, x2, x3) = U49_gg(x1, x2, x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x1, x2, x3, x4, x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg(x1, x2) U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x1, x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x1, x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x1, x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg(x1, x2) U50_gg(x1, x2, x3) = U50_gg(x1, x2, x3) U51_gg(x1, x2, x3) = U51_gg(x1, x2, x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x1, x2, x3, x4, x5) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U12_GA(x1, x2, x3, x4, x5) = U12_GA(x1, x2, x5) U13_GA(x1, x2, x3, x4, x5) = U13_GA(x1, x2, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (76) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (77) Obligation: Pi DP problem: The TRS P consists of the following rules: U12_GA(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_GA(X, Xs, Y, Ys, =_in_ag(Y, U)) U13_GA(X, Xs, Y, Ys, =_out_ag(Y, U)) -> ADDONE_IN_GA(Xs, Ys) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U12_GA(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) The TRS R consists of the following rules: =_in_ag(X, X) -> =_out_ag(X, X) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) The argument filtering Pi contains the following mapping: .(x1, x2) = .(x1, x2) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x1, x2, x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x1, x2, x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x1, x2, x4) U17_gga(x1, x2, x3, x4) = U17_gga(x1, x2, x4) U18_gga(x1, x2, x3, x4) = U18_gga(x1, x2, x4) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1, x2) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U12_GA(x1, x2, x3, x4, x5) = U12_GA(x1, x2, x5) U13_GA(x1, x2, x3, x4, x5) = U13_GA(x1, x2, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (78) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (79) Obligation: Q DP problem: The TRS P consists of the following rules: U12_GA(X, Xs, isPlus_out_gga(X, succ(zero), U)) -> U13_GA(X, Xs, =_in_ag(U)) U13_GA(X, Xs, =_out_ag(Y, U)) -> ADDONE_IN_GA(Xs) ADDONE_IN_GA(.(X, Xs)) -> U12_GA(X, Xs, isPlus_in_gga(X, succ(zero))) The TRS R consists of the following rules: =_in_ag(X) -> =_out_ag(X, X) isPlus_in_gga(zero, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), succ(Y)) -> U15_gga(X, Y, isPlus_in_gga(X, Y)) isPlus_in_gga(pred(X), succ(Y)) -> U17_gga(X, Y, isPlus_in_gga(X, Y)) U15_gga(X, Y, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U17_gga(X, Y, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) isPlus_in_gga(succ(X), zero) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), pred(Y)) -> U16_gga(X, Y, isPlus_in_gga(X, Y)) isPlus_in_gga(pred(X), zero) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), pred(Y)) -> U18_gga(X, Y, isPlus_in_gga(X, Y)) U16_gga(X, Y, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U18_gga(X, Y, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) The set Q consists of the following terms: =_in_ag(x0) isPlus_in_gga(x0, x1) U15_gga(x0, x1, x2) U17_gga(x0, x1, x2) U16_gga(x0, x1, x2) U18_gga(x0, x1, x2) We have to consider all (P,Q,R)-chains. ---------------------------------------- (80) 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: *U13_GA(X, Xs, =_out_ag(Y, U)) -> ADDONE_IN_GA(Xs) The graph contains the following edges 2 >= 1 *ADDONE_IN_GA(.(X, Xs)) -> U12_GA(X, Xs, isPlus_in_gga(X, succ(zero))) The graph contains the following edges 1 > 1, 1 > 2 *U12_GA(X, Xs, isPlus_out_gga(X, succ(zero), U)) -> U13_GA(X, Xs, =_in_ag(U)) The graph contains the following edges 1 >= 1, 3 > 1, 2 >= 2 ---------------------------------------- (81) YES ---------------------------------------- (82) Obligation: Pi DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U8_GGG(X, Xs, Val, Start, =_in_ag(X1, X)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_GGG(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_GGG(X, Xs, Val, Start, isLess_in_gg(X1, X2)) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) =_in_ag(X, X) -> =_out_ag(X, X) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, =_in_ag(X1, X)) U4_ggg(X, X2, Val, X3, =_out_ag(X1, X)) -> U5_ggg(X, X2, Val, X3, X1, =_in_ag(X4, Val)) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U6_ggg(X, X2, Val, X3, isGreater_in_gg(X1, X4)) isGreater_in_gg(succ(X), zero) -> isGreater_out_gg(succ(X), zero) isGreater_in_gg(succ(X), pred(Y)) -> isGreater_out_gg(succ(X), pred(Y)) isGreater_in_gg(succ(X), succ(Y)) -> U48_gg(X, Y, isGreater_in_gg(X, Y)) isGreater_in_gg(zero, pred(Y)) -> isGreater_out_gg(zero, pred(Y)) isGreater_in_gg(pred(X), pred(Y)) -> U49_gg(X, Y, isGreater_in_gg(X, Y)) U49_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(pred(X), pred(Y)) U48_gg(X, Y, isGreater_out_gg(X, Y)) -> isGreater_out_gg(succ(X), succ(Y)) U6_ggg(X, X2, Val, X3, isGreater_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) U5_ggg(X, X2, Val, X3, X1, =_out_ag(X4, Val)) -> U7_ggg(X, X2, Val, X3, =_in_gg(X1, X4)) =_in_gg(X, X) -> =_out_gg(X, X) U7_ggg(X, X2, Val, X3, =_out_gg(X1, X4)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U8_ggg(X, Xs, Val, Start, =_in_ag(X1, X)) U8_ggg(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_ggg(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_ggg(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_ggg(X, Xs, Val, Start, isLess_in_gg(X1, X2)) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U10_ggg(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> U11_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U11_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x1, x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x1, x2, x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x1, x2, x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x1, x2, x4) U17_gga(x1, x2, x3, x4) = U17_gga(x1, x2, x4) U18_gga(x1, x2, x3, x4) = U18_gga(x1, x2, x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x1, x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1, x2) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x1, x2, x3, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x1, x2, x3, x4, x5) U5_ggg(x1, x2, x3, x4, x5, x6) = U5_ggg(x1, x2, x3, x4, x5, x6) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x1, x2, x3, x4, x5) isGreater_in_gg(x1, x2) = isGreater_in_gg(x1, x2) isGreater_out_gg(x1, x2) = isGreater_out_gg(x1, x2) U48_gg(x1, x2, x3) = U48_gg(x1, x2, x3) U49_gg(x1, x2, x3) = U49_gg(x1, x2, x3) U7_ggg(x1, x2, x3, x4, x5) = U7_ggg(x1, x2, x3, x4, x5) =_in_gg(x1, x2) = =_in_gg(x1, x2) =_out_gg(x1, x2) = =_out_gg(x1, x2) U8_ggg(x1, x2, x3, x4, x5) = U8_ggg(x1, x2, x3, x4, x5) U9_ggg(x1, x2, x3, x4, x5, x6) = U9_ggg(x1, x2, x3, x4, x5, x6) U10_ggg(x1, x2, x3, x4, x5) = U10_ggg(x1, x2, x3, x4, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg(x1, x2) U50_gg(x1, x2, x3) = U50_gg(x1, x2, x3) U51_gg(x1, x2, x3) = U51_gg(x1, x2, x3) U11_ggg(x1, x2, x3, x4, x5) = U11_ggg(x1, x2, x3, x4, x5) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x2, x3) U8_GGG(x1, x2, x3, x4, x5) = U8_GGG(x1, x2, x3, x4, x5) U9_GGG(x1, x2, x3, x4, x5, x6) = U9_GGG(x1, x2, x3, x4, x5, x6) U10_GGG(x1, x2, x3, x4, x5) = U10_GGG(x1, x2, x3, x4, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (83) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (84) Obligation: Pi DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U8_GGG(X, Xs, Val, Start, =_in_ag(X1, X)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_GGG(X, Xs, Val, Start, X1, =_in_ag(X2, Val)) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_GGG(X, Xs, Val, Start, isLess_in_gg(X1, X2)) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U12_ga(X, Xs, Y, Ys, isPlus_in_gga(X, succ(zero), U)) =_in_ag(X, X) -> =_out_ag(X, X) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U12_ga(X, Xs, Y, Ys, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, Y, Ys, =_in_ag(Y, U)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) isPlus_in_gga(zero, X, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), succ(Y), succ(succ(Z))) -> U15_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), succ(Y), Z) -> U17_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U13_ga(X, Xs, Y, Ys, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U15_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U17_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U14_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) isPlus_in_gga(succ(X), zero, succ(X)) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), pred(Y), Z) -> U16_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) isPlus_in_gga(pred(X), zero, pred(X)) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), pred(Y), pred(pred(Z))) -> U18_gga(X, Y, Z, isPlus_in_gga(X, Y, Z)) U16_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U18_gga(X, Y, Z, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) The argument filtering Pi contains the following mapping: [] = [] addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x1, x2) U12_ga(x1, x2, x3, x4, x5) = U12_ga(x1, x2, x5) isPlus_in_gga(x1, x2, x3) = isPlus_in_gga(x1, x2) zero = zero isPlus_out_gga(x1, x2, x3) = isPlus_out_gga(x1, x2, x3) succ(x1) = succ(x1) U15_gga(x1, x2, x3, x4) = U15_gga(x1, x2, x4) pred(x1) = pred(x1) U16_gga(x1, x2, x3, x4) = U16_gga(x1, x2, x4) U17_gga(x1, x2, x3, x4) = U17_gga(x1, x2, x4) U18_gga(x1, x2, x3, x4) = U18_gga(x1, x2, x4) U13_ga(x1, x2, x3, x4, x5) = U13_ga(x1, x2, x5) =_in_ag(x1, x2) = =_in_ag(x2) =_out_ag(x1, x2) = =_out_ag(x1, x2) U14_ga(x1, x2, x3, x4, x5) = U14_ga(x1, x2, x3, x5) isLess_in_gg(x1, x2) = isLess_in_gg(x1, x2) isLess_out_gg(x1, x2) = isLess_out_gg(x1, x2) U50_gg(x1, x2, x3) = U50_gg(x1, x2, x3) U51_gg(x1, x2, x3) = U51_gg(x1, x2, x3) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x2, x3) U8_GGG(x1, x2, x3, x4, x5) = U8_GGG(x1, x2, x3, x4, x5) U9_GGG(x1, x2, x3, x4, x5, x6) = U9_GGG(x1, x2, x3, x4, x5, x6) U10_GGG(x1, x2, x3, x4, x5) = U10_GGG(x1, x2, x3, x4, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (85) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (86) Obligation: Q DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U8_GGG(X, Xs, Val, Start, =_in_ag(X)) U8_GGG(X, Xs, Val, Start, =_out_ag(X1, X)) -> U9_GGG(X, Xs, Val, Start, X1, =_in_ag(Val)) U9_GGG(X, Xs, Val, Start, X1, =_out_ag(X2, Val)) -> U10_GGG(X, Xs, Val, Start, isLess_in_gg(X1, X2)) U10_GGG(X, Xs, Val, Start, isLess_out_gg(X1, X2)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: addOne_in_ga([]) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs)) -> U12_ga(X, Xs, isPlus_in_gga(X, succ(zero))) =_in_ag(X) -> =_out_ag(X, X) isLess_in_gg(pred(X), zero) -> isLess_out_gg(pred(X), zero) isLess_in_gg(pred(X), succ(Y)) -> isLess_out_gg(pred(X), succ(Y)) isLess_in_gg(pred(X), pred(Y)) -> U50_gg(X, Y, isLess_in_gg(X, Y)) isLess_in_gg(zero, succ(Y)) -> isLess_out_gg(zero, succ(Y)) isLess_in_gg(succ(X), succ(Y)) -> U51_gg(X, Y, isLess_in_gg(X, Y)) U12_ga(X, Xs, isPlus_out_gga(X, succ(zero), U)) -> U13_ga(X, Xs, =_in_ag(U)) U50_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(pred(X), pred(Y)) U51_gg(X, Y, isLess_out_gg(X, Y)) -> isLess_out_gg(succ(X), succ(Y)) isPlus_in_gga(zero, X) -> isPlus_out_gga(zero, X, X) isPlus_in_gga(succ(X), succ(Y)) -> U15_gga(X, Y, isPlus_in_gga(X, Y)) isPlus_in_gga(pred(X), succ(Y)) -> U17_gga(X, Y, isPlus_in_gga(X, Y)) U13_ga(X, Xs, =_out_ag(Y, U)) -> U14_ga(X, Xs, Y, addOne_in_ga(Xs)) U15_gga(X, Y, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), succ(Y), succ(succ(Z))) U17_gga(X, Y, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), succ(Y), Z) U14_ga(X, Xs, Y, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) isPlus_in_gga(succ(X), zero) -> isPlus_out_gga(succ(X), zero, succ(X)) isPlus_in_gga(succ(X), pred(Y)) -> U16_gga(X, Y, isPlus_in_gga(X, Y)) isPlus_in_gga(pred(X), zero) -> isPlus_out_gga(pred(X), zero, pred(X)) isPlus_in_gga(pred(X), pred(Y)) -> U18_gga(X, Y, isPlus_in_gga(X, Y)) U16_gga(X, Y, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(succ(X), pred(Y), Z) U18_gga(X, Y, isPlus_out_gga(X, Y, Z)) -> isPlus_out_gga(pred(X), pred(Y), pred(pred(Z))) The set Q consists of the following terms: addOne_in_ga(x0) =_in_ag(x0) isLess_in_gg(x0, x1) U12_ga(x0, x1, x2) U50_gg(x0, x1, x2) U51_gg(x0, x1, x2) isPlus_in_gga(x0, x1) U13_ga(x0, x1, x2) U15_gga(x0, x1, x2) U17_gga(x0, x1, x2) U14_ga(x0, x1, x2, x3) U16_gga(x0, x1, x2) U18_gga(x0, x1, x2) We have to consider all (P,Q,R)-chains. ---------------------------------------- (87) CutEliminatorProof (SOUND) Eliminated all cuts by simply ignoring them[PROLOG]. ---------------------------------------- (88) Obligation: Clauses: find([], X1). find(Vec, Val) :- find(Vec, Val, Vec). find([], Val, Start) :- ','(addOne(Start, StartPlusOne), find(StartPlusOne, Val)). find(.(X, X2), Val, X3) :- >=(X, Val). find(.(X, Xs), Val, Start) :- ','(<(X, Val), find(Xs, Val, Start)). addOne([], []). addOne(.(X, Xs), .(Y, Ys)) :- ','(is(Y, +(X, 1)), addOne(Xs, Ys)). Query: find(g,g) ---------------------------------------- (89) UndefinedPredicateHandlerProof (SOUND) Added facts for all undefined predicates [PROLOG]. ---------------------------------------- (90) Obligation: Clauses: find([], X1). find(Vec, Val) :- find(Vec, Val, Vec). find([], Val, Start) :- ','(addOne(Start, StartPlusOne), find(StartPlusOne, Val)). find(.(X, X2), Val, X3) :- >=(X, Val). find(.(X, Xs), Val, Start) :- ','(<(X, Val), find(Xs, Val, Start)). addOne([], []). addOne(.(X, Xs), .(Y, Ys)) :- ','(is(Y, +(X, 1)), addOne(Xs, Ys)). >=(X0, X1). <(X0, X1). is(X0, X1). Query: find(g,g) ---------------------------------------- (91) PrologToPiTRSProof (SOUND) We use the technique of [TOCL09]. With regard to the inferred argument filtering the predicates were used in the following modes: find_in_2: (b,b) find_in_3: (b,b,b) addOne_in_2: (b,f) Transforming Prolog into the following Term Rewriting System: Pi-finite rewrite system: The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, >=_in_ag(X, Val)) >=_in_ag(X0, X1) -> >=_out_ag(X0, X1) U4_ggg(X, X2, Val, X3, >=_out_ag(X, Val)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U5_ggg(X, Xs, Val, Start, <_in_ag(X, Val)) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U5_ggg(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U6_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x5) >=_in_ag(x1, x2) = >=_in_ag(x2) >=_out_ag(x1, x2) = >=_out_ag U5_ggg(x1, x2, x3, x4, x5) = U5_ggg(x2, x3, x4, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog ---------------------------------------- (92) Obligation: Pi-finite rewrite system: The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, >=_in_ag(X, Val)) >=_in_ag(X0, X1) -> >=_out_ag(X0, X1) U4_ggg(X, X2, Val, X3, >=_out_ag(X, Val)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U5_ggg(X, Xs, Val, Start, <_in_ag(X, Val)) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U5_ggg(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U6_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x5) >=_in_ag(x1, x2) = >=_in_ag(x2) >=_out_ag(x1, x2) = >=_out_ag U5_ggg(x1, x2, x3, x4, x5) = U5_ggg(x2, x3, x4, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) ---------------------------------------- (93) 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: FIND_IN_GG(Vec, Val) -> U1_GG(Vec, Val, find_in_ggg(Vec, Val, Vec)) FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) FIND_IN_GGG([], Val, Start) -> ADDONE_IN_GA(Start, StartPlusOne) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U7_GA(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> IS_IN_AG(Y, +(X, 1)) U7_GA(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_GA(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U7_GA(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> ADDONE_IN_GA(Xs, Ys) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_GGG(Val, Start, find_in_gg(StartPlusOne, Val)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, X2), Val, X3) -> U4_GGG(X, X2, Val, X3, >=_in_ag(X, Val)) FIND_IN_GGG(.(X, X2), Val, X3) -> >=_IN_AG(X, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U5_GGG(X, Xs, Val, Start, <_in_ag(X, Val)) FIND_IN_GGG(.(X, Xs), Val, Start) -> <_IN_AG(X, Val) U5_GGG(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_GGG(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U5_GGG(X, Xs, Val, Start, <_out_ag(X, Val)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, >=_in_ag(X, Val)) >=_in_ag(X0, X1) -> >=_out_ag(X0, X1) U4_ggg(X, X2, Val, X3, >=_out_ag(X, Val)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U5_ggg(X, Xs, Val, Start, <_in_ag(X, Val)) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U5_ggg(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U6_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x5) >=_in_ag(x1, x2) = >=_in_ag(x2) >=_out_ag(x1, x2) = >=_out_ag U5_ggg(x1, x2, x3, x4, x5) = U5_ggg(x2, x3, x4, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) U1_GG(x1, x2, x3) = U1_GG(x3) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x3) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U7_GA(x1, x2, x3, x4, x5) = U7_GA(x2, x5) IS_IN_AG(x1, x2) = IS_IN_AG(x2) U8_GA(x1, x2, x3, x4, x5) = U8_GA(x5) U3_GGG(x1, x2, x3) = U3_GGG(x3) U4_GGG(x1, x2, x3, x4, x5) = U4_GGG(x5) >=_IN_AG(x1, x2) = >=_IN_AG(x2) U5_GGG(x1, x2, x3, x4, x5) = U5_GGG(x2, x3, x4, x5) <_IN_AG(x1, x2) = <_IN_AG(x2) U6_GGG(x1, x2, x3, x4, x5) = U6_GGG(x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (94) Obligation: Pi DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> U1_GG(Vec, Val, find_in_ggg(Vec, Val, Vec)) FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) FIND_IN_GGG([], Val, Start) -> ADDONE_IN_GA(Start, StartPlusOne) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U7_GA(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> IS_IN_AG(Y, +(X, 1)) U7_GA(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_GA(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U7_GA(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> ADDONE_IN_GA(Xs, Ys) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_GGG(Val, Start, find_in_gg(StartPlusOne, Val)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, X2), Val, X3) -> U4_GGG(X, X2, Val, X3, >=_in_ag(X, Val)) FIND_IN_GGG(.(X, X2), Val, X3) -> >=_IN_AG(X, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U5_GGG(X, Xs, Val, Start, <_in_ag(X, Val)) FIND_IN_GGG(.(X, Xs), Val, Start) -> <_IN_AG(X, Val) U5_GGG(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_GGG(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U5_GGG(X, Xs, Val, Start, <_out_ag(X, Val)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, >=_in_ag(X, Val)) >=_in_ag(X0, X1) -> >=_out_ag(X0, X1) U4_ggg(X, X2, Val, X3, >=_out_ag(X, Val)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U5_ggg(X, Xs, Val, Start, <_in_ag(X, Val)) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U5_ggg(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U6_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x5) >=_in_ag(x1, x2) = >=_in_ag(x2) >=_out_ag(x1, x2) = >=_out_ag U5_ggg(x1, x2, x3, x4, x5) = U5_ggg(x2, x3, x4, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) U1_GG(x1, x2, x3) = U1_GG(x3) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x3) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U7_GA(x1, x2, x3, x4, x5) = U7_GA(x2, x5) IS_IN_AG(x1, x2) = IS_IN_AG(x2) U8_GA(x1, x2, x3, x4, x5) = U8_GA(x5) U3_GGG(x1, x2, x3) = U3_GGG(x3) U4_GGG(x1, x2, x3, x4, x5) = U4_GGG(x5) >=_IN_AG(x1, x2) = >=_IN_AG(x2) U5_GGG(x1, x2, x3, x4, x5) = U5_GGG(x2, x3, x4, x5) <_IN_AG(x1, x2) = <_IN_AG(x2) U6_GGG(x1, x2, x3, x4, x5) = U6_GGG(x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (95) DependencyGraphProof (EQUIVALENT) The approximation of the Dependency Graph [LOPSTR] contains 2 SCCs with 9 less nodes. ---------------------------------------- (96) Complex Obligation (AND) ---------------------------------------- (97) Obligation: Pi DP problem: The TRS P consists of the following rules: U7_GA(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> ADDONE_IN_GA(Xs, Ys) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U7_GA(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, >=_in_ag(X, Val)) >=_in_ag(X0, X1) -> >=_out_ag(X0, X1) U4_ggg(X, X2, Val, X3, >=_out_ag(X, Val)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U5_ggg(X, Xs, Val, Start, <_in_ag(X, Val)) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U5_ggg(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U6_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x5) >=_in_ag(x1, x2) = >=_in_ag(x2) >=_out_ag(x1, x2) = >=_out_ag U5_ggg(x1, x2, x3, x4, x5) = U5_ggg(x2, x3, x4, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U7_GA(x1, x2, x3, x4, x5) = U7_GA(x2, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (98) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (99) Obligation: Pi DP problem: The TRS P consists of the following rules: U7_GA(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> ADDONE_IN_GA(Xs, Ys) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U7_GA(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) The TRS R consists of the following rules: is_in_ag(X0, X1) -> is_out_ag(X0, X1) The argument filtering Pi contains the following mapping: .(x1, x2) = .(x2) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag +(x1, x2) = +(x2) 1 = 1 ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U7_GA(x1, x2, x3, x4, x5) = U7_GA(x2, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (100) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (101) Obligation: Q DP problem: The TRS P consists of the following rules: U7_GA(Xs, is_out_ag) -> ADDONE_IN_GA(Xs) ADDONE_IN_GA(.(Xs)) -> U7_GA(Xs, is_in_ag(+(1))) The TRS R consists of the following rules: is_in_ag(X1) -> is_out_ag The set Q consists of the following terms: is_in_ag(x0) We have to consider all (P,Q,R)-chains. ---------------------------------------- (102) 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: *ADDONE_IN_GA(.(Xs)) -> U7_GA(Xs, is_in_ag(+(1))) The graph contains the following edges 1 > 1 *U7_GA(Xs, is_out_ag) -> ADDONE_IN_GA(Xs) The graph contains the following edges 1 >= 1 ---------------------------------------- (103) YES ---------------------------------------- (104) Obligation: Pi DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U5_GGG(X, Xs, Val, Start, <_in_ag(X, Val)) U5_GGG(X, Xs, Val, Start, <_out_ag(X, Val)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, >=_in_ag(X, Val)) >=_in_ag(X0, X1) -> >=_out_ag(X0, X1) U4_ggg(X, X2, Val, X3, >=_out_ag(X, Val)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U5_ggg(X, Xs, Val, Start, <_in_ag(X, Val)) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U5_ggg(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U6_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg U1_gg(x1, x2, x3) = U1_gg(x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x5) U3_ggg(x1, x2, x3) = U3_ggg(x3) find_out_ggg(x1, x2, x3) = find_out_ggg U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x5) >=_in_ag(x1, x2) = >=_in_ag(x2) >=_out_ag(x1, x2) = >=_out_ag U5_ggg(x1, x2, x3, x4, x5) = U5_ggg(x2, x3, x4, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x5) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x3) U5_GGG(x1, x2, x3, x4, x5) = U5_GGG(x2, x3, x4, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (105) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (106) Obligation: Pi DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U5_GGG(X, Xs, Val, Start, <_in_ag(X, Val)) U5_GGG(X, Xs, Val, Start, <_out_ag(X, Val)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) The argument filtering Pi contains the following mapping: [] = [] addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x3) U5_GGG(x1, x2, x3, x4, x5) = U5_GGG(x2, x3, x4, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (107) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (108) Obligation: Q DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, addOne_in_ga(Start)) U2_GGG(Val, addOne_out_ga(StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(Xs), Val, Start) -> U5_GGG(Xs, Val, Start, <_in_ag(Val)) U5_GGG(Xs, Val, Start, <_out_ag) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: addOne_in_ga([]) -> addOne_out_ga([]) addOne_in_ga(.(Xs)) -> U7_ga(Xs, is_in_ag(+(1))) <_in_ag(X1) -> <_out_ag U7_ga(Xs, is_out_ag) -> U8_ga(addOne_in_ga(Xs)) is_in_ag(X1) -> is_out_ag U8_ga(addOne_out_ga(Ys)) -> addOne_out_ga(.(Ys)) The set Q consists of the following terms: addOne_in_ga(x0) <_in_ag(x0) U7_ga(x0, x1) is_in_ag(x0) U8_ga(x0) We have to consider all (P,Q,R)-chains. ---------------------------------------- (109) PrologToPiTRSProof (SOUND) We use the technique of [TOCL09]. With regard to the inferred argument filtering the predicates were used in the following modes: find_in_2: (b,b) find_in_3: (b,b,b) addOne_in_2: (b,f) Transforming Prolog into the following Term Rewriting System: Pi-finite rewrite system: The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, >=_in_ag(X, Val)) >=_in_ag(X0, X1) -> >=_out_ag(X0, X1) U4_ggg(X, X2, Val, X3, >=_out_ag(X, Val)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U5_ggg(X, Xs, Val, Start, <_in_ag(X, Val)) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U5_ggg(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U6_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag(x2) +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x2, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x2, x3, x4, x5) >=_in_ag(x1, x2) = >=_in_ag(x2) >=_out_ag(x1, x2) = >=_out_ag(x2) U5_ggg(x1, x2, x3, x4, x5) = U5_ggg(x2, x3, x4, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag(x2) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x2, x3, x4, x5) Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog ---------------------------------------- (110) Obligation: Pi-finite rewrite system: The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, >=_in_ag(X, Val)) >=_in_ag(X0, X1) -> >=_out_ag(X0, X1) U4_ggg(X, X2, Val, X3, >=_out_ag(X, Val)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U5_ggg(X, Xs, Val, Start, <_in_ag(X, Val)) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U5_ggg(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U6_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag(x2) +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x2, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x2, x3, x4, x5) >=_in_ag(x1, x2) = >=_in_ag(x2) >=_out_ag(x1, x2) = >=_out_ag(x2) U5_ggg(x1, x2, x3, x4, x5) = U5_ggg(x2, x3, x4, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag(x2) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x2, x3, x4, x5) ---------------------------------------- (111) 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: FIND_IN_GG(Vec, Val) -> U1_GG(Vec, Val, find_in_ggg(Vec, Val, Vec)) FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) FIND_IN_GGG([], Val, Start) -> ADDONE_IN_GA(Start, StartPlusOne) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U7_GA(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> IS_IN_AG(Y, +(X, 1)) U7_GA(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_GA(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U7_GA(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> ADDONE_IN_GA(Xs, Ys) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_GGG(Val, Start, find_in_gg(StartPlusOne, Val)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, X2), Val, X3) -> U4_GGG(X, X2, Val, X3, >=_in_ag(X, Val)) FIND_IN_GGG(.(X, X2), Val, X3) -> >=_IN_AG(X, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U5_GGG(X, Xs, Val, Start, <_in_ag(X, Val)) FIND_IN_GGG(.(X, Xs), Val, Start) -> <_IN_AG(X, Val) U5_GGG(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_GGG(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U5_GGG(X, Xs, Val, Start, <_out_ag(X, Val)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, >=_in_ag(X, Val)) >=_in_ag(X0, X1) -> >=_out_ag(X0, X1) U4_ggg(X, X2, Val, X3, >=_out_ag(X, Val)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U5_ggg(X, Xs, Val, Start, <_in_ag(X, Val)) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U5_ggg(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U6_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag(x2) +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x2, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x2, x3, x4, x5) >=_in_ag(x1, x2) = >=_in_ag(x2) >=_out_ag(x1, x2) = >=_out_ag(x2) U5_ggg(x1, x2, x3, x4, x5) = U5_ggg(x2, x3, x4, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag(x2) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x2, x3, x4, x5) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) U1_GG(x1, x2, x3) = U1_GG(x1, x2, x3) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x2, x3) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U7_GA(x1, x2, x3, x4, x5) = U7_GA(x2, x5) IS_IN_AG(x1, x2) = IS_IN_AG(x2) U8_GA(x1, x2, x3, x4, x5) = U8_GA(x2, x5) U3_GGG(x1, x2, x3) = U3_GGG(x1, x2, x3) U4_GGG(x1, x2, x3, x4, x5) = U4_GGG(x2, x3, x4, x5) >=_IN_AG(x1, x2) = >=_IN_AG(x2) U5_GGG(x1, x2, x3, x4, x5) = U5_GGG(x2, x3, x4, x5) <_IN_AG(x1, x2) = <_IN_AG(x2) U6_GGG(x1, x2, x3, x4, x5) = U6_GGG(x2, x3, x4, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (112) Obligation: Pi DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> U1_GG(Vec, Val, find_in_ggg(Vec, Val, Vec)) FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) FIND_IN_GGG([], Val, Start) -> ADDONE_IN_GA(Start, StartPlusOne) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U7_GA(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> IS_IN_AG(Y, +(X, 1)) U7_GA(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_GA(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U7_GA(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> ADDONE_IN_GA(Xs, Ys) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_GGG(Val, Start, find_in_gg(StartPlusOne, Val)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, X2), Val, X3) -> U4_GGG(X, X2, Val, X3, >=_in_ag(X, Val)) FIND_IN_GGG(.(X, X2), Val, X3) -> >=_IN_AG(X, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U5_GGG(X, Xs, Val, Start, <_in_ag(X, Val)) FIND_IN_GGG(.(X, Xs), Val, Start) -> <_IN_AG(X, Val) U5_GGG(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_GGG(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U5_GGG(X, Xs, Val, Start, <_out_ag(X, Val)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, >=_in_ag(X, Val)) >=_in_ag(X0, X1) -> >=_out_ag(X0, X1) U4_ggg(X, X2, Val, X3, >=_out_ag(X, Val)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U5_ggg(X, Xs, Val, Start, <_in_ag(X, Val)) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U5_ggg(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U6_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag(x2) +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x2, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x2, x3, x4, x5) >=_in_ag(x1, x2) = >=_in_ag(x2) >=_out_ag(x1, x2) = >=_out_ag(x2) U5_ggg(x1, x2, x3, x4, x5) = U5_ggg(x2, x3, x4, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag(x2) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x2, x3, x4, x5) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) U1_GG(x1, x2, x3) = U1_GG(x1, x2, x3) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x2, x3) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U7_GA(x1, x2, x3, x4, x5) = U7_GA(x2, x5) IS_IN_AG(x1, x2) = IS_IN_AG(x2) U8_GA(x1, x2, x3, x4, x5) = U8_GA(x2, x5) U3_GGG(x1, x2, x3) = U3_GGG(x1, x2, x3) U4_GGG(x1, x2, x3, x4, x5) = U4_GGG(x2, x3, x4, x5) >=_IN_AG(x1, x2) = >=_IN_AG(x2) U5_GGG(x1, x2, x3, x4, x5) = U5_GGG(x2, x3, x4, x5) <_IN_AG(x1, x2) = <_IN_AG(x2) U6_GGG(x1, x2, x3, x4, x5) = U6_GGG(x2, x3, x4, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (113) DependencyGraphProof (EQUIVALENT) The approximation of the Dependency Graph [LOPSTR] contains 2 SCCs with 9 less nodes. ---------------------------------------- (114) Complex Obligation (AND) ---------------------------------------- (115) Obligation: Pi DP problem: The TRS P consists of the following rules: U7_GA(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> ADDONE_IN_GA(Xs, Ys) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U7_GA(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, >=_in_ag(X, Val)) >=_in_ag(X0, X1) -> >=_out_ag(X0, X1) U4_ggg(X, X2, Val, X3, >=_out_ag(X, Val)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U5_ggg(X, Xs, Val, Start, <_in_ag(X, Val)) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U5_ggg(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U6_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag(x2) +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x2, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x2, x3, x4, x5) >=_in_ag(x1, x2) = >=_in_ag(x2) >=_out_ag(x1, x2) = >=_out_ag(x2) U5_ggg(x1, x2, x3, x4, x5) = U5_ggg(x2, x3, x4, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag(x2) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x2, x3, x4, x5) ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U7_GA(x1, x2, x3, x4, x5) = U7_GA(x2, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (116) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (117) Obligation: Pi DP problem: The TRS P consists of the following rules: U7_GA(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> ADDONE_IN_GA(Xs, Ys) ADDONE_IN_GA(.(X, Xs), .(Y, Ys)) -> U7_GA(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) The TRS R consists of the following rules: is_in_ag(X0, X1) -> is_out_ag(X0, X1) The argument filtering Pi contains the following mapping: .(x1, x2) = .(x2) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag(x2) +(x1, x2) = +(x2) 1 = 1 ADDONE_IN_GA(x1, x2) = ADDONE_IN_GA(x1) U7_GA(x1, x2, x3, x4, x5) = U7_GA(x2, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (118) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (119) Obligation: Q DP problem: The TRS P consists of the following rules: U7_GA(Xs, is_out_ag(+(1))) -> ADDONE_IN_GA(Xs) ADDONE_IN_GA(.(Xs)) -> U7_GA(Xs, is_in_ag(+(1))) The TRS R consists of the following rules: is_in_ag(X1) -> is_out_ag(X1) The set Q consists of the following terms: is_in_ag(x0) We have to consider all (P,Q,R)-chains. ---------------------------------------- (120) 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: *ADDONE_IN_GA(.(Xs)) -> U7_GA(Xs, is_in_ag(+(1))) The graph contains the following edges 1 > 1 *U7_GA(Xs, is_out_ag(+(1))) -> ADDONE_IN_GA(Xs) The graph contains the following edges 1 >= 1 ---------------------------------------- (121) YES ---------------------------------------- (122) Obligation: Pi DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U5_GGG(X, Xs, Val, Start, <_in_ag(X, Val)) U5_GGG(X, Xs, Val, Start, <_out_ag(X, Val)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: find_in_gg([], X1) -> find_out_gg([], X1) find_in_gg(Vec, Val) -> U1_gg(Vec, Val, find_in_ggg(Vec, Val, Vec)) find_in_ggg([], Val, Start) -> U2_ggg(Val, Start, addOne_in_ga(Start, StartPlusOne)) addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) U2_ggg(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> U3_ggg(Val, Start, find_in_gg(StartPlusOne, Val)) U3_ggg(Val, Start, find_out_gg(StartPlusOne, Val)) -> find_out_ggg([], Val, Start) find_in_ggg(.(X, X2), Val, X3) -> U4_ggg(X, X2, Val, X3, >=_in_ag(X, Val)) >=_in_ag(X0, X1) -> >=_out_ag(X0, X1) U4_ggg(X, X2, Val, X3, >=_out_ag(X, Val)) -> find_out_ggg(.(X, X2), Val, X3) find_in_ggg(.(X, Xs), Val, Start) -> U5_ggg(X, Xs, Val, Start, <_in_ag(X, Val)) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U5_ggg(X, Xs, Val, Start, <_out_ag(X, Val)) -> U6_ggg(X, Xs, Val, Start, find_in_ggg(Xs, Val, Start)) U6_ggg(X, Xs, Val, Start, find_out_ggg(Xs, Val, Start)) -> find_out_ggg(.(X, Xs), Val, Start) U1_gg(Vec, Val, find_out_ggg(Vec, Val, Vec)) -> find_out_gg(Vec, Val) The argument filtering Pi contains the following mapping: find_in_gg(x1, x2) = find_in_gg(x1, x2) [] = [] find_out_gg(x1, x2) = find_out_gg(x1, x2) U1_gg(x1, x2, x3) = U1_gg(x1, x2, x3) find_in_ggg(x1, x2, x3) = find_in_ggg(x1, x2, x3) U2_ggg(x1, x2, x3) = U2_ggg(x1, x2, x3) addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag(x2) +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x2, x5) U3_ggg(x1, x2, x3) = U3_ggg(x1, x2, x3) find_out_ggg(x1, x2, x3) = find_out_ggg(x1, x2, x3) U4_ggg(x1, x2, x3, x4, x5) = U4_ggg(x2, x3, x4, x5) >=_in_ag(x1, x2) = >=_in_ag(x2) >=_out_ag(x1, x2) = >=_out_ag(x2) U5_ggg(x1, x2, x3, x4, x5) = U5_ggg(x2, x3, x4, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag(x2) U6_ggg(x1, x2, x3, x4, x5) = U6_ggg(x2, x3, x4, x5) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x2, x3) U5_GGG(x1, x2, x3, x4, x5) = U5_GGG(x2, x3, x4, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (123) UsableRulesProof (EQUIVALENT) For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R. ---------------------------------------- (124) Obligation: Pi DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start, StartPlusOne)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(X, Xs), Val, Start) -> U5_GGG(X, Xs, Val, Start, <_in_ag(X, Val)) U5_GGG(X, Xs, Val, Start, <_out_ag(X, Val)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: addOne_in_ga([], []) -> addOne_out_ga([], []) addOne_in_ga(.(X, Xs), .(Y, Ys)) -> U7_ga(X, Xs, Y, Ys, is_in_ag(Y, +(X, 1))) <_in_ag(X0, X1) -> <_out_ag(X0, X1) U7_ga(X, Xs, Y, Ys, is_out_ag(Y, +(X, 1))) -> U8_ga(X, Xs, Y, Ys, addOne_in_ga(Xs, Ys)) is_in_ag(X0, X1) -> is_out_ag(X0, X1) U8_ga(X, Xs, Y, Ys, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(X, Xs), .(Y, Ys)) The argument filtering Pi contains the following mapping: [] = [] addOne_in_ga(x1, x2) = addOne_in_ga(x1) addOne_out_ga(x1, x2) = addOne_out_ga(x1, x2) .(x1, x2) = .(x2) U7_ga(x1, x2, x3, x4, x5) = U7_ga(x2, x5) is_in_ag(x1, x2) = is_in_ag(x2) is_out_ag(x1, x2) = is_out_ag(x2) +(x1, x2) = +(x2) 1 = 1 U8_ga(x1, x2, x3, x4, x5) = U8_ga(x2, x5) <_in_ag(x1, x2) = <_in_ag(x2) <_out_ag(x1, x2) = <_out_ag(x2) FIND_IN_GG(x1, x2) = FIND_IN_GG(x1, x2) FIND_IN_GGG(x1, x2, x3) = FIND_IN_GGG(x1, x2, x3) U2_GGG(x1, x2, x3) = U2_GGG(x1, x2, x3) U5_GGG(x1, x2, x3, x4, x5) = U5_GGG(x2, x3, x4, x5) We have to consider all (P,R,Pi)-chains ---------------------------------------- (125) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (126) Obligation: Q DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) FIND_IN_GGG(.(Xs), Val, Start) -> U5_GGG(Xs, Val, Start, <_in_ag(Val)) U5_GGG(Xs, Val, Start, <_out_ag(Val)) -> FIND_IN_GGG(Xs, Val, Start) The TRS R consists of the following rules: addOne_in_ga([]) -> addOne_out_ga([], []) addOne_in_ga(.(Xs)) -> U7_ga(Xs, is_in_ag(+(1))) <_in_ag(X1) -> <_out_ag(X1) U7_ga(Xs, is_out_ag(+(1))) -> U8_ga(Xs, addOne_in_ga(Xs)) is_in_ag(X1) -> is_out_ag(X1) U8_ga(Xs, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(Xs), .(Ys)) The set Q consists of the following terms: addOne_in_ga(x0) <_in_ag(x0) U7_ga(x0, x1) is_in_ag(x0) U8_ga(x0, x1) We have to consider all (P,Q,R)-chains. ---------------------------------------- (127) TransformationProof (EQUIVALENT) By rewriting [LPAR04] the rule FIND_IN_GGG(.(Xs), Val, Start) -> U5_GGG(Xs, Val, Start, <_in_ag(Val)) at position [3] we obtained the following new rules [LPAR04]: (FIND_IN_GGG(.(Xs), Val, Start) -> U5_GGG(Xs, Val, Start, <_out_ag(Val)),FIND_IN_GGG(.(Xs), Val, Start) -> U5_GGG(Xs, Val, Start, <_out_ag(Val))) ---------------------------------------- (128) Obligation: Q DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) U5_GGG(Xs, Val, Start, <_out_ag(Val)) -> FIND_IN_GGG(Xs, Val, Start) FIND_IN_GGG(.(Xs), Val, Start) -> U5_GGG(Xs, Val, Start, <_out_ag(Val)) The TRS R consists of the following rules: addOne_in_ga([]) -> addOne_out_ga([], []) addOne_in_ga(.(Xs)) -> U7_ga(Xs, is_in_ag(+(1))) <_in_ag(X1) -> <_out_ag(X1) U7_ga(Xs, is_out_ag(+(1))) -> U8_ga(Xs, addOne_in_ga(Xs)) is_in_ag(X1) -> is_out_ag(X1) U8_ga(Xs, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(Xs), .(Ys)) The set Q consists of the following terms: addOne_in_ga(x0) <_in_ag(x0) U7_ga(x0, x1) is_in_ag(x0) U8_ga(x0, x1) We have to consider all (P,Q,R)-chains. ---------------------------------------- (129) UsableRulesProof (EQUIVALENT) As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [LPAR04] we can delete all non-usable rules [FROCOS05] from R. ---------------------------------------- (130) Obligation: Q DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) U5_GGG(Xs, Val, Start, <_out_ag(Val)) -> FIND_IN_GGG(Xs, Val, Start) FIND_IN_GGG(.(Xs), Val, Start) -> U5_GGG(Xs, Val, Start, <_out_ag(Val)) The TRS R consists of the following rules: addOne_in_ga([]) -> addOne_out_ga([], []) addOne_in_ga(.(Xs)) -> U7_ga(Xs, is_in_ag(+(1))) is_in_ag(X1) -> is_out_ag(X1) U7_ga(Xs, is_out_ag(+(1))) -> U8_ga(Xs, addOne_in_ga(Xs)) U8_ga(Xs, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(Xs), .(Ys)) The set Q consists of the following terms: addOne_in_ga(x0) <_in_ag(x0) U7_ga(x0, x1) is_in_ag(x0) U8_ga(x0, x1) We have to consider all (P,Q,R)-chains. ---------------------------------------- (131) QReductionProof (EQUIVALENT) We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.[THIEMANN]. <_in_ag(x0) ---------------------------------------- (132) Obligation: Q DP problem: The TRS P consists of the following rules: FIND_IN_GG(Vec, Val) -> FIND_IN_GGG(Vec, Val, Vec) FIND_IN_GGG([], Val, Start) -> U2_GGG(Val, Start, addOne_in_ga(Start)) U2_GGG(Val, Start, addOne_out_ga(Start, StartPlusOne)) -> FIND_IN_GG(StartPlusOne, Val) U5_GGG(Xs, Val, Start, <_out_ag(Val)) -> FIND_IN_GGG(Xs, Val, Start) FIND_IN_GGG(.(Xs), Val, Start) -> U5_GGG(Xs, Val, Start, <_out_ag(Val)) The TRS R consists of the following rules: addOne_in_ga([]) -> addOne_out_ga([], []) addOne_in_ga(.(Xs)) -> U7_ga(Xs, is_in_ag(+(1))) is_in_ag(X1) -> is_out_ag(X1) U7_ga(Xs, is_out_ag(+(1))) -> U8_ga(Xs, addOne_in_ga(Xs)) U8_ga(Xs, addOne_out_ga(Xs, Ys)) -> addOne_out_ga(.(Xs), .(Ys)) The set Q consists of the following terms: addOne_in_ga(x0) U7_ga(x0, x1) is_in_ag(x0) U8_ga(x0, x1) We have to consider all (P,Q,R)-chains. ---------------------------------------- (133) PrologToDTProblemTransformerProof (SOUND) Built DT problem from termination graph DT10. { "root": 1, "program": { "directives": [], "clauses": [ [ "(find ([]) X1)", "(!)" ], [ "(find Vec Val)", "(find Vec Val Vec)" ], [ "(find ([]) Val Start)", "(',' (addOne Start StartPlusOne) (find StartPlusOne Val))" ], [ "(find (. X X2) Val X3)", "(',' (>= X Val) (!))" ], [ "(find (. X Xs) Val Start)", "(',' (< X Val) (',' (!) (find Xs Val Start)))" ], [ "(addOne ([]) ([]))", null ], [ "(addOne (. X Xs) (. Y Ys))", "(',' (is Y (+ X (1))) (addOne Xs Ys))" ] ] }, "graph": { "nodes": { "22": { "goal": [{ "clause": 4, "scope": 2, "term": "(find T7 T8 T7)" }], "kb": { "nonunifying": [ [ "(find T7 T8)", "(find ([]) X5)" ], [ "(find T7 T8 T7)", "(find (. X20 X21) X22 X23)" ] ], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T7", "T8" ], "free": [ "X5", "X20", "X21", "X22", "X23" ], "exprvars": [] } }, "2191": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "23": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "2190": { "goal": [{ "clause": 4, "scope": 3, "term": "(find T26 T27 (. T25 T26))" }], "kb": { "nonunifying": [[ "(find T26 T27 (. T25 T26))", "(find (. X83 X84) X85 X86)" ]], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T25", "T27", "T26" ], "free": [ "X83", "X84", "X85", "X86" ], "exprvars": [ "T25", "T18", "T16", "T27" ] } }, "2056": { "goal": [{ "clause": -1, "scope": -1, "term": "(',' (< T25 T27) (',' (!_2) (find T26 T27 (. T25 T26))))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" } ] }, "ground": [ "T25", "T26", "T27" ], "free": [], "exprvars": [ "T25", "T18", "T16", "T27" ] } }, "2111": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">=" } ] }, "ground": [ "T25", "T27", "T26" ], "free": [], "exprvars": [ "T25", "T18", "T16", "T27" ] } }, "2110": { "goal": [{ "clause": -1, "scope": -1, "term": "(',' (!_2) (find T26 T27 (. T25 T26)))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T25", "T27", "T26" ], "free": [], "exprvars": [ "T25", "T18", "T16", "T27" ] } }, "type": "Nodes", "2194": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "2193": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": [], "exprvars": [ "T25", "T18", "T16", "T27" ] } }, "2126": { "goal": [{ "clause": -1, "scope": -1, "term": "(',' (is X68 (+ T43 (1))) (addOne ([]) X69))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": ["T43"], "free": [ "X68", "X69" ], "exprvars": [ "T25", "T18", "T39", "T16", "T27", "T38", "T43" ] } }, "1399": { "goal": [ { "clause": -1, "scope": -1, "term": "(!_2)" }, { "clause": 4, "scope": 2, "term": "(find (. T16 T17) T18 (. T16 T17))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [{ "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": "<=" }] }, "ground": [ "T18", "T17", "T16" ], "free": [], "exprvars": [ "T18", "T16" ] } }, "2189": { "goal": [ { "clause": -1, "scope": -1, "term": "(',' (>= T54 T56) (!_3))" }, { "clause": 4, "scope": 3, "term": "(find (. T54 T55) T56 (. T57 (. T54 T55)))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T56", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T54", "T55", "T56", "T57" ], "free": [], "exprvars": [ "T25", "T57", "T18", "T56", "T16", "T27" ] } }, "10": { "goal": [{ "clause": 1, "scope": 1, "term": "(find T1 T2)" }], "kb": { "nonunifying": [[ "(find T1 T2)", "(find ([]) X5)" ]], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T1", "T2" ], "free": ["X5"], "exprvars": [] } }, "11": { "goal": [{ "clause": -1, "scope": -1, "term": "(true)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "2180": { "goal": [ { "clause": 5, "scope": 5, "term": "(addOne ([]) X69)" }, { "clause": 6, "scope": 5, "term": "(addOne ([]) X69)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T44", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T43", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": ["X69"], "exprvars": [ "T25", "T18", "T39", "T44", "T16", "T27", "T38", "T43" ] } }, "12": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "17": { "goal": [{ "clause": -1, "scope": -1, "term": "(find T7 T8 T7)" }], "kb": { "nonunifying": [[ "(find T7 T8)", "(find ([]) X5)" ]], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T7", "T8" ], "free": ["X5"], "exprvars": [] } }, "18": { "goal": [ { "clause": 2, "scope": 2, "term": "(find T7 T8 T7)" }, { "clause": 3, "scope": 2, "term": "(find T7 T8 T7)" }, { "clause": 4, "scope": 2, "term": "(find T7 T8 T7)" } ], "kb": { "nonunifying": [[ "(find T7 T8)", "(find ([]) X5)" ]], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T7", "T8" ], "free": ["X5"], "exprvars": [] } }, "2121": { "goal": [{ "clause": 6, "scope": 4, "term": "(addOne (. T39 ([])) X51)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": ["T39"], "free": ["X51"], "exprvars": [ "T25", "T18", "T39", "T16", "T27", "T38" ] } }, "2120": { "goal": [ { "clause": 5, "scope": 4, "term": "(addOne (. T39 ([])) X51)" }, { "clause": 6, "scope": 4, "term": "(addOne (. T39 ([])) X51)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": ["T39"], "free": ["X51"], "exprvars": [ "T25", "T18", "T39", "T16", "T27", "T38" ] } }, "2185": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T44", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T43", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": [], "exprvars": [ "T25", "T18", "T39", "T44", "T16", "T27", "T38", "T43" ] } }, "2184": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T44", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T43", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "arguments": [ { "name": "T43", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T43", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": [], "exprvars": [ "T25", "T18", "T39", "T44", "T16", "T27", "T38", "T43" ] } }, "2183": { "goal": [{ "clause": -1, "scope": -1, "term": "(true)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T44", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T43", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "arguments": [ { "name": "T43", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T43", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": [], "exprvars": [ "T25", "T18", "T39", "T44", "T16", "T27", "T38", "T43" ] } }, "2182": { "goal": [{ "clause": 6, "scope": 5, "term": "(addOne ([]) X69)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T44", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T43", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": ["X69"], "exprvars": [ "T25", "T18", "T39", "T44", "T16", "T27", "T38", "T43" ] } }, "2181": { "goal": [{ "clause": 5, "scope": 5, "term": "(addOne ([]) X69)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T44", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T43", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": ["X69"], "exprvars": [ "T25", "T18", "T39", "T44", "T16", "T27", "T38", "T43" ] } }, "2119": { "goal": [{ "clause": -1, "scope": -1, "term": "(find T40 T38)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T38", "T40" ], "free": [], "exprvars": [] } }, "1": { "goal": [{ "clause": -1, "scope": -1, "term": "(find T1 T2)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T1", "T2" ], "free": [], "exprvars": [] } }, "2118": { "goal": [{ "clause": -1, "scope": -1, "term": "(addOne (. T39 ([])) X51)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": ["T39"], "free": ["X51"], "exprvars": [ "T25", "T18", "T39", "T16", "T27", "T38" ] } }, "1402": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [{ "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": "<=" }] }, "ground": [], "free": [], "exprvars": [ "T18", "T16" ] } }, "2117": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": [], "exprvars": [ "T25", "T18", "T16", "T27" ] } }, "1401": { "goal": [{ "clause": -1, "scope": -1, "term": "(true)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [{ "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": "<=" }] }, "ground": [], "free": [], "exprvars": [ "T18", "T16" ] } }, "2116": { "goal": [{ "clause": -1, "scope": -1, "term": "(',' (addOne (. T39 ([])) X51) (find X51 T38))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T38", "T39" ], "free": ["X51"], "exprvars": [ "T25", "T18", "T39", "T16", "T27", "T38" ] } }, "1400": { "goal": [{ "clause": 4, "scope": 2, "term": "(find (. T16 T17) T18 (. T16 T17))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [{ "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }] }, "ground": [ "T18", "T17", "T16" ], "free": [], "exprvars": [ "T18", "T16" ] } }, "2115": { "goal": [ { "clause": 3, "scope": 3, "term": "(find T26 T27 (. T25 T26))" }, { "clause": 4, "scope": 3, "term": "(find T26 T27 (. T25 T26))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T25", "T27", "T26" ], "free": [], "exprvars": [ "T25", "T18", "T16", "T27" ] } }, "2114": { "goal": [{ "clause": 2, "scope": 3, "term": "(find T26 T27 (. T25 T26))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T25", "T27", "T26" ], "free": [], "exprvars": [ "T25", "T18", "T16", "T27" ] } }, "6": { "goal": [ { "clause": 0, "scope": 1, "term": "(find T1 T2)" }, { "clause": 1, "scope": 1, "term": "(find T1 T2)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T1", "T2" ], "free": [], "exprvars": [] } }, "2113": { "goal": [ { "clause": 2, "scope": 3, "term": "(find T26 T27 (. T25 T26))" }, { "clause": 3, "scope": 3, "term": "(find T26 T27 (. T25 T26))" }, { "clause": 4, "scope": 3, "term": "(find T26 T27 (. T25 T26))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T25", "T27", "T26" ], "free": [], "exprvars": [ "T25", "T18", "T16", "T27" ] } }, "2179": { "goal": [{ "clause": -1, "scope": -1, "term": "(addOne ([]) X69)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T44", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T43", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T16", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T44", "T43" ], "free": [ "X68", "X69" ], "exprvars": [ "T25", "T18", "T39", "T44", "T16", "T27", "T38", "T43" ] } }, "2112": { "goal": [{ "clause": -1, "scope": -1, "term": "(find T26 T27 (. T25 T26))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T18", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T16", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T25", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T25", "T27", "T26" ], "free": [], "exprvars": [ "T25", "T18", "T16", "T27" ] } }, "9": { "goal": [ { "clause": -1, "scope": -1, "term": "(!_1)" }, { "clause": 1, "scope": 1, "term": "(find ([]) T4)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T4"], "free": [], "exprvars": [] } }, "20": { "goal": [ { "clause": 3, "scope": 2, "term": "(find T7 T8 T7)" }, { "clause": 4, "scope": 2, "term": "(find T7 T8 T7)" } ], "kb": { "nonunifying": [[ "(find T7 T8)", "(find ([]) X5)" ]], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T7", "T8" ], "free": ["X5"], "exprvars": [] } }, "21": { "goal": [ { "clause": -1, "scope": -1, "term": "(',' (>= T16 T18) (!_2))" }, { "clause": 4, "scope": 2, "term": "(find (. T16 T17) T18 (. T16 T17))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T16", "T17", "T18" ], "free": [], "exprvars": [] } } }, "edges": [ { "from": 1, "to": 6, "label": "CASE" }, { "from": 6, "to": 9, "label": "EVAL with clause\nfind([], X5) :- !_1.\nand substitutionT1 -> [],\nT2 -> T4,\nX5 -> T4" }, { "from": 6, "to": 10, "label": "EVAL-BACKTRACK" }, { "from": 9, "to": 11, "label": "CUT" }, { "from": 10, "to": 17, "label": "ONLY EVAL with clause\nfind(X8, X9) :- find(X8, X9, X8).\nand substitutionT1 -> T7,\nX8 -> T7,\nT2 -> T8,\nX9 -> T8" }, { "from": 11, "to": 12, "label": "SUCCESS" }, { "from": 17, "to": 18, "label": "CASE" }, { "from": 18, "to": 20, "label": "BACKTRACK\nfor clause: find([], Val, Start) :- ','(addOne(Start, StartPlusOne), find(StartPlusOne, Val))\nwith clash: (find(T7, T8), find([], X5))" }, { "from": 20, "to": 21, "label": "EVAL with clause\nfind(.(X20, X21), X22, X23) :- ','(>=(X20, X22), !_2).\nand substitutionX20 -> T16,\nX21 -> T17,\nT7 -> .(T16, T17),\nT8 -> T18,\nX22 -> T18,\nX23 -> .(T16, T17)" }, { "from": 20, "to": 22, "label": "EVAL-BACKTRACK" }, { "from": 21, "to": 23, "label": "IS ERROR" }, { "from": 21, "to": 1399, "label": "ARITHCOMP SUCCESS" }, { "from": 21, "to": 1400, "label": "ARITHCOMP FAIL" }, { "from": 22, "to": 2194, "label": "BACKTRACK\nfor clause: find(.(X, Xs), Val, Start) :- ','(<(X, Val), ','(!, find(Xs, Val, Start)))\nwith clash: (find(T7, T8, T7), find(.(X20, X21), X22, X23))" }, { "from": 1399, "to": 1401, "label": "CUT" }, { "from": 1400, "to": 2056, "label": "ONLY EVAL with clause\nfind(.(X32, X33), X34, X35) :- ','(<(X32, X34), ','(!_2, find(X33, X34, X35))).\nand substitutionT16 -> T25,\nX32 -> T25,\nT17 -> T26,\nX33 -> T26,\nT18 -> T27,\nX34 -> T27,\nX35 -> .(T25, T26)" }, { "from": 1401, "to": 1402, "label": "SUCCESS" }, { "from": 2056, "to": 2110, "label": "ARITHCOMP SUCCESS" }, { "from": 2056, "to": 2111, "label": "ARITHCOMP FAIL" }, { "from": 2110, "to": 2112, "label": "CUT" }, { "from": 2112, "to": 2113, "label": "CASE" }, { "from": 2113, "to": 2114, "label": "PARALLEL" }, { "from": 2113, "to": 2115, "label": "PARALLEL" }, { "from": 2114, "to": 2116, "label": "EVAL with clause\nfind([], X49, X50) :- ','(addOne(X50, X51), find(X51, X49)).\nand substitutionT26 -> [],\nT27 -> T38,\nX49 -> T38,\nT25 -> T39,\nX50 -> .(T39, [])" }, { "from": 2114, "to": 2117, "label": "EVAL-BACKTRACK" }, { "from": 2115, "to": 2189, "label": "EVAL with clause\nfind(.(X83, X84), X85, X86) :- ','(>=(X83, X85), !_3).\nand substitutionX83 -> T54,\nX84 -> T55,\nT26 -> .(T54, T55),\nT27 -> T56,\nX85 -> T56,\nT25 -> T57,\nX86 -> .(T57, .(T54, T55))" }, { "from": 2115, "to": 2190, "label": "EVAL-BACKTRACK" }, { "from": 2116, "to": 2118, "label": "SPLIT 1" }, { "from": 2116, "to": 2119, "label": "SPLIT 2\nnew knowledge:\nT39 is ground\nT40 is ground\nreplacements:X51 -> T40" }, { "from": 2118, "to": 2120, "label": "CASE" }, { "from": 2119, "to": 1, "label": "INSTANCE with matching:\nT1 -> T40\nT2 -> T38" }, { "from": 2120, "to": 2121, "label": "BACKTRACK\nfor clause: addOne([], [])because of non-unification" }, { "from": 2121, "to": 2126, "label": "ONLY EVAL with clause\naddOne(.(X64, X65), .(X66, X67)) :- ','(is(X66, +(X64, 1)), addOne(X65, X67)).\nand substitutionT39 -> T43,\nX64 -> T43,\nX65 -> [],\nX66 -> X68,\nX67 -> X69,\nX51 -> .(X68, X69)" }, { "from": 2126, "to": 2179, "label": "\nX68 -> T44" }, { "from": 2179, "to": 2180, "label": "CASE" }, { "from": 2180, "to": 2181, "label": "PARALLEL" }, { "from": 2180, "to": 2182, "label": "PARALLEL" }, { "from": 2181, "to": 2183, "label": "ONLY EVAL with clause\naddOne([], []).\nand substitutionX69 -> []" }, { "from": 2182, "to": 2185, "label": "BACKTRACK\nfor clause: addOne(.(X, Xs), .(Y, Ys)) :- ','(is(Y, +(X, 1)), addOne(Xs, Ys))because of non-unification" }, { "from": 2183, "to": 2184, "label": "SUCCESS" }, { "from": 2189, "to": 2191, "label": "IS ERROR" }, { "from": 2190, "to": 2193, "label": "BACKTRACK\nfor clause: find(.(X, Xs), Val, Start) :- ','(<(X, Val), ','(!, find(Xs, Val, Start)))\nwith clash: (find(T26, T27, .(T25, T26)), find(.(X83, X84), X85, X86))" } ], "type": "Graph" } } ---------------------------------------- (134) Obligation: Triples: findA(.(X1, []), X2) :- ','(addOnecB(X1, X3), findA(X3, X2)). Clauses: findcA([], X1). findcA(.(X1, X2), X3). findcA(.(X1, []), X2) :- ','(addOnecB(X1, X3), findcA(X3, X2)). addOnecB(X1, .(X2, [])). Afs: findA(x1, x2) = findA(x1, x2) ---------------------------------------- (135) TriplesToPiDPProof (SOUND) We use the technique of [DT09]. With regard to the inferred argument filtering the predicates were used in the following modes: findA_in_2: (b,b) Transforming TRIPLES into the following Term Rewriting System: Pi DP problem: The TRS P consists of the following rules: FINDA_IN_GG(.(X1, []), X2) -> U1_GG(X1, X2, addOnecB_in_aa(X1, X3)) U1_GG(X1, X2, addOnecB_out_aa(X1, X3)) -> U2_GG(X1, X2, findA_in_gg(X3, X2)) U1_GG(X1, X2, addOnecB_out_aa(X1, X3)) -> FINDA_IN_GG(X3, X2) The TRS R consists of the following rules: addOnecB_in_aa(X1, .(X2, [])) -> addOnecB_out_aa(X1, .(X2, [])) The argument filtering Pi contains the following mapping: findA_in_gg(x1, x2) = findA_in_gg(x1, x2) .(x1, x2) = .(x2) [] = [] addOnecB_in_aa(x1, x2) = addOnecB_in_aa addOnecB_out_aa(x1, x2) = addOnecB_out_aa(x2) FINDA_IN_GG(x1, x2) = FINDA_IN_GG(x1, x2) U1_GG(x1, x2, x3) = U1_GG(x2, x3) U2_GG(x1, x2, x3) = U2_GG(x2, x3) We have to consider all (P,R,Pi)-chains Infinitary Constructor Rewriting Termination of PiDP implies Termination of TRIPLES ---------------------------------------- (136) Obligation: Pi DP problem: The TRS P consists of the following rules: FINDA_IN_GG(.(X1, []), X2) -> U1_GG(X1, X2, addOnecB_in_aa(X1, X3)) U1_GG(X1, X2, addOnecB_out_aa(X1, X3)) -> U2_GG(X1, X2, findA_in_gg(X3, X2)) U1_GG(X1, X2, addOnecB_out_aa(X1, X3)) -> FINDA_IN_GG(X3, X2) The TRS R consists of the following rules: addOnecB_in_aa(X1, .(X2, [])) -> addOnecB_out_aa(X1, .(X2, [])) The argument filtering Pi contains the following mapping: findA_in_gg(x1, x2) = findA_in_gg(x1, x2) .(x1, x2) = .(x2) [] = [] addOnecB_in_aa(x1, x2) = addOnecB_in_aa addOnecB_out_aa(x1, x2) = addOnecB_out_aa(x2) FINDA_IN_GG(x1, x2) = FINDA_IN_GG(x1, x2) U1_GG(x1, x2, x3) = U1_GG(x2, x3) U2_GG(x1, x2, x3) = U2_GG(x2, x3) We have to consider all (P,R,Pi)-chains ---------------------------------------- (137) DependencyGraphProof (EQUIVALENT) The approximation of the Dependency Graph [LOPSTR] contains 1 SCC with 1 less node. ---------------------------------------- (138) Obligation: Pi DP problem: The TRS P consists of the following rules: U1_GG(X1, X2, addOnecB_out_aa(X1, X3)) -> FINDA_IN_GG(X3, X2) FINDA_IN_GG(.(X1, []), X2) -> U1_GG(X1, X2, addOnecB_in_aa(X1, X3)) The TRS R consists of the following rules: addOnecB_in_aa(X1, .(X2, [])) -> addOnecB_out_aa(X1, .(X2, [])) The argument filtering Pi contains the following mapping: .(x1, x2) = .(x2) [] = [] addOnecB_in_aa(x1, x2) = addOnecB_in_aa addOnecB_out_aa(x1, x2) = addOnecB_out_aa(x2) FINDA_IN_GG(x1, x2) = FINDA_IN_GG(x1, x2) U1_GG(x1, x2, x3) = U1_GG(x2, x3) We have to consider all (P,R,Pi)-chains ---------------------------------------- (139) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (140) Obligation: Q DP problem: The TRS P consists of the following rules: U1_GG(X2, addOnecB_out_aa(X3)) -> FINDA_IN_GG(X3, X2) FINDA_IN_GG(.([]), X2) -> U1_GG(X2, addOnecB_in_aa) The TRS R consists of the following rules: addOnecB_in_aa -> addOnecB_out_aa(.([])) The set Q consists of the following terms: addOnecB_in_aa We have to consider all (P,Q,R)-chains. ---------------------------------------- (141) PrologToIRSwTTransformerProof (SOUND) Transformed Prolog program to IRSwT according to method in Master Thesis of A. Weinert { "root": 4, "program": { "directives": [], "clauses": [ [ "(find ([]) X1)", "(!)" ], [ "(find Vec Val)", "(find Vec Val Vec)" ], [ "(find ([]) Val Start)", "(',' (addOne Start StartPlusOne) (find StartPlusOne Val))" ], [ "(find (. X X2) Val X3)", "(',' (>= X Val) (!))" ], [ "(find (. X Xs) Val Start)", "(',' (< X Val) (',' (!) (find Xs Val Start)))" ], [ "(addOne ([]) ([]))", null ], [ "(addOne (. X Xs) (. Y Ys))", "(',' (is Y (+ X (1))) (addOne Xs Ys))" ] ] }, "graph": { "nodes": { "27": { "goal": [ { "clause": 2, "scope": 2, "term": "(find T14 T15 T14)" }, { "clause": 3, "scope": 2, "term": "(find T14 T15 T14)" }, { "clause": 4, "scope": 2, "term": "(find T14 T15 T14)" } ], "kb": { "nonunifying": [[ "(find T14 T15)", "(find ([]) X6)" ]], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T14", "T15" ], "free": ["X6"], "exprvars": [] } }, "28": { "goal": [ { "clause": 3, "scope": 2, "term": "(find T14 T15 T14)" }, { "clause": 4, "scope": 2, "term": "(find T14 T15 T14)" } ], "kb": { "nonunifying": [[ "(find T14 T15)", "(find ([]) X6)" ]], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T14", "T15" ], "free": ["X6"], "exprvars": [] } }, "2133": { "goal": [ { "clause": 5, "scope": 4, "term": "(addOne (. T50 ([])) X68)" }, { "clause": 6, "scope": 4, "term": "(addOne (. T50 ([])) X68)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T49", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": ["T50"], "free": ["X68"], "exprvars": [ "T36", "T29", "T50", "T27", "T38", "T49" ] } }, "2132": { "goal": [{ "clause": -1, "scope": -1, "term": "(find T51 T49)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T49", "T51" ], "free": [], "exprvars": [] } }, "2198": { "goal": [{ "clause": 5, "scope": 5, "term": "(addOne ([]) X86)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T55", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T54", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T49", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": ["X86"], "exprvars": [ "T36", "T29", "T50", "T55", "T27", "T38", "T49", "T54" ] } }, "2131": { "goal": [{ "clause": -1, "scope": -1, "term": "(addOne (. T50 ([])) X68)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T49", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": ["T50"], "free": ["X68"], "exprvars": [ "T36", "T29", "T50", "T27", "T38", "T49" ] } }, "2130": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": [], "exprvars": [ "T36", "T29", "T27", "T38" ] } }, "2196": { "goal": [ { "clause": 5, "scope": 5, "term": "(addOne ([]) X86)" }, { "clause": 6, "scope": 5, "term": "(addOne ([]) X86)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T55", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T54", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T49", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": ["X86"], "exprvars": [ "T36", "T29", "T50", "T55", "T27", "T38", "T49", "T54" ] } }, "2295": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "type": "Nodes", "2293": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": [], "exprvars": [ "T36", "T29", "T27", "T38" ] } }, "2192": { "goal": [{ "clause": -1, "scope": -1, "term": "(addOne ([]) X86)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T55", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T54", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T49", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T55", "T54" ], "free": [ "X85", "X86" ], "exprvars": [ "T36", "T29", "T50", "T55", "T27", "T38", "T49", "T54" ] } }, "2129": { "goal": [{ "clause": -1, "scope": -1, "term": "(',' (addOne (. T50 ([])) X68) (find X68 T49))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T49", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T49", "T50" ], "free": ["X68"], "exprvars": [ "T36", "T29", "T50", "T27", "T38", "T49" ] } }, "2128": { "goal": [ { "clause": 3, "scope": 3, "term": "(find T37 T38 (. T36 T37))" }, { "clause": 4, "scope": 3, "term": "(find T37 T38 (. T36 T37))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T36", "T38", "T37" ], "free": [], "exprvars": [ "T36", "T29", "T27", "T38" ] } }, "2205": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T55", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T54", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T49", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": [], "exprvars": [ "T36", "T29", "T50", "T55", "T27", "T38", "T49", "T54" ] } }, "2127": { "goal": [{ "clause": 2, "scope": 3, "term": "(find T37 T38 (. T36 T37))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T36", "T38", "T37" ], "free": [], "exprvars": [ "T36", "T29", "T27", "T38" ] } }, "2203": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T55", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T54", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "arguments": [ { "name": "T54", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T54", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T49", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": [], "exprvars": [ "T36", "T29", "T50", "T55", "T27", "T38", "T49", "T54" ] } }, "2125": { "goal": [ { "clause": 2, "scope": 3, "term": "(find T37 T38 (. T36 T37))" }, { "clause": 3, "scope": 3, "term": "(find T37 T38 (. T36 T37))" }, { "clause": 4, "scope": 3, "term": "(find T37 T38 (. T36 T37))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T36", "T38", "T37" ], "free": [], "exprvars": [ "T36", "T29", "T27", "T38" ] } }, "1398": { "goal": [{ "clause": -1, "scope": -1, "term": "(',' (< T36 T38) (',' (!_2) (find T37 T38 (. T36 T37))))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" } ] }, "ground": [ "T36", "T37", "T38" ], "free": [], "exprvars": [ "T36", "T29", "T27", "T38" ] } }, "2124": { "goal": [{ "clause": -1, "scope": -1, "term": "(find T37 T38 (. T36 T37))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T36", "T38", "T37" ], "free": [], "exprvars": [ "T36", "T29", "T27", "T38" ] } }, "2201": { "goal": [{ "clause": -1, "scope": -1, "term": "(true)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T55", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T54", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "arguments": [ { "name": "T54", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T54", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T49", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": [], "exprvars": [ "T36", "T29", "T50", "T55", "T27", "T38", "T49", "T54" ] } }, "1397": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [{ "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<=" }] }, "ground": [], "free": [], "exprvars": [ "T29", "T27" ] } }, "2123": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": ">=" } ] }, "ground": [ "T36", "T38", "T37" ], "free": [], "exprvars": [ "T36", "T29", "T27", "T38" ] } }, "2200": { "goal": [{ "clause": 6, "scope": 5, "term": "(addOne ([]) X86)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T55", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "arguments": [ { "name": "T54", "type": "PlainIntegerVariable" }, { "type": "PlainIntegerConstant", "value": "1" } ], "type": "PlainIntegerOperation", "operation": "+" }, "operation": "=" }, { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T49", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [], "free": ["X86"], "exprvars": [ "T36", "T29", "T50", "T55", "T27", "T38", "T49", "T54" ] } }, "31": { "goal": [ { "clause": -1, "scope": -1, "term": "(',' (>= T27 T29) (!_2))" }, { "clause": 4, "scope": 2, "term": "(find (. T27 T28) T29 (. T27 T28))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T27", "T28", "T29" ], "free": [], "exprvars": [] } }, "32": { "goal": [{ "clause": 4, "scope": 2, "term": "(find T14 T15 T14)" }], "kb": { "nonunifying": [ [ "(find T14 T15)", "(find ([]) X6)" ], [ "(find T14 T15 T14)", "(find (. X37 X38) X39 X40)" ] ], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T14", "T15" ], "free": [ "X6", "X37", "X38", "X39", "X40" ], "exprvars": [] } }, "33": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "13": { "goal": [ { "clause": -1, "scope": -1, "term": "(!_1)" }, { "clause": 1, "scope": 1, "term": "(find ([]) T5)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T5"], "free": [], "exprvars": [] } }, "14": { "goal": [{ "clause": 1, "scope": 1, "term": "(find T1 T2)" }], "kb": { "nonunifying": [[ "(find T1 T2)", "(find ([]) X6)" ]], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T1", "T2" ], "free": ["X6"], "exprvars": [] } }, "15": { "goal": [{ "clause": -1, "scope": -1, "term": "(true)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "16": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "19": { "goal": [{ "clause": -1, "scope": -1, "term": "(find T14 T15 T14)" }], "kb": { "nonunifying": [[ "(find T14 T15)", "(find ([]) X6)" ]], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T14", "T15" ], "free": ["X6"], "exprvars": [] } }, "1396": { "goal": [{ "clause": -1, "scope": -1, "term": "(true)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [{ "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<=" }] }, "ground": [], "free": [], "exprvars": [ "T29", "T27" ] } }, "2122": { "goal": [{ "clause": -1, "scope": -1, "term": "(',' (!_2) (find T37 T38 (. T36 T37)))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T36", "T38", "T37" ], "free": [], "exprvars": [ "T36", "T29", "T27", "T38" ] } }, "2287": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "1395": { "goal": [{ "clause": 4, "scope": 2, "term": "(find (. T27 T28) T29 (. T27 T28))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [{ "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }] }, "ground": [ "T29", "T28", "T27" ], "free": [], "exprvars": [ "T29", "T27" ] } }, "2286": { "goal": [{ "clause": 4, "scope": 3, "term": "(find T37 T38 (. T36 T37))" }], "kb": { "nonunifying": [[ "(find T37 T38 (. T36 T37))", "(find (. X100 X101) X102 X103)" ]], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T36", "T38", "T37" ], "free": [ "X100", "X101", "X102", "X103" ], "exprvars": [ "T36", "T29", "T27", "T38" ] } }, "2285": { "goal": [ { "clause": -1, "scope": -1, "term": "(',' (>= T65 T67) (!_3))" }, { "clause": 4, "scope": 3, "term": "(find (. T65 T66) T67 (. T68 (. T65 T66)))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T67", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": [ "T65", "T66", "T67", "T68" ], "free": [], "exprvars": [ "T36", "T68", "T29", "T67", "T27", "T38" ] } }, "1392": { "goal": [ { "clause": -1, "scope": -1, "term": "(!_2)" }, { "clause": 4, "scope": 2, "term": "(find (. T27 T28) T29 (. T27 T28))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [{ "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": "<=" }] }, "ground": [ "T29", "T28", "T27" ], "free": [], "exprvars": [ "T29", "T27" ] } }, "4": { "goal": [{ "clause": -1, "scope": -1, "term": "(find T1 T2)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T1", "T2" ], "free": [], "exprvars": [] } }, "5": { "goal": [ { "clause": 0, "scope": 1, "term": "(find T1 T2)" }, { "clause": 1, "scope": 1, "term": "(find T1 T2)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T1", "T2" ], "free": [], "exprvars": [] } }, "2135": { "goal": [{ "clause": -1, "scope": -1, "term": "(',' (is X85 (+ T54 (1))) (addOne ([]) X86))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T49", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T38", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": ["T54"], "free": [ "X85", "X86" ], "exprvars": [ "T36", "T29", "T50", "T27", "T38", "T49", "T54" ] } }, "2134": { "goal": [{ "clause": 6, "scope": 4, "term": "(addOne (. T50 ([])) X68)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [ { "lhs": { "name": "T29", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T36", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T27", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T27", "type": "PlainIntegerVariable" }, "operation": ">" }, { "lhs": { "name": "T49", "type": "PlainIntegerVariable" }, "type": "PlainIntegerRelation", "rhs": { "name": "T38", "type": "PlainIntegerVariable" }, "operation": "<" } ] }, "ground": ["T50"], "free": ["X68"], "exprvars": [ "T36", "T29", "T50", "T27", "T38", "T49" ] } } }, "edges": [ { "from": 4, "to": 5, "label": "CASE" }, { "from": 5, "to": 13, "label": "EVAL with clause\nfind([], X6) :- !_1.\nand substitutionT1 -> [],\nT2 -> T5,\nX6 -> T5" }, { "from": 5, "to": 14, "label": "EVAL-BACKTRACK" }, { "from": 13, "to": 15, "label": "CUT" }, { "from": 14, "to": 19, "label": "ONLY EVAL with clause\nfind(X18, X19) :- find(X18, X19, X18).\nand substitutionT1 -> T14,\nX18 -> T14,\nT2 -> T15,\nX19 -> T15" }, { "from": 15, "to": 16, "label": "SUCCESS" }, { "from": 19, "to": 27, "label": "CASE" }, { "from": 27, "to": 28, "label": "BACKTRACK\nfor clause: find([], Val, Start) :- ','(addOne(Start, StartPlusOne), find(StartPlusOne, Val))\nwith clash: (find(T14, T15), find([], X6))" }, { "from": 28, "to": 31, "label": "EVAL with clause\nfind(.(X37, X38), X39, X40) :- ','(>=(X37, X39), !_2).\nand substitutionX37 -> T27,\nX38 -> T28,\nT14 -> .(T27, T28),\nT15 -> T29,\nX39 -> T29,\nX40 -> .(T27, T28)" }, { "from": 28, "to": 32, "label": "EVAL-BACKTRACK" }, { "from": 31, "to": 33, "label": "IS ERROR" }, { "from": 31, "to": 1392, "label": "ARITHCOMP SUCCESS" }, { "from": 31, "to": 1395, "label": "ARITHCOMP FAIL" }, { "from": 32, "to": 2295, "label": "BACKTRACK\nfor clause: find(.(X, Xs), Val, Start) :- ','(<(X, Val), ','(!, find(Xs, Val, Start)))\nwith clash: (find(T14, T15, T14), find(.(X37, X38), X39, X40))" }, { "from": 1392, "to": 1396, "label": "CUT" }, { "from": 1395, "to": 1398, "label": "ONLY EVAL with clause\nfind(.(X49, X50), X51, X52) :- ','(<(X49, X51), ','(!_2, find(X50, X51, X52))).\nand substitutionT27 -> T36,\nX49 -> T36,\nT28 -> T37,\nX50 -> T37,\nT29 -> T38,\nX51 -> T38,\nX52 -> .(T36, T37)" }, { "from": 1396, "to": 1397, "label": "SUCCESS" }, { "from": 1398, "to": 2122, "label": "ARITHCOMP SUCCESS" }, { "from": 1398, "to": 2123, "label": "ARITHCOMP FAIL" }, { "from": 2122, "to": 2124, "label": "CUT" }, { "from": 2124, "to": 2125, "label": "CASE" }, { "from": 2125, "to": 2127, "label": "PARALLEL" }, { "from": 2125, "to": 2128, "label": "PARALLEL" }, { "from": 2127, "to": 2129, "label": "EVAL with clause\nfind([], X66, X67) :- ','(addOne(X67, X68), find(X68, X66)).\nand substitutionT37 -> [],\nT38 -> T49,\nX66 -> T49,\nT36 -> T50,\nX67 -> .(T50, [])" }, { "from": 2127, "to": 2130, "label": "EVAL-BACKTRACK" }, { "from": 2128, "to": 2285, "label": "EVAL with clause\nfind(.(X100, X101), X102, X103) :- ','(>=(X100, X102), !_3).\nand substitutionX100 -> T65,\nX101 -> T66,\nT37 -> .(T65, T66),\nT38 -> T67,\nX102 -> T67,\nT36 -> T68,\nX103 -> .(T68, .(T65, T66))" }, { "from": 2128, "to": 2286, "label": "EVAL-BACKTRACK" }, { "from": 2129, "to": 2131, "label": "SPLIT 1" }, { "from": 2129, "to": 2132, "label": "SPLIT 2\nnew knowledge:\nT50 is ground\nT51 is ground\nreplacements:X68 -> T51" }, { "from": 2131, "to": 2133, "label": "CASE" }, { "from": 2132, "to": 4, "label": "INSTANCE with matching:\nT1 -> T51\nT2 -> T49" }, { "from": 2133, "to": 2134, "label": "BACKTRACK\nfor clause: addOne([], [])because of non-unification" }, { "from": 2134, "to": 2135, "label": "ONLY EVAL with clause\naddOne(.(X81, X82), .(X83, X84)) :- ','(is(X83, +(X81, 1)), addOne(X82, X84)).\nand substitutionT50 -> T54,\nX81 -> T54,\nX82 -> [],\nX83 -> X85,\nX84 -> X86,\nX68 -> .(X85, X86)" }, { "from": 2135, "to": 2192, "label": "\nX85 -> T55" }, { "from": 2192, "to": 2196, "label": "CASE" }, { "from": 2196, "to": 2198, "label": "PARALLEL" }, { "from": 2196, "to": 2200, "label": "PARALLEL" }, { "from": 2198, "to": 2201, "label": "ONLY EVAL with clause\naddOne([], []).\nand substitutionX86 -> []" }, { "from": 2200, "to": 2205, "label": "BACKTRACK\nfor clause: addOne(.(X, Xs), .(Y, Ys)) :- ','(is(Y, +(X, 1)), addOne(Xs, Ys))because of non-unification" }, { "from": 2201, "to": 2203, "label": "SUCCESS" }, { "from": 2285, "to": 2287, "label": "IS ERROR" }, { "from": 2286, "to": 2293, "label": "BACKTRACK\nfor clause: find(.(X, Xs), Val, Start) :- ','(<(X, Val), ','(!, find(Xs, Val, Start)))\nwith clash: (find(T37, T38, .(T36, T37)), find(.(X100, X101), X102, X103))" } ], "type": "Graph" } } ---------------------------------------- (142) Obligation: Rules: f2122_in(T37, T38, T36) -> f2124_in(T37, T38, T36) :|: TRUE f2124_out(x, x1, x2) -> f2122_out(x, x1, x2) :|: TRUE f2133_out(T50) -> f2131_out(T50) :|: TRUE f2131_in(x3) -> f2133_in(x3) :|: TRUE f2196_out -> f2192_out(T55, T54) :|: TRUE f2192_in(x4, x5) -> f2196_in :|: TRUE f1395_in(x6, x7, x8) -> f1398_in(x6, x8, x7) :|: TRUE f1398_out(x9, x10, x11) -> f1395_out(x9, x11, x10) :|: TRUE f2131_out(x12) -> f2132_in(x13, x14) :|: TRUE f2129_in(x15, x16) -> f2131_in(x15) :|: TRUE f2132_out(x17, x18) -> f2129_out(x19, x18) :|: TRUE f2198_in -> f2201_in :|: TRUE f2201_out -> f2198_out :|: TRUE f31_in(T27, T29, T28) -> f1395_in(T27, T28, T29) :|: T27 < T29 f33_out -> f31_out(x20, x21, x22) :|: TRUE f31_in(x23, x24, x25) -> f33_in :|: TRUE f31_in(x26, x27, x28) -> f1392_in(x26, x28, x27) :|: x26 >= x27 f1392_out(x29, x30, x31) -> f31_out(x29, x31, x30) :|: x29 >= x31 f1395_out(x32, x33, x34) -> f31_out(x32, x34, x33) :|: x32 < x34 f27_out(T14, T15) -> f19_out(T14, T15) :|: TRUE f19_in(x35, x36) -> f27_in(x35, x36) :|: TRUE f4_in(T1, T2) -> f5_in(T1, T2) :|: TRUE f5_out(x37, x38) -> f4_out(x37, x38) :|: TRUE f2201_in -> f2201_out :|: TRUE f2128_out(x39, x40, x41) -> f2125_out(x39, x40, x41) :|: TRUE f2125_in(x42, x43, x44) -> f2127_in(x42, x43, x44) :|: TRUE f2127_out(x45, x46, x47) -> f2125_out(x45, x46, x47) :|: TRUE f2125_in(x48, x49, x50) -> f2128_in(x48, x49, x50) :|: TRUE f2134_in(x51) -> f2135_in(x51) :|: TRUE f2135_out(x52) -> f2134_out(x52) :|: TRUE f27_in(x53, x54) -> f28_in(x53, x54) :|: TRUE f28_out(x55, x56) -> f27_out(x55, x56) :|: TRUE f2200_in -> f2205_in :|: TRUE f2205_out -> f2200_out :|: TRUE f2196_in -> f2198_in :|: TRUE f2198_out -> f2196_out :|: TRUE f2200_out -> f2196_out :|: TRUE f2196_in -> f2200_in :|: TRUE f19_out(x57, x58) -> f14_out(x57, x58) :|: TRUE f14_in(x59, x60) -> f19_in(x59, x60) :|: TRUE f1398_in(x61, x62, x63) -> f2122_in(x63, x62, x61) :|: x61 < x62 f1398_in(x64, x65, x66) -> f2123_in(x64, x65, x66) :|: x64 >= x65 f2123_out(x67, x68, x69) -> f1398_out(x67, x68, x69) :|: x67 >= x68 f2122_out(x70, x71, x72) -> f1398_out(x72, x71, x70) :|: x72 < x71 f2127_in([], x73, x74) -> f2129_in(x74, x73) :|: TRUE f2127_in(x75, x76, x77) -> f2130_in :|: TRUE f2129_out(x78, x79) -> f2127_out([], x79, x78) :|: TRUE f2130_out -> f2127_out(x80, x81, x82) :|: TRUE f28_in(.(x83, x84), x85) -> f31_in(x83, x85, x84) :|: TRUE f28_in(x86, x87) -> f32_in(x86, x87) :|: TRUE f31_out(x88, x89, x90) -> f28_out(.(x88, x90), x89) :|: TRUE f32_out(x91, x92) -> f28_out(x91, x92) :|: TRUE f2124_in(x93, x94, x95) -> f2125_in(x93, x94, x95) :|: TRUE f2125_out(x96, x97, x98) -> f2124_out(x96, x97, x98) :|: TRUE f14_out(x99, x100) -> f5_out(x99, x100) :|: TRUE f13_out(T5) -> f5_out([], T5) :|: TRUE f5_in([], x101) -> f13_in(x101) :|: TRUE f5_in(x102, x103) -> f14_in(x102, x103) :|: TRUE f2132_in(T51, T49) -> f4_in(T51, T49) :|: TRUE f4_out(x104, x105) -> f2132_out(x104, x105) :|: TRUE f2133_in(x106) -> f2134_in(x106) :|: TRUE f2134_out(x107) -> f2133_out(x107) :|: TRUE f2135_in(x108) -> f2192_in(x109, x108) :|: x109 = x108 + 1 f2192_out(x110, x111) -> f2135_out(x111) :|: TRUE Start term: f4_in(T1, T2) ---------------------------------------- (143) IRSwTSimpleDependencyGraphProof (EQUIVALENT) Constructed simple dependency graph. Simplified to the following IRSwTs: intTRSProblem: f2122_in(T37, T38, T36) -> f2124_in(T37, T38, T36) :|: TRUE f2133_out(T50) -> f2131_out(T50) :|: TRUE f2131_in(x3) -> f2133_in(x3) :|: TRUE f2196_out -> f2192_out(T55, T54) :|: TRUE f2192_in(x4, x5) -> f2196_in :|: TRUE f1395_in(x6, x7, x8) -> f1398_in(x6, x8, x7) :|: TRUE f2131_out(x12) -> f2132_in(x13, x14) :|: TRUE f2129_in(x15, x16) -> f2131_in(x15) :|: TRUE f2198_in -> f2201_in :|: TRUE f2201_out -> f2198_out :|: TRUE f31_in(T27, T29, T28) -> f1395_in(T27, T28, T29) :|: T27 < T29 f19_in(x35, x36) -> f27_in(x35, x36) :|: TRUE f4_in(T1, T2) -> f5_in(T1, T2) :|: TRUE f2201_in -> f2201_out :|: TRUE f2125_in(x42, x43, x44) -> f2127_in(x42, x43, x44) :|: TRUE f2134_in(x51) -> f2135_in(x51) :|: TRUE f2135_out(x52) -> f2134_out(x52) :|: TRUE f27_in(x53, x54) -> f28_in(x53, x54) :|: TRUE f2196_in -> f2198_in :|: TRUE f2198_out -> f2196_out :|: TRUE f14_in(x59, x60) -> f19_in(x59, x60) :|: TRUE f1398_in(x61, x62, x63) -> f2122_in(x63, x62, x61) :|: x61 < x62 f2127_in([], x73, x74) -> f2129_in(x74, x73) :|: TRUE f28_in(.(x83, x84), x85) -> f31_in(x83, x85, x84) :|: TRUE f2124_in(x93, x94, x95) -> f2125_in(x93, x94, x95) :|: TRUE f5_in(x102, x103) -> f14_in(x102, x103) :|: TRUE f2132_in(T51, T49) -> f4_in(T51, T49) :|: TRUE f2133_in(x106) -> f2134_in(x106) :|: TRUE f2134_out(x107) -> f2133_out(x107) :|: TRUE f2135_in(x108) -> f2192_in(x109, x108) :|: x109 = x108 + 1 f2192_out(x110, x111) -> f2135_out(x111) :|: TRUE ---------------------------------------- (144) Obligation: Rules: f2122_in(T37, T38, T36) -> f2124_in(T37, T38, T36) :|: TRUE f2133_out(T50) -> f2131_out(T50) :|: TRUE f2131_in(x3) -> f2133_in(x3) :|: TRUE f2196_out -> f2192_out(T55, T54) :|: TRUE f2192_in(x4, x5) -> f2196_in :|: TRUE f1395_in(x6, x7, x8) -> f1398_in(x6, x8, x7) :|: TRUE f2131_out(x12) -> f2132_in(x13, x14) :|: TRUE f2129_in(x15, x16) -> f2131_in(x15) :|: TRUE f2198_in -> f2201_in :|: TRUE f2201_out -> f2198_out :|: TRUE f31_in(T27, T29, T28) -> f1395_in(T27, T28, T29) :|: T27 < T29 f19_in(x35, x36) -> f27_in(x35, x36) :|: TRUE f4_in(T1, T2) -> f5_in(T1, T2) :|: TRUE f2201_in -> f2201_out :|: TRUE f2125_in(x42, x43, x44) -> f2127_in(x42, x43, x44) :|: TRUE f2134_in(x51) -> f2135_in(x51) :|: TRUE f2135_out(x52) -> f2134_out(x52) :|: TRUE f27_in(x53, x54) -> f28_in(x53, x54) :|: TRUE f2196_in -> f2198_in :|: TRUE f2198_out -> f2196_out :|: TRUE f14_in(x59, x60) -> f19_in(x59, x60) :|: TRUE f1398_in(x61, x62, x63) -> f2122_in(x63, x62, x61) :|: x61 < x62 f2127_in([], x73, x74) -> f2129_in(x74, x73) :|: TRUE f28_in(.(x83, x84), x85) -> f31_in(x83, x85, x84) :|: TRUE f2124_in(x93, x94, x95) -> f2125_in(x93, x94, x95) :|: TRUE f5_in(x102, x103) -> f14_in(x102, x103) :|: TRUE f2132_in(T51, T49) -> f4_in(T51, T49) :|: TRUE f2133_in(x106) -> f2134_in(x106) :|: TRUE f2134_out(x107) -> f2133_out(x107) :|: TRUE f2135_in(x108) -> f2192_in(x109, x108) :|: x109 = x108 + 1 f2192_out(x110, x111) -> f2135_out(x111) :|: TRUE ---------------------------------------- (145) IntTRSCompressionProof (EQUIVALENT) Compressed rules. ---------------------------------------- (146) Obligation: Rules: f2135_out(x52:0) -> f2135_out(T54:0) :|: TRUE ---------------------------------------- (147) IRSFormatTransformerProof (EQUIVALENT) Reformatted IRS to match normalized format (transformed away non-linear left-hand sides, !=, / and %). ---------------------------------------- (148) Obligation: Rules: f2135_out(x52:0) -> f2135_out(T54:0) :|: TRUE ---------------------------------------- (149) IRSwTTerminationDigraphProof (EQUIVALENT) Constructed termination digraph! Nodes: (1) f2135_out(x52:0) -> f2135_out(T54:0) :|: TRUE Arcs: (1) -> (1) This digraph is fully evaluated! ---------------------------------------- (150) Obligation: Termination digraph: Nodes: (1) f2135_out(x52:0) -> f2135_out(T54:0) :|: TRUE Arcs: (1) -> (1) This digraph is fully evaluated! ---------------------------------------- (151) FilterProof (EQUIVALENT) Used the following sort dictionary for filtering: f2135_out(VARIABLE) Replaced non-predefined constructor symbols by 0. ---------------------------------------- (152) Obligation: Rules: f2135_out(x52:0) -> f2135_out(T54:0) :|: TRUE ---------------------------------------- (153) IntTRSPeriodicNontermProof (COMPLETE) Normalized system to the following form: f(pc, x52:0) -> f(1, T54:0) :|: pc = 1 && TRUE Witness term starting non-terminating reduction: f(1, 0) ---------------------------------------- (154) NO