void GenerateNextLevelStates() { PrevStates.Clear(); PrevStates.Union(CurrStates); foreach (PlanAction act in ExecutableActions) { // do execute the action CurrStates = mProbDef.ExecuteAction(CurrStates, act, false, true); } //NewPreds.Clear(); //NewPreds.Union(CurrStates); //NewPreds.IntersectWith(PrevStates); // now for the added predicates compute mutexes between themselves and previous predicates // but first, compute action mutexes. these are between executable actions and previousely // executed actions. //TODO:Think about prevactionlayer GenerateActionMutexes(); GenerateStateMutexes(); NumLevelsExpanded++; }
public void GenerateGraph(PredicateList startState) { Reset(); CurrStates.Union(startState); CheckGoal(); while (SearchState == GraphSearchState.ContinueSearch) { GenerateNextLevelStates(); CheckGoal(); } }