:-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV1.e',56). :- call_pel_directive(translate(unskipped, '/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.pel')). :-include(library('ec_planner/ec_test_incl')). :-expects_dialect(ecalc). :- call_pel_directive(translate(begining, '/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.pel')). %; %; 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 %; %; @inproceedings{Mueller:2004b, %; author = "Erik T. Mueller", %; year = "2004", %; title = "A tool for satisfiability-based commonsense reasoning in the event calculus", %; editor = "Valerie Barr and Zdravko Markov", %; booktitle = "\uppercase{P}roceedings of the \uppercase{S}eventeenth \uppercase{I}nternational \uppercase{F}lorida \uppercase{A}rtificial \uppercase{I}ntelligence \uppercase{R}esearch \uppercase{S}ociety \uppercase{C}onference", %; pages = "147--152", %; address = "Menlo Park, CA", %; publisher = "AAAI Press", %; } %; :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',23). % load foundations/Root.e :- call_pel_directive(load('foundations/Root.e')). % load foundations/EC.e :- call_pel_directive(load('foundations/EC.e')). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',26). % sort agent sort(agent). % sort switch sort(switch). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',28). % sort tv sort(tv). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',30). % function TVOf(switch): tv function(tVOf(switch),tv). % fluent SwitchOn(switch) fluent(switchOn(switch)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',32). % fluent TVOn(tv) fluent(tVOn(tv)). % fluent PluggedIn(tv) fluent(pluggedIn(tv)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',34). % event TurnOn(agent,switch) event(turnOn(agent,switch)). % event TurnOff(agent,switch) event(turnOff(agent,switch)). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',37). % [agent,switch,time] % Initiates(TurnOn(agent,switch),SwitchOn(switch),time). initiates_at(turnOn(Agent,Switch), switchOn(Switch), Time). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',39). % [agent,switch,tv,time] % TVOf(switch)=tv & HoldsAt(PluggedIn(tv),time) -> % Initiates(TurnOn(agent,switch),TVOn(tv),time). tVOf(Switch)=Tv, holds_at(pluggedIn(Tv), Time) -> initiates_at(turnOn(Agent, Switch), tVOn(Tv), Time). % agent James :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',42). t(agent,james). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',44). % switch Switch1 t(switch,switch1). % tv TV1 t(tv,tv1). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',47). % TVOf(Switch1)=TV1. tVOf(switch1)=tv1. % !HoldsAt(PluggedIn(TV1),0). holds_at(not(pluggedIn(tv1)),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',49). % !HoldsAt(SwitchOn(Switch1),0). holds_at(not(switchOn(switch1)),0). % !HoldsAt(TVOn(TV1),0). holds_at(not(tVOn(tv1)),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',51). % Happens(TurnOn(James,Switch1),0). happens_at(turnOn(james,switch1),0). :-was_s_l('/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.e',53). % range time 0 1 :- call_pel_directive(range(time, 0, 1)). % range offset 1 1 :- call_pel_directive(range(offset, 1, 1)). %; End of file. :- call_pel_directive(translate(ending, '/pack/logicmoo_ec/ext/ec_sources/examples/Mueller2004b/TV2.pel')).