-
Notifications
You must be signed in to change notification settings - Fork 57
/
domain.pddl
92 lines (83 loc) · 2.43 KB
/
domain.pddl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
(define (domain driverlog)
(:requirements :typing :durative-actions :fluents)
(:types
location locatable - object
driver truck obj - locatable)
(:predicates
(at ?obj - locatable ?loc - location)
(in ?obj1 - obj ?obj - truck)
(driving ?d - driver ?v - truck)
(link ?x ?y - location) (path ?x ?y - location)
(empty ?v - truck)
)
(:functions (time-to-walk ?loc ?loc1 - location)
(time-to-drive ?loc ?loc1 - location))
(:durative-action LOAD-TRUCK
:parameters
(?obj - obj
?truck - truck
?loc - location)
:duration (= ?duration 2)
:condition
(and (over all (at ?truck ?loc)) (at start (at ?obj ?loc)))
:effect
(and (at start (not (at ?obj ?loc))) (at end (in ?obj ?truck))))
(:durative-action UNLOAD-TRUCK
:parameters
(?obj - obj
?truck - truck
?loc - location)
:duration (= ?duration 2)
:condition
(and (over all (at ?truck ?loc)) (at start (in ?obj ?truck)))
:effect
(and (at start (not (in ?obj ?truck))) (at end (at ?obj ?loc))))
(:durative-action BOARD-TRUCK
:parameters
(?driver - driver
?truck - truck
?loc - location)
:duration (= ?duration 1)
:condition
(and (over all (at ?truck ?loc)) (at start (at ?driver ?loc))
(at start (empty ?truck)))
:effect
(and (at start (not (at ?driver ?loc)))
(at end (driving ?driver ?truck)) (at start (not (empty ?truck)))))
(:durative-action DISEMBARK-TRUCK
:parameters
(?driver - driver
?truck - truck
?loc - location)
:duration (= ?duration 1)
:condition
(and (over all (at ?truck ?loc)) (at start (driving ?driver ?truck)))
:effect
(and (at start (not (driving ?driver ?truck)))
(at end (at ?driver ?loc)) (at end (empty ?truck))))
(:durative-action DRIVE-TRUCK
:parameters
(?truck - truck
?loc-from - location
?loc-to - location
?driver - driver)
:duration (= ?duration (time-to-drive ?loc-from ?loc-to))
:condition
(and (at start (at ?truck ?loc-from))
(over all (driving ?driver ?truck)) (at start (link ?loc-from ?loc-to)))
:effect
(and (at start (not (at ?truck ?loc-from)))
(at end (at ?truck ?loc-to))))
(:durative-action WALK
:parameters
(?driver - driver
?loc-from - location
?loc-to - location)
:duration (= ?duration (time-to-walk ?loc-from ?loc-to))
:condition
(and (at start (at ?driver ?loc-from))
(at start (path ?loc-from ?loc-to)))
:effect
(and (at start (not (at ?driver ?loc-from)))
(at end (at ?driver ?loc-to))))
)