:-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard2.e',80). % From E: % % :-call_pel_directive(translate(unskipped,'/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e.lps')). :- call_pel_directive(translate(unskipped, '/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e.lps')). :-include(library('ec_planner/ec_test_incl')). :-expects_dialect(lps). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard2.e',80). % From E: % % :-call_pel_directive(translate(begining,'/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e.lps')). :- call_pel_directive(translate(begining, '/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e.lps')). % Sat, 10 Oct 2020 15:31:51 GMT File: (0x559e4b435700)%; %; Copyright (c) 2005 IBM Corporation and others. %; All rights reserved. This program and the accompanying materials %; are made available under the terms of the Common Public License v1.0 %; which accompanies this distribution, and is available at %; http://www.eclipse.org/legal/cpl-v10.html %; %; Contributors: %; IBM - Initial implementation %; %; due to Raymond Reiter %; %; @inproceedings{KarthaLifschitz:1994, %; author = "G. Neelakantan Kartha and Vladimir Lifschitz", %; year = "1994", %; title = "Actions with indirect effects (preliminary report)", %; editor = "Jon Doyle and Erik Sandewall and Pietro Torasso", %; booktitle = "\uppercase{P}roceedings of the \uppercase{F}ourth \uppercase{I}nternational \uppercase{C}onference on \uppercase{P}rinciples of \uppercase{K}nowledge \uppercase{R}epresentation and \uppercase{R}easoning", %; pages = "341--350", %; address = "San Francisco", %; publisher = "Morgan Kaufmann", %; } %; %; @incollection{Shanahan:1999, %; author = "Shanahan, Murray", %; year = "1999", %; title = "The Event Calculus explained", %; editor = "Michael J. Wooldridge and Manuela M. Veloso", %; booktitle = "Artificial Intelligence Today: Recent Trends and Developments", %; series = "Lecture Notes in Computer Science", %; volume = "1600", %; pages = "409--430", %; address = "Berlin", %; publisher = "Springer", %; } %; %; model finding %; %; modifications from Shanahan's formulation: %; InitiallyN -> !HoldsAt %; pruning of models irrelevant to example %; timestamps %; :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',45). % load foundations/Root.e % From E: % % :-call_pel_directive(load('foundations/Root.e')). :- call_pel_directive(load('foundations/Root.e')). % load foundations/EC.e :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',45). % From E: % % :-call_pel_directive(load('foundations/EC.e')). :- call_pel_directive(load('foundations/EC.e')). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',48). % event Throw() % From E: % % event(throw()). events([throw/0]). % fluent ItsBlack() :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',48). % From E: % % fluent(itsBlack()). fluents([itsBlack/0]). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',50). % fluent ItsWhite() % From E: % % fluent(itsWhite()). fluents([itsWhite/0]). % fluent OnBlack() :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',50). % From E: % % fluent(onBlack()). fluents([onBlack/0]). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',52). % fluent OnWhite() % From E: % % fluent(onWhite()). fluents([onWhite/0]). % noninertial ItsBlack, ItsWhite :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',52). % From E: % % :-call_pel_directive(noninertial(itsBlack)). :- call_pel_directive(noninertial(itsBlack)). % From E: % % :-call_pel_directive(noninertial(itsWhite)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',52). :- call_pel_directive(noninertial(itsWhite)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',55). % [time] % HoldsAt(ItsWhite(),time) -> % Initiates(Throw(),OnWhite(),time). % From E: % % '->'( % holds_at(itsWhite(),Time), % initiates_at(throw(),onWhite(),Time)). % [Time]. throw initiates onWhite if itsWhite. :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',55). /* initiated(happens(throw,Time_From,Time_Until), onWhite, [itsWhite]). */ % "% =================================". % [time] % HoldsAt(ItsBlack(),time) -> % Initiates(Throw(),OnBlack(),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',60). % From E: % % '->'( % holds_at(itsBlack(),Time), % initiates_at(throw(),onBlack(),Time)). % [Time]. throw initiates onBlack if itsBlack. /* initiated(happens(throw,Time_From,Time_Until), onBlack, [itsBlack]). */ % "% =================================". % [time] % HoldsAt(ItsWhite(),time) | HoldsAt(ItsBlack(),time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',62). % From E: % % (holds_at(itsWhite(),Time) ; % holds_at(itsBlack(),Time)). % [Time]. false not itsWhite, not itsBlack. % d_pre([not(itsWhite),not(itsBlack)]). % "% =================================". % !HoldsAt(OnWhite(),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',64). % From E: % % holds_at(not(onWhite()),0). initially not onWhite. % initial_state([not(onWhite)]). % "% =================================". :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',66). % !HoldsAt(OnBlack(),0). % From E: % % holds_at(not(onBlack()),0). initially not onBlack. % initial_state([not(onBlack)]). % "% =================================". % Happens(Throw(),35). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',66). % From E: % % happens_at(throw(),35). observe throw at 35. % observe([throw],35). % "% =================================". %; prune models irrelevant to example: :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',70). % HoldsAt(ItsWhite(),0). % From E: % % holds_at(itsWhite(),0). initially itsWhite. % initial_state([itsWhite]). % "% =================================". % HoldsAt(ItsBlack(),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',70). % From E: % % holds_at(itsBlack(),0). initially itsBlack. % initial_state([itsBlack]). % "% =================================". :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',72). % HoldsAt(ItsWhite(),40). % From E: % % holds_at(itsWhite(),40). holds_at(itsWhite,40). % HoldsAt(ItsBlack(),40). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',72). % From E: % % holds_at(itsBlack(),40). holds_at(itsBlack,40). % completion Happens :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',74). % From E: % % :-call_pel_directive(completion(happens_at)). :- call_pel_directive(completion(happens_at)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',77). % range time 0 40 % From E: % % :-call_pel_directive(range(time,0,40)). :- call_pel_directive(range(time, 0, 40)). % range offset 1 1 :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',77). % From E: % % :-call_pel_directive(range(offset,1,1)). :- call_pel_directive(range(offset, 1, 1)). %; End of file. :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e',80). % From E: % % :-call_pel_directive(translate(ending,'/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e.lps')). :- call_pel_directive(translate(ending, '/pack/logicmoo_ec/ext/ec_sources/examples/ecasp-decreasoner/ChessBoard40.e.lps')).