%%%%%%%%%% Testing:

#const n = 11.
step(1..n-1).

container(backpack).
item(book).

person(greg).

city(rome).
city(baghdad).
city(boston).
city(berlin).
city(paris).
#domain city(C;C1;C2).    % This defines typed variables 
                          % for cities.

location(X) :- 
       city(X).

const max_length = 10.   % max length of a sequence of actions.
index(0..max_length).

% Description of a trip j1:

trip(j1).

planned_stop(j1,boston,0).    
planned_stop(j1,baghdad,1).
planned_stop(j1,boston,2).
num_of_planned_stops(j1,2).

o(go_on(greg,j1),1).

%starts(go(j1),1).   % trip j1 leaves at 1

obs(at(j1,boston),1,t).
obs(at(greg,boston),1,t).
%-o(depart(j1),3).

%o(pack(greg,book,backpack), 1).
%o(take(greg,backpack), 2).
%o(go_on(greg,j1), 3).
%-o(depart(j1),4).

%%%%%%




%%%%%%% Display:

e(A,S) :- 
       o(A,S),
       atomic(A).

t(F,S) :- 
       h(F,S),
       fluent(F).

at_trip(J,Pos,S) :- 
         h(at(J,Pos),S).

at_pers(P,Pos,S) :- 
         h(at(P,Pos),S).


%at_item(I,Pos,S) :- 
%         h(at(I,Pos),S).
%


hide.
show h(A,B), o(A,B), starts(A,B),ends(A,B),atomic(A).




%e(A,B), at_item(A,B,C).
