
 solve.pl -- The sCASP solver
solve.pl -- The sCASP solver solve(:Goals, +StackIn, -StackOut, -Model)
 solve(:Goals, +StackIn, -StackOut, -Model) check_goal(+Goal, +Module, +Parents, +ProvedIn, -ProvedOut, +StackIn, -StackOut, -Model)[private]
 check_goal(+Goal, +Module, +Parents, +ProvedIn, -ProvedOut, +StackIn, -StackOut, -Model)[private] dynamic_consistency_check(+Goal, +Module, +StackIn) is semidet[private]
 dynamic_consistency_check(+Goal, +Module, +StackIn) is semidet[private] solve_goal(+Goal, +Module, +Parents, +ProvedIn, -ProvedOut, +StackIn, -StackOut, -Model)[private]
 solve_goal(+Goal, +Module, +Parents, +ProvedIn, -ProvedOut, +StackIn, -StackOut, -Model)[private] solve_goal_forall(+Forall, +Module, +Parents, +ProvedIn, -ProvedOut, +StackIn, -StackOut, -Model)[private]
 solve_goal_forall(+Forall, +Module, +Parents, +ProvedIn, -ProvedOut, +StackIn, -StackOut, -Model)[private]forall(Var,Goal) and success if Var
success in all its domain for the goal Goal. It calls solve/4
 solve_goal_table_predicate(+Goal, +Module, +Parents, +ProvedIn, -ProvedOut, +AttStackIn, -AttStackOut, -AttModel)[private]
 solve_goal_table_predicate(+Goal, +Module, +Parents, +ProvedIn, -ProvedOut, +AttStackIn, -AttStackOut, -AttModel)[private] solve_goal_predicate(+Goal, +Module, +Parents, +ProvedIn, -ProvedOut, +StackIn, -StackOut, -Model)[private]
 solve_goal_predicate(+Goal, +Module, +Parents, +ProvedIn, -ProvedOut, +StackIn, -StackOut, -Model)[private] solve_goal_builtin(+Goal, -Model)[private]
 solve_goal_builtin(+Goal, -Model)[private] check_CHS(+Goal, +Module, +Parents, +ProvedIn, +StackIn, -Result) is det[private]
 check_CHS(+Goal, +Module, +Parents, +ProvedIn, +StackIn, -Result) is det[private] neg_in_stack(+Goal, +Parents, +Proved) is semidet[private]
 neg_in_stack(+Goal, +Parents, +Proved) is semidet[private] ground_neg_in_stack(++Goal, +Parents, +Proved) is det[private]
 ground_neg_in_stack(++Goal, +Parents, +Proved) is det[private] constrained_neg_in_stack(+Goal, +Parents, +Proved) is det[private]
 constrained_neg_in_stack(+Goal, +Parents, +Proved) is det[private] proved_in_stack(+Goal, +Proved) is semidet[private]
 proved_in_stack(+Goal, +Proved) is semidet[private] check_parents(+Goal, +Parents, -Type) is semidet[private]
 check_parents(+Goal, +Parents, -Type) is semidet[private]even if we have an even
loop through negation or a simple positive match. stack_parents(+Stack, -Parents) is det[private]
 stack_parents(+Stack, -Parents) is det[private] stack_proved(Stack, Proved:assoc) is det[private]
 stack_proved(Stack, Proved:assoc) is det[private]The code is based on the old proved_in_stack/2. Effectively this extracts the other half than stack_parents/2, so possibly we should sync the code with that.
 solve_c_forall(+Forall, +Module, +Parents, +ProvedIn, -ProvedOut, +StackIn, -StackOut, -Model)[private]
 solve_c_forall(+Forall, +Module, +Parents, +ProvedIn, -ProvedOut, +StackIn, -StackOut, -Model)[private]c_forall(Vars,Goal) and succeeds if the
goal Goal succeeds covering the domain of all the vars in the list
of vars `Vars. It calls solve/4
 solve_var_forall_(+Goal, +Module, +Parents, +ProvedIn, -ProvedOut, +Entry, +Duals, +OtherVars, +StackIn, -StackOut, -Model) is nondet[private]
 solve_var_forall_(+Goal, +Module, +Parents, +ProvedIn, -ProvedOut, +Entry, +Duals, +OtherVars, +StackIn, -StackOut, -Model) is nondet[private]Note that the constraints on the forall variables are maintained explicitly.
 find_duals(+C_Vars, +C_Vars1, +OtherVars, -Duals)[private]
 find_duals(+C_Vars, +C_Vars1, +OtherVars, -Duals)[private] dump_constraint(+C_Vars, +C_Vars1, -Dump, +Pending0, -Pending) is det[private]
 dump_constraint(+C_Vars, +C_Vars1, -Dump, +Pending0, -Pending) is det[private] collect_vars(?Forall, ?CollectForall)[private]
 collect_vars(?Forall, ?CollectForall)[private] my_copy_term(+Var, +Term, -NewVar, -NewTerm) is det[private]
 my_copy_term(+Var, +Term, -NewVar, -NewTerm) is det[private] my_diff_term(+Term, +Vars, -Others) is det[private]
 my_diff_term(+Term, +Vars, -Others) is det[private]