0

为了激发我的问题,考虑一个带有可以推动石头的可移动代理的网格世界。到目前为止,一切都很好。我们可能有一个看起来像这样的推送操作(借用自 sokoban pddl):

    (:action push
    :parameters (?p - thing ?s - thing ?ppos - location ?from - location ?to - location ?dir - direction)
    :precondition (and (move ?dir)
        (is-player ?p)
        (is-stone ?s)
        (at ?p ?ppos)
        (at ?s ?from)
        (clear ?to)
        (move-dir ?ppos ?from ?dir)
        (move-dir ?from ?to ?dir)
        (is-nongoal ?to))
    :effect (and
        (not (at ?p ?ppos))
        (not (at ?s ?from))
        (not (clear ?to))
        (at ?p ?from)
        (at ?s ?to)
        (clear ?ppos)
        (not (at-goal ?s)))
)

现在假设我们想要让代理推动一块石头,即使它后面有任意数量的石头。效果是所有这些石头都将在推动方向上移动 1 个位置(前提是它们没有从网格上掉下来或占据与墙壁相同的位置)。

你会如何建模?

4

0 回答 0