*3.3. Geometric Constraint Predicates*

Basically, three general predicates, evaluated by geometric reasoning, are allocated that set constraints to the task states: *isCrit(*O*<sup>m</sup> <sup>j</sup> ,* O *, Pos)*, *infeasByRob(*R*,* O *, Pos)*, and *assist(Human,* O *, Pos)*. The first predicate indicates that there is a blocking object <sup>O</sup>*<sup>m</sup> <sup>j</sup>* which is located towards the target object O placed in the pose *Pos*. The second one shows that the target object cannot be manipulated by the robot R in the corresponding pose *Pos*. The last predicate shows the manipulation action with the target object O and the corresponding *Pos* must be done by a human operator *Human*.

The proposed predicates are interleaved inside the pre- and post-conditions of the actions. Concerning the actions done by the robot, the predicates ∼*isCrit* and ∼*infeasByRob* are inserted within the preconditions of the actions *Transit, Open, Transfer,* and *Push* in order to avoid moving the robot to any unreachable or infeasible configuration. Referring to the post-conditions, the last two actions may include the negation of the predicate *isCrit* if they are moving a blocking object to a placement where the obstruction does no longer hold. With respect to the actions performed by a human, the preconditions of the actions *HumanTransfer* and *HumanOpen* may include the predicate *assist* in order to indicate the requirement of a human operator.

To illustrate the use of these predicates, the actions *Transit* and *HumanOpen* are described next. The action template *Transit(*R*,* <sup>O</sup>*<sup>m</sup> <sup>i</sup> , Surface, Pos)* is designed to move the robot R (arm and base), without holding any object, towards a grasp configuration of a manipulatable object <sup>O</sup>*<sup>m</sup> <sup>i</sup>* located on a surface *Surface* at pose *Pos*. In the final configuration, the robot holds the target object. The action is applicable if the following preconditions hold: the object is located on a surface, top of the object is clear, the robot arm is empty, it can reach the grasp configuration if there is no movable objects blocking its way to <sup>O</sup>*<sup>m</sup> <sup>i</sup>* . The last precondition is represented by fact *isCrit(*O*<sup>m</sup> <sup>j</sup> ,* <sup>O</sup>*<sup>m</sup> <sup>i</sup> , Pos)*; objects that make this fact to hold are called *Critical Objects* which are the objects blocking the way of reaching the object. As a result of the action, the robot holds an object.

*Transit(*R*,* <sup>O</sup>*<sup>m</sup> <sup>i</sup> , Surface, Pos):*

**Pre**: *onSurface(*O*<sup>m</sup> <sup>i</sup> , Surface, Pos), armEmpty(*R*), clear(*O*<sup>m</sup> <sup>i</sup> ),* <sup>∼</sup>*infeasByRob(*R*,* <sup>O</sup>*<sup>m</sup> <sup>i</sup> , Pos),* ∀O*<sup>m</sup> <sup>j</sup>* <sup>∼</sup>*isCrit(*O*<sup>m</sup> <sup>j</sup> ,* <sup>O</sup>*<sup>m</sup> <sup>i</sup> , Pos)*

**Effect**: *holding(*R*,* <sup>O</sup>*<sup>m</sup> <sup>i</sup> , Pos),* <sup>∼</sup>*clear(*O*<sup>m</sup> <sup>i</sup> ),* <sup>∼</sup>*armEmpty(*R*),* <sup>∼</sup>*onSurface(*O*<sup>m</sup> <sup>i</sup> , Surface, Pos)*

The action template *HumanOpen(Human,* <sup>O</sup>*<sup>m</sup> <sup>i</sup> , Pos, Closed, Open)* is used to open a box-like container <sup>O</sup>*<sup>m</sup> <sup>i</sup>* when it is closed. The action is applicable if the robot needs the assistance from a human operator, represented by the *assist* predicate, and its status is closed, shown by the predicate *status*. These conditions are introduced in the action preconditions. As a result of the action, the corresponding container will be open.

*HumanOpen(Human,* <sup>O</sup>*<sup>m</sup> <sup>i</sup> , Pos, Closed, Open):* **Pre**: *assist(Human,* <sup>O</sup>*<sup>m</sup> <sup>i</sup> , Pos), status(*O*<sup>m</sup> <sup>i</sup> , Closed)* **Effect**: *status(*O*<sup>m</sup> <sup>i</sup> , Open),* <sup>∼</sup>*status(*O*<sup>m</sup> <sup>i</sup> , Closed)*
