Regard the rooms as the vertices of a grid graph. Let and let the two robot positions be . A single controller chooses both commands, so the state space is the ordered Cartesian product , with initial state . Distinguishing the robots matters because their later action laws need not be identical.
For a room , let consist of wait and all cardinal moves remaining in ; write for the resulting room. At an action is the ordered pair , and the deterministic search transition model is
The goal test is , checked at integer time boundaries, and every joint action costs one. Swapping two distinct rooms does not satisfy the goal test. No internal walls are supplied; if walls were specified, they would simply restrict the move relation.
The ordered Cartesian product has states, including goal states. Each robot has at most five commands, so the search tree has branching factor at most , attained when both are interior for . Boundary states have fewer actions under the legal-move convention. For the maximum is , and for it is one if waiting is retained.
The state space is finite, but the unrestricted search tree is infinite because both robots can wait repeatedly. counts physical states, not distinct action histories.
Let be their Manhattan distance. Each joint action can reduce by at most two, so use the simultaneous rendezvous distance
This heuristic function is nonzero whenever the robots are apart. For a transition , the triangle inequality gives
Applying the ceiling function yields , and . Thus is a consistent heuristic, hence an admissible heuristic.
In the unobstructed grid this estimate is exact. Along a shortest route of length , both robots approach a middle room, taking at most steps each; when is an odd integer, the robot with the shorter route waits once. That final wait prevents a crossing from being mistaken for a meeting. With obstacles the same formula remains a relaxation heuristic, though it need not be exact.
Figure 1.
An original nine-edge route needs five simultaneous steps: the last wait produces a meeting rather than a crossing
. Details.
Write for the optimal remaining cost and suppose for . The conclusions hold pointwise:
These are admissible heuristic combinations. An unweighted sum needs an extra condition, such as distributing action costs between the component estimates, to prevent counting the same required work twice.
Use if each estimate is available at comparable cost. For every ,
Thus has heuristic dominance over all the other combinations guaranteed to remain admissible heuristics. A-star search orders nodes by , where is the accumulated path cost. A larger admissible heuristic excludes more nodes from the compulsory region, where is the optimal solution cost. Under the usual nonnegative-cost and goal-normalization assumptions, this gives at least as informative a search guide while preserving the optimality guarantee of A-star search with tree search.
The unweighted sum loses that guarantee. The dominance statement does not promise smaller wall-clock time in every implementation: evaluating estimates costs time, and nodes with depend on tie handling. Nor does admissibility of the inputs alone imply consistent heuristics. If both inputs are consistent heuristics, however, their pointwise maximum is also a consistent heuristic.
Retain the ordered position state , the same initial state and the goal test , with unit joint-action cost. Replace the deterministic search transition model by a set-valued outcome relation. Let
Then
Here for an attempted move leaving the board returns the current room. This explicit boundary convention keeps every outcome inside the state space; alternatively disable a horizontal command unless both possible destinations are legal. Mrs Robot’s commands can still be restricted to legal moves as before.
The result is a fully observable nondeterministic planning problem, assuming that actual positions are observed after every step. Both possible horizontal outcomes must be represented, even though they may coincide at a boundary or when . No outcome probabilities are supplied, so attaching equal probabilities would add an assumption. Its solution is a position-dependent plan or policy.
Use AND-OR search for a strong plan. At an OR node choose a joint action; at its AND node require successful continuations for every possible outcome. A repeated state on the current branch cannot by itself establish progress. On a finite state space, the equivalent strong planning winning-set iteration starts with and repeatedly adds states with an action whose nonempty outcome set is contained in the current winning set:
A newly admitted state has a plan with at most remaining steps in the worst case. This algorithm terminates on the finite state space and is complete for finite guaranteed-success plans. In a general nondeterministic planning problem it cannot guarantee that a strong plan exists: an uncontrollable self-loop can prevent inevitable progress.
For this particular unobstructed grid, a strong plan does exist. Command Mr Robot to wait throughout and move Mrs Robot along a shortest route to his initial room. Her movement is deterministic and his waiting is unaffected by the horizontal uncertainty. This meets in steps, regardless of every uncertain outcome, because no uncertain command is used. Thus a complete finite AND-OR search will find a solution here. With an unspecified disconnected maze, existence would instead require both robots to lie in the same reachable graph component.
Include all four positions and a turn marker:
The initial marker is . There are at most such states before terminal compression. The two robots form one maximizing team in the adversarial search representation. At an R state their actions are joint legal moves, including waiting, with deterministic successor positions and marker M. At an M state the monster outcome is a pair of legal cardinal moves, producing marker R.
Check termination initially and after each simultaneous pair of moves. A state is a failure if . Otherwise it is a success if . Collision takes priority over meeting, so meeting on an occupied room fails. A safe meeting ends immediately, before a further monster response. Room swaps without a shared position at a checked boundary are neither capture nor meeting.
The monsters move randomly, so their nodes are chance nodes, not minimizing decisions. Under independent uniform legal moves, if monster currently has available destinations, each joint outcome has probability . If several commands produce the same state, add their probabilities. This specifies a stochastic game tree, equivalently a Markov decision process for the robot team. Uniform legal moves and independent monsters are explicit boundary/joint-law conventions; uniform attempted directions with blocked moves staying put is another convention, with different boundary transition probabilities but the same search method. For the one-cell grid, a monster with no legal move stays; all four initial positions then coincide and the instance immediately fails.
The game tree alternates MAX nodes for joint robot choices and CHANCE nodes for joint monster outcomes. An interior MAX node has at most children; an interior CHANCE node at most . A terminal safe meeting has utility one and capture has utility zero. With no specified preference for speed, the objective is to maximize the probability of eventual safe meeting.
Use expectimax: maximize at MAX nodes and take the expected value at CHANCE nodes. For nonterminal states, its finite-horizon backup is
Here the horizon counts half-turns, terminal values stay fixed at zero or one, and is zero at nonterminal states. This computes the best chance of success within the horizon. Maximizing the worst monster outcome would solve a different problem from the stipulated random movement.
Because waiting and movement cycles can repeat states, the infinite game tree need not terminate. For the unbounded objective, use value iteration on the finite state graph, starting from terminal-success indicators as above: increases to the optimal eventual-success probability. A reachability-policy method or sufficiently long finite-horizon policies can extract the actions; arbitrary tie choices in the limiting equations must not select a policy that waits forever instead of realizing the value. Alternatively impose an explicit finite horizon and use depth-limited expectimax, stating that changed objective. No method guarantees success with probability one from every initial configuration.

Articles by others on the same topic (0)

There are currently no matching articles.