; TeX output 1993.07.13:0942y4ti䍍pPF$4K`yff cmr10MOTELUserManual9&e+XQ cmr12UllricrhHustadt_&AndreasNonnengartRenateScrhmidtJanTimm<܍mMPI{I{92{236qJune1992*B'&vTiv2R6 cmss12Authorr'sAddress8-3>K`y cmr10UllrichUUHustadt 37Max-Planck-InstitutUUfGurInformatikImUUStadtwaldW-6600UUSaarbrGuckenGermanyZSE-mail:qAndreasUUNonnengart 37Max-Planck-InstitutUUfGurInformatikImUUStadtwaldW-6600UUSaarbrGuckenGermanyZSE-mail:qAndreas.Nonnengart@mpi-sb.mpg.de>RenateUUSchmidt 37Max-Planck-InstitutUUfGurInformatikImUUStadtwaldW-6600UUSaarbrGuckenGermanyZSE-mail:qRenate.Schmidt@mpi-sb.mpg.de'O!AcknorwledgementsThisresearchwasfundedbytheGermanMinistryforResearchandT*echnology(BMFT)xundergrantITS 389102ÓandtheDeutscheF*orschungsgemeinschaft,"SFBw314(TICS).TherespGonsibilityforthecontentsofthisUUpublicationlieswiththeauthors.zB'&vTivAbstract*MOTEL&isWalogic-basedknowledgerepresentationlanguagesoftheKL-ONE&family*.1sIt 38*containsasakernelthe!", cmsy10K$RIS"languagewhichisadecidablesublanguageof rst-order*predicateUUlogic(seeBaaderandHollunder(1990)).9WhereasVK$RIS%YisVasingle-agentknowledgerepresentationsystem,=i.e.K$RIS%Yis*onlyabletorepresentgeneralworldknowledgeortheknowledgeofoneagentabGout*theaworld,MOTELBisamulti-agentknowledgerepresentationsystem.TheMOTEL*languageallowsmoGdalcontextsandmoGdalconceptformingoperatorswhichallowto*representandreasonabGoutthebelievesandwishesofmultipleagents.Z F*urthermoreit*isUUpGossibletorepresentdefaultsandstereotypGes.9Besidethebasicresoningfacilitiesforconsistencychecking,classi cation,andre-*alization,%MOTELprovidesanabGductiveinferencemechanism.]F*urthermoreitisable*toUUgiveexplanationsforitsinferences.DSKeywrordsqǍabGduction,:belief revision,defaultlogic,moGdallogic,terminologicallogic,multi-agent knowledgerepre- 38sentation,UUfunctionaldepGendencies썠:-iӍΖ9H"VG cmbx10HCon4tents?39"V cmbx101ReadingTtheUserMan9ual>3 381.1PredicateUUDesciptionsj b> cmmi10::::::::::::::::::::::::::::::::::::::::$31.1.1>CallUUArguments::::::::::::::::::::::::::::::::::::::::$31.2ArgumentUUTypGesf:::::::::::::::::::::::::::::::::::::::::::$4392En9vironments{g53Kno9wledgeTRepresentation9}8 383.1ConceptUUandRoleF*ormation"Ս::::::::::::::::::::::::::::::::::::$83.2MoGdalUUT*erminologicalAxiomsҍ::::::::::::::::::::::::::::::::::::$83.3MoGdalUUAssertionalAxiomsr::::::::::::::::::::::::::::::::::::::$103.4KnowledgeUURevision?r:::::::::::::::::::::::::::::::::::::::::$103.5Semantics2:::::::::::::::::::::::::::::::::::::::::::::::$113.6MoGdalUUAxiomsO::::::::::::::::::::::::::::::::::::::::::::$143.7KnowledgeUUBasesj.:::::::::::::::::::::::::::::::::::::::::::$14394Classi cationx164.1BuildingUUtheSemanticNetwork>:::::::::::::::::::::::::::::::::::$164.2RetrievqalUUcommandsforconcepts⍑::::::::::::::::::::::::::::::::::$164.3RetrievqalUUcommandsforroles::::::::::::::::::::::::::::::::::::$195RealizationTandRetriev\ralofobjects([216(In)consistencynr237F unctionalTDepQendencies=247.1De nitionUUandRevisionofF*uncionalDepGendencies7::::::::::::::::::::::::$247.2Deductionj:::::::::::::::::::::::::::::::::::::::::::::::$257.3AbGductionqh:::::::::::::::::::::::::::::::::::::::::::::::$278Examples+298.1MoGdalUUOperatorsՍ:::::::::::::::::::::::::::::::::::::::::::$298.2RoleUUclosureT::::::::::::::::::::::::::::::::::::::::::::::$298.3AbGductionqh:::::::::::::::::::::::::::::::::::::::::::::::$308.4Defaultsx::::::::::::::::::::::::::::::::::::::::::::::::$318.5EnumerationUUTypGesꍑ::::::::::::::::::::::::::::::::::::::::::$32AQuin9tusTPrologRelease3.1.1SpQeci cPredicatesc33BSICStusT2.1SpQeci cPredicatesTg34D1 ֠썠:-iӍ{-CSB-LITTERSTIn9terfaceF}3539DTheTCommonLisptoPR9OLOGinterface42 38D.1TheUUsyntaxofaPROLOGgoalinlisp:::::::::::::::::::::::::::::::$42D.2TheUUfunctions(start-prolog),(start-motel),(reset-prolog)and(kill-prolog).N:::$43D.3TheUUfunction(prolog-goal).[荑::::::::::::::::::::::::::::::::::::$43D.4TheUUfunction(prolog-next).:::::::::::::::::::::::::::::::::::$43D.5TheUUmacro(do-prolog)qQ:::::::::::::::::::::::::::::::::::::::$43D.6TheUUmacro(do-prolog-with-streams)15::::::::::::::::::::::::::::::$44EInstallingTMOTEL^ 45E.1Requirementsq\:::::::::::::::::::::::::::::::::::::::::::::$45E.2Installationҍ::::::::::::::::::::::::::::::::::::::::::::::$45D2.썠:-iӍ7I"Vp cmbx10IChapterF15 HReading theUserMan4ual;ԍ7"Vff cmbx101.1PredicateDesciptionsSPrediatesUUaredescribGedaccordingtothefollowinggrammar:z># <ϢPredicateUUDescription>%::=z[<AyCallPattern> 37z[Arguments:q< 8ArgumentTypGes>z[<AyInformalUUDescription> <ϢCallPattern>%::=z[<AyPredicateUUName>< <ϢCallArguments>%::=z[j< ': cmti10[(<CallArgument>^ٓRcmr7+j)]z[j< (<CallArgument>^+j) <ϢCallArgument>%::=z[[<MoGdeUUAnnotation><,]z[j< [<MoGdeUUAnnotation><]z[j< <>MoGdeUUAnnotation>< <ϢArgumentTypGes>%::=z[j< <>MetaUUV*ariable> s:q< 8TypGe>z[<AyArgumentTypGes> <ϢPredicateUUName>%::=z[<AyIdenti er> <ϢMetaUUV*ariable>%::=z[<AyIdenti er> <ϢTypGe>%::=z[<AyInformalUUDescription>wInUUthefollowingsubsections,wegivefurtherexplanationsforthepartsofapredicatedescription.,d0N cmbx121.1.1!HCallArgumentsAUUpredicatecanhaveUUavqaryingnumbGerUUofarguments.qIfweuse-[(<CallArgument>^+j)]wewanttodescribGethesituationthatthepredicatehaseithernoargumentsoratleastoneargumentswhich 38mustUUbGeenclosedinroundbrackets.qThenotation(<CallArgument>^+j)isusedifthepredicatehasatleastoneargumentwhichhastobGeenclosedinroundbrackets.G\IfthepredicatehasUUnoarguments,wesimplygivenocallarguments.IfUUacallargumentstakestheform[<MoGdeUUAnnotation><,]D39\썠:-iӍ{-thenSitisanoptionalargument,i.e.itmaybGeomitted,anditisfollowedbGeacommaunlessitisthelast 38argument,UUi.e.qthelastonebGeforetheclosingroundbracket.qIfweuse38h[<MoGdeUUAnnotation><]thenUUitisanoptionalargumentwhichisneverfollowedbyacomma.qThelastformis$<MoGdeUUAnnotation><denotingUUanon-optionalargument.ThemoGdeannotationsareusefultotellwetheranargumentisinputoroutputorbGoth.TheyalsodescribGeUUformallytheinstantiationpatterntothecall.F*ollowingUUisacompletedescriptionofthemoGdeannotationsyouwill ndinthisusermanual:8+AiInputGGargument.GThisargumentwillbGeinspectedbythepredicate,anda ectsthebehaviouroftheAipredicate,UUbutwillnotbGefurtherinstantiatedbythepredicate.8 O!cmsy7AiDeterministicD(outputargument.l Thisargumentisuni edwiththeoutputvqalueofthepredicate.l GivenAitheUUinputarguments,thevqalueofadeterministicoutputargumentisuniquelyde ned.8AiNondeterministic7loutputargument. Thisargumentisuni edwiththeoutputvqalueofthepredicate.AiTheipredicatemightbGeresatis able,)andmightthroughbacktrackinggeneratemorethanoneoutputAivqalueUUforthisargument.8+AiAnUUinputargumentthatdeterministicallymightbGefurtherinstantiatedbythepredicate.8+AiAn;inputargumentthatmightbGefurtherinstantiatedbythepredicate.^ThepredicatemightbGeresatis-Ai able,F-andBcmightthroughbacktrackinggeneratemorethanoneinstantiationpatternforthisargument.AllUUpredicatesofarityzeroaredeterminate."ޘ1.2Argumen=tTypuesSAfterthecallpattern,fwedeclarethetypGesoftheargumentsoGccurringinthecallpattern.rF*oreachmetavqariableUUinthecallpatternthecorrespGondingtypeisgiven.qTypesUUarenotformallyde ned.D4C8썠:-iӍ7IChapterF25 HEn4vironments538Anenvironmentisacontainerforaknowledgebase.KEachenvironmenthassomeuserprovidedenvironment 38name,kCsome3systemgeneratedinternalenvironmentname,kCandauserprovidedcomment. AlthoughitispGossibletohavetwodi erentenvironmentswiththesameenvironmentname,4theonegeneratedlaterwillbGe*notaccessiblebytheuser.SotheusershouldcarefullychoGosethenamesfortheenvironments.TheinternalRenvironmentnameisuniqueanddoGesnotdependontheenvironmentname.pThecommentcanbGeusedUUforanypurpGose,e.g.toremindtheuserwhattheknowledgebaseisabGout.There^isalways^acurr}'ent|environment.Whenever^apredicatehasanenvironmentnameasoptionalargument=andtheargumentisnotprovidedinacalltothepredicate,thesystemwillrefertothecurrentenvironment.qAtUUthebGeginning,thereexistsanemptyenvironmentnamedinitial.W*eUUprovidethefollowingpredicatesforhandlingenvironments:clearEnvironment[(G+ EnvName2 )Arguments:OEnvName1aenvironmentUUname 37OEnvName2aenvironmentUUnamečcreatesYwanewenvironmentYwEnvName2andcopiestheknowledgebaseinEnvName1toEnvName2.environment(G+ cEnvName,GÒEnvId,GComment )Arguments:OEnvNameenvironmentUUname 37OEnvIdinternalUUenvironmentnameOCommentstring&Mretrievestheinternalenvironmentidenti erEnvIdandtheassoGciatedcommentCommentfora 38givenUUenvironmentnameEnvName.D5L썠:-iӍ{-getCurrentEnvironment(G@EnvName )38Arguments:OEnvNameenvironmentUUname 38instantiatesUUEnvNamewiththeidenti erforthecurrentenvironment.38initEnvironment[(G+#EnvName )]Arguments:OEnvNameenvironmentUUnameprovides2theenvironmentEnvNamewiththeinitialdatastructures._fThecurrentenvironmentisinitializedUUifnoEnvNameisgiven.38initialiseremoves}allenvironments,'initialises}theemptyenvironmentinitial,'andmakesinitialthecurrentUUenvironment.38initializeIdenticalUUtoinitialize.qF*orthoseofuswhopreferthealternativespGelling.38loadEnvironment(G+#FileName[,(EnvName] )Arguments:OFileName leUUname 37OEnvNameenvironmentUUnamečloads1theinternalrepresentationofanenvironmentEnvNamefroma lenamedFileName.Z\IfnoHEnvNameisgiven,theenviromentnamestoredinthe leFileNamewillbGetaken.IftherealreadyUUexistsanenvironmentUUEnvName,itwillbGeremoved.38makeEnvironment(G+#EnvName,G+>Comment )Arguments:OEnvNameenvironmentUUname 37OCommentstringčcreatesanewenvironmentwithidenti erEnvNameandassoGciatedcommentComment.ThisnewUUenvironmentbGecomesthecurrentenvironment.38removeEnvironment(G+ cEnvName )Arguments:OEnvNameenvironmentUUnameremovess\theknowledgebaseandtheenvironmentEnvName.IfEnvNamewasthecurrentenvi-ronmentUUtheninitialenvironmentbGecomesthecurrentenvironment.38renameEnvironment(G+#EnvName1,G+>EnvName2 )Arguments:OEnvNameenvironmentUUnamerenamesUUenvironmentG+ xEnvName1toG+EnvName2.38saveEnvironment([G+#EnvName,]FileName )Arguments:OEnvNameenvironmentUUname 37OFileName leUUnamečsavesUUtheinternalrepresentationofenvironmentEnvNameintoa lenamedFileName.D6XT썠:-iӍ{-showEnvironment[(G+#EnvName )]38Arguments:OEnvNameenvironmentUUname 38displaysJ_theknowledgebaseinenvironmentEnvName,Li.e.theterminologicalaxioms,theasser-tionalUUaxioms,andthemoGdalaxioms.38switchToEnvironment(G+#EnvName )Arguments:OEnvNameenvironmentUUnamemakesUUEnvNamethecurrentenvironment(ifanenvironmentwiththisidenti erexists).D7bˠ썠:-iӍ7IChapterF35 HKno4wledge Representation;ԍ3.1ConceptandRoleFormationSAssumeuthatwehavefourdisjointalphabGetsofsymbGols,𞍍[and([R1|s;:::;Rl])(roleUUconjunction) 37[inverse(R)(roleUUinversion)[restr(R,C)(roleUUrestriction)!>areUUroleterms."ޘ3.2MoudalTerminologicalAxiomsA mo}'dal=context-isa(pGossiblyempty)listoftermsoftheformb(O,a),vaisanagentnameandAisaconceptname.h@ThesetofallmodalcontextsisdenotedUUMCW.D8 e8썠:-iӍ{-So-calledAmo}'dalmterminologicalaxiomsAareusedtointroGducenamesformodalconcepttermsandrole 38terms.WA nite setofsuchaxiomssatisfyingcertainrestrictionsiscalledaterminolo}'gy(TBox).WTherearethreeUUdi erentwaysofintroGducingnewconcepts(respectivelyroles)intoaterminology*.ByUUthemo}'dalterminologicalaxiomsdefprimconcept([G+#EnvName,][G+M,]G+>A )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOAconceptUUname44defprimrole([G+#EnvName,][G+M,]G+>P )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOProleUUname4Mnew+conceptandrolenamesareintroGducedinenvironmentEnvNameandmoGdalcontextMwithoutrestrict- 38ing~theirinterpretation.LIfnoEnvNameisgiven,thecurrentenvironmentwillbGetaken.LIfnoMbisprovided,theUUemptymoGdalcontextwillbGeused.TheUUmoGdalterminologicalaxiomsdefprimconcept([G+#EnvName,][G+M,]G+>A,G+C )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOAconceptUUnameOCconceptUUtermBkdefprimrole([G+#EnvName,][G+M]G+>P,G+R )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOProleUUnameORroleUUtermA2impGose4EnecessaryconditionsontheinterpretationoftheintroGducedconceptandrolenamesinenvironment 38EnvNameUUandmoGdalcontextM.Finally*,UUonecanimpGosenecessaryandsucientconditionsbythemoGdalterminologicalaxiomsdefconcept([G+#EnvName,][G+M,]G+>A,G+C )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOAconceptUUnameOCconceptUUtermdefrole([G+#EnvName,][G+M,]G+>P,G+R )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOProleUUnameORroleUUtermD9 pҠ썠:-iӍ{-OnecanimpGoseanadditionalrestrictionontheinterpretationofalreadyintroGducedconceptnamesby 38theUUterminologicalaxiomdefdisjoint([G+#EnvName,][G+M,]G+>CL )ɍArguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOCLlistUUofconceptnames/yUwhichUUdeclaresthemutaldisjointnessofallconceptsinthegivenlistofconceptnames."-3.3MoudalAssertionalAxiomsSAssertionalUUaxiomshaveUUtheformassertEff&fǫind([G+#EnvName,][G+M,]G+>X,G+A )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameOAconceptUUname=:ōassertEff&fǫind([G+#EnvName,][G+M,]G+>X,G+Y,G+P )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameOYob8jectUUnameOProleUUnameIÍThe@ rstonede nesX@tobGeanelementofconceptAinenvironment@ EnvNameandmoGdalcontextM.ThesecondUUonede nesthepair(X,Y)tobGeanelementoftheroleP.AUU nitesetsetofsuchaxiomsiscalledworlddescription."-3.4Kno=wledgeRevisionSMOTEL has Dpredicatesforrevisingtheterminologyandtheworlddescriptionofaknowledgebase.ThefollowingOpredicatesallowstodeleteaconcept,Ni.e.afterdeletingtheconceptAitisnolongerpGossibletoproveUUthatsomeob8jectaisanelementofAunlessitisexplicitlystatedintheworlddescription.undefconcept(G+#EnvName,M,A )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOAconceptUUname&MdeletesUUconceptAinenvironmentUUEnvNameandmoGdalcontextM.^The_followingpredicatesdeletetherelationshipbGetweenaconceptnameandaconcepttermpreviouslyde nedUUbysometerminologicalaxiom.undefconcept(G+#EnvName,G+>M,G+A,G+CT )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOAconceptUUnameOCTconceptUUterm32deletes&Jtheaxiomde ningtheequivqalenceofA&andCTinenvironment&JEnvNameandmoGdalcontextUUM.Ļ10 |썠:-iӍ{-undefprimconcept(G+#EnvName,M,A,CT )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOAconceptUUnameOCTconceptUUterm32deletestheaxiomde ningtheinclusionofAinCTinenvironmentEnvNameandmoGdalcontext 38M.38T*o'(revisetheworlddescriptiononecaneitherdeletethemembGershipofsomeob8jectainaconceptAortheUUmembGershipofapair(a;b)intherolePc.deleteEff&fǫind(G+#EnvName,G+>M,G+X,A )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameOAconceptUUname32deletesUUtheassertionalaxiomde ningthemembGershipofXinA.38deleteEff&fǫind([G+#EnvName,][G+M,]G+>X,G+Y,G+P )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameOYob8jectUUnameOProleUUnameABdeletesUUtheassertionalaxiomde ningthemembGershipofthepair(X,Y)inroleP.0ޘ3.5Seman=ticsSSuppGoseUU=(CW;R;M;O)UUisaknowledgesignature.De nitionT1(-Structures)As^usualwede nea-structur}'easapair(DG;I)whichconsistsofadomainD{andaninterpretationfunctionIwhichHmapstheindividualob8jectstoelementsofDG,JprimitiveconceptstosubsetsofD9andtheprimitiverolesUUtosubsetsofD8DG.]438De nitionT2(F ramesandIn9terpretations)ByUUaframeFZweunderstandanypair(W 6;<)whereWisUUanon-emptyset(ofworlds).38<=Cu cmex10CU m'O72M;a2A74<^abO 3wherethe<^abO:'sarebinaryrelationonWl/,theso-calledac}'cessibilityrelationsbGetweenUUworlds.ByUUa-interpretation=basedonFZweunderstandanytuple(D;F Z;=lo7ch;)whereD[denotesUUthecommondomainofall-structuresintherangeof=lo7c.38UUdenotestheactualworld(thecurrentsituation)F isUUaframe=lo7c&mapsUUworldsto-structureswithcommondomainDwhichinterpretagents'namesequally*.Ļ11 썠:-iӍ{-d438De nitionT3(In9terpretationofT erms) 38LetLY==(D;F Z;=lo7ch;)bGea-interpretationandlet=lo7c ()=(DG;I).nW*ede netheinterpretationoftermsinductivelyUUovertheirstructure:^'7=(A);=YI(A)ifUUAisaconceptname 377=(Pc);=YI(Pc)ifUUPisarolename7=(and([C1|s;:::;Cnq~])S2);=Y=(C1|s)8\:::g\=(Cnq~)7=(or([C1|s;:::;Cnq~])M);=Y=(C1|s)8[:::g[=(Cnq~)7=(not(C)");=YDn8=(C)7=(all(R,C)/I);=Yfd2D je2=(C)UUforallewith(d;e)2=(R)xEXg7=(some(R,C)4HF);=Yfd2D je2=(C)UUforsomeewith(d;e)2=(R)pg7=(b(OG,a,C)/M);=Yfd2D jd2=[](C)UUforallwith<^abO:(;)et%ğճ(ff{y =qͤƄ 37ff͟ :Name 37ffTTmAxiomUUSchema.Ƅ 37ff IPropGertyG7Ƅ 37ff\,ff{y񡍍ͤƄ 37ff$ :d 37ff>b(OG,a,C)qqd(OG,a,C)KƄ 37ff8x9y"<^abO:(x;y[)<*|Ƅ 37ff 37ͤƄ 37ff$ :t 37ffRb(OG,a,C)C7᤟Ƅ 37ff58x<^abO:(x;x)AYƄ 37ffͤƄ 37ffK :b 37ff>CI~b(OG,a,d(O,a,C))s Ƅ 37ff18x;y"<^abO:(x;y[))<^abO(y[;x)"UƄ 37ffͤƄ 37ff] :4 37ff+G b(OG,a,C)][b(OG,a,b(O,a,C))_RƄ 37ffʨ8x;y[;z7<^abO:(x;y)8^<^abO:(y;zp)Z_)<^abO:(x;zp)͟Ƅ 37ffͤƄ 37ff] :5 37ff+G d(OG,a,C)][b(OG,a,d(O,a,C))_RƄ 37ffʨ8x;y[;z7<^abO:(x;y)8^<^abO:(x;zp)[_)<^abO:(y;zp)͟Ƅ 37ffff{y񎎎5TheNuserspGeci esthepropertiesoftheaccessibilityrelationusingthepredicatemodalAxioms.Atthemoment,theconjunctionsd45,d4,d5,andtareallowed.lTheidenti erskd45,kd4,kd5,andkttogetherformUUtheargumenttypGeofKripkeclasses.modalAxioms([+EnvName,]+Class,+O,+a )38Arguments:OEnvNameenvironmentUUname 37OClassKripkeUUclassOOmoGdalUUoperatorOaagentUUname32assertsctheinternalrepresentationofthepropGertiesde nedbythegivenKripkeclassClassfortheUUaccessibilityrelationofthemoGdaloperatorOandagenta.38modalAxioms([+EnvName,]+Class,+O,concept(+A) )Arguments:OEnvNameenvironmentUUname 37OClassKripkeUUclassOOmoGdalUUoperatorOAconceptUUname32assertsctheinternalrepresentationofthepropGertiesde nedbythegivenKripkeclassClassfortheUUaccessibilityrelationofthemoGdaloperatorOforeveryagentinconceptA.0ޘ3.7Kno=wledgeBasesSAtripleconsistingofaterminology*,aworlddescription,andmoGdalaxiomsisaknowle}'dgebase.>SItispossibletoUUloadandtosaveUUknowledgebasesusingthefollowingpredicates.saveKB([G+#EnvName,]G+>FileName )Arguments:OEnvNameenvironmentUUname 37OFileName leUUnamečsavestheterminological,'assertional,andmoGdalaxiomsoftheknowledgebaseinenvironmentEnvNameUUintothe leFileName.38loadKB(G+#FileName,GEnvName )Arguments:OFileName leUUname 37OEnvNameenvironmentUUnamečloads@theterminological,assertional,and@moGdalaxiomsfrom leFileName,turnsthemintotheirinternalUUrepresentationinenvironmentEnvName.Ļ143썠:-iӍ{-getKB([G+#EnvName],GAxioms )38Arguments:OEnvNameenvironmentUUname 37OAxiomslistUUofaxiomsčAxiomsOisinstantiatedwithalistofallterminological,assertional,andOmoGdalaxiomsinenviron- 38mentUUEnvName.Ļ15DZ썠:-iӍ7IChapterF45 HClassi cation;ԍ4.1BuildingtheSeman=ticNetworkSSuppGoseEC;aandDbareconceptsinamodalcontextM.ThenC;asubsumesDbifwecanprovefromthe 38assumption {thataskolemconstantaisanelementofDRthatisalsoanelementofC.8ThepredicatefordoingUUthisinMOTELissubsumes([G+#EnvName,][G+M,]G+>C,G+D )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOCconceptUUnameODcoGceptUUname32succeedskCifCk=andDareknownconceptsinenvironmentEnvNameandmoGdalcontextMk=andCsubsumesUUD.38Let>C(E;M)bGethesetofallconceptsinenvironment>EandmodalcontextM.W*ecancomputethesubsumptionUUrelationonC(M),calledsemanticnetworkofM,UUusingthepredicateclassify[([G+#EnvName,][G+M] )]Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextčcomputesUUthesemanticnetworkinmoGdalcontextM.0ޘ4.2Retriev{alcommandsforconceptsSAftertheclassi cationisdone,onecanusethefollowingcommandstoretrieveinformationsabGoutthesemantikUUnetwork:showHierarchy(G+#EnvName,G+>M,G+T;yp}'e )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOT;yp}'eeitherUUconceptsorroles&Mdisplaysϖtheconcepthierarchy*,.&i.e.thesemanticnetworkinthemoGdalcontextM5ifT;yp}'eisconceptsUUandtherolehierarchyUUinthemoGdalcontextMifT;yp}'eisroles.Ļ16b썠:-iӍ{-getHierarchy(G+#EnvName,G+>M,G+T;yp}'e,GH )gArguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOT;yp}'eeitherUUconceptsorrolesOHinternalUUrepresentationofthesubsumptionhierarchy32instantiateshHAwiththeinternalrepresentationoftheconcepthierarchy*,ؘi.e.thesemanticnetwork 38innMthemoGdalcontextMnifT;yp}'eisconceptsandwiththeinternalrepresentationoftherolehierarchyUUinthemoGdalcontextMifT;yp}'eisroles.>getDirectSuperConcepts(G+#EnvName,G+>M,G+Conc}'ept,GCL )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOConc}'eptconceptUUnameOCLlistUUofconceptnames32CLUUisthelistofallconceptnameswhicharedirectsupGerconceptsofConc}'ept.getAllSuperConcepts(G+#EnvName,G+>M,G+Conc}'ept,GCL )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOConc}'eptconceptUUnameOCLlistUUofconceptnames32CLUUisthelistofallconceptnameswhicharesupGerconceptsofConc}'ept.getDirectSubConcepts(G+#EnvName,G+>M,G+Conc}'ept,GCL )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOConc}'eptconceptUUnameOCLlistUUofconceptnamesOCListhelistofallconceptnameswhichare32directUUsubconceptsofConc}'ept.getAllSubConcepts(G+#EnvName,G+>M,G+Conc}'ept,GCL )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOConc}'eptconceptUUnameOCLlistUUofconceptnames32CLUUisthelistofallconceptnameswhicharesubconceptsofConc}'ept.getConcepts(G+#EnvName,G+>M,GCL )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOCLlistUUofconceptnames&MCLUUisthelistofallconceptnamesinthesubsumptionhierarchy*.testDirectSuperConcept(G+#EnvName,G+>M,G+Conc}'ept1,G+Concept2,GConcept )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOConc}'ept1conceptUUnameOConc}'ept2conceptUUnameOConc}'eptconceptUUnameĻ17썠:-iӍ{-Conc}'eptbisConcept1i Concept1isadirectsupGerconceptofConcept2orConceptisConcept2 38i UUConc}'ept2isadirectsupGerconceptofConcept1otherwisethepredicatefails.38testDirectSubConcept(G+#EnvName,G+>M,G+Conc}'ept1,G+Concept2,GConcept )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOConc}'ept1conceptUUnameOConc}'ept2conceptUUnameOConc}'eptconceptUUname@iConc}'eptisConcept1i Concept1isadirectsubconceptofConcept2orConceptisConcept2i Conc}'ept2UUisadirectsubconceptofConcept1otherwisethepredicatefails.testSuperConcept(G+#EnvName,G+>M,G+Conc}'ept1,G+Concept2,GConcept )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOConc}'ept1conceptUUnameOConc}'ept2conceptUUnameOConc}'eptconceptUUname@iConc}'eptbisConcept1i Concept1isadirectsupGerconceptofConcept2orConceptisConcept2i UUConc}'ept2isadirectsupGerconceptofConcept1otherwisethepredicatefails.testSubConcept(G+#EnvName,G+>M,G+Conc}'ept1,G+Concept2,GConcept )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOConc}'ept1conceptUUnameOConc}'ept2conceptUUnameOConc}'eptconceptUUname@iConc}'eptbisConcept1i Concept1isadirectsupGerconceptofConcept2orConceptisConcept2i UUConc}'ept2isadirectsupGerconceptofConcept1otherwisethepredicatefails.getCommonSuperConcepts(G+#EnvName,G+>M,G+CL1,GCL2 )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOCL1listUUofconceptnamesOCL2listUUofconceptnames32CL2UUisthelistofallconceptnamessubsumingallconceptsinCL1.getCommonSubConcepts(G+#EnvName,G+>M,G+CL1,GCL2 )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOCL1listUUofconceptnamesOCL2listUUofconceptnames32CL2UUisthelistofallconceptnameswhicharesubsumedbyallconceptsinCL1.Ļ18썠:-iӍ{-4.3Retriev{alcommandsforrolesSgetDirectFatherRoles(G+#EnvName,G+>M,G+R}'ole,GRL )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOR}'oleroleUUnameORLlistUUofrolenames32RLUUisthelistofallrolenameswhicharedirectfatherrolesofR}'ole.38getAllFatherRoles(G+#EnvName,G+>M,G+R}'ole,GRL )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOR}'oleroleUUnameORLlistUUofrolenamesRLUUisthelistofallrolenameswhicharefatherrolesofR}'ole.38getDirectSonRoles(G+#EnvName,G+>M,G+R}'ole,GRL )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOR}'oleroleUUnameORLlistUUofrolenamesRLUUisthelistofallrolenameswhicharedirectsonrolesofR}'ole.38getAllSonRoles(G+#EnvName,G+>M,G+R}'ole,GRL )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOR}'oleroleUUnameORLlistUUofrolenamesRLUUisthelistofallrolenameswhicharesonrolesofR}'ole.38getRoles(G+#EnvName,G+>M,GRL )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextORLlistUUofrolenames&MRLUUisthelistofallrolenamesinthesubsumptionhierarchy*.testDirectFatherRole(G+#EnvName,G+>M,G+R}'ole1,G+Role2,GRole )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOR}'ole1roleUUnameOR}'ole2roleUUnameOR}'oleroleUUname@iR}'olehkisRole1i Role1isadirectfatherroleofRole2orRoleisRole2i Role2isadirectfather 38roleUUofR}'ole1otherwisethepredicatefailsĻ199썠:-iӍ{-testDirectSonRole(G+#EnvName,G+>M,G+R}'ole1,G+Role2,GRole )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOR}'ole1roleUUnameOR}'ole2roleUUnameOR}'oleroleUUname@iR}'ole_isRole1i Role1isadirectsonroleofRole2orRoleisRole2i Role2isadirectsonrole 38ofUUR}'ole1otherwisethepredicatefails38testFatherRole(G+#EnvName,G+>M,G+R}'ole1,G+Role2,GRole )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOR}'ole1roleUUnameOR}'ole2roleUUnameOR}'oleroleUUnameR}'olehkisRole1i Role1isadirectfatherroleofRole2orRoleisRole2i Role2isadirectfather 38roleUUofR}'ole1otherwisethepredicatefails38testSonRole(G+#EnvName,G+>M,G+R}'ole1,G+Role2,GRole )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOR}'ole1roleUUnameOR}'ole2roleUUnameOR}'oleroleUUnameR}'ole_isRole1i Role1isadirectsonroleofRole2orRoleisRole2i Role2isadirectsonrole 38ofUUR}'ole1otherwisethepredicatefails38getCommonFatherRoles(G+#EnvName,G+>M,G+RL1,GRL2 )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextORL1listUUofrolenamesORL2listUUofrolenames32RL2UUisthelistofallrolenamessubsumingallrolesinRL1.getCommonSonRoles(G+#EnvName,G+>M,G+RL1,GRL2 )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextORL1listUUofrolenamesORL2listUUofrolenames32RL2UUisthelistofallrolenameswhicharesubsumedbyallrolesinRL1.Ļ20Ӡ썠:-iӍ7IChapterF55 HRealization andRetrievialofobjects538Ther}'ealizationproblemisto ndforanob8jectaallconceptsC8suchthataisaninstanceofC.D_Theretrieval 38pr}'oblemyBisto ndforaconceptC0^allob8jectsasuchthataisaninstanceofC.ݍInMOTELy8bGothproblemsareUUsolvedusingthededuce-command.deduce(G+ cEnvName,G+?M,elementOf(G+X,G+?CT),G+Exp )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameOCTconceptUUtermOExpexplanation@iF*orBagivenob8jectnameXallconceptnamesCTsuchthatXisaninstanceofCTwillbGeenumerated.Expصprovidessomeexplanationwhythisistrue.F*oragivenconcepttermCTؓallob8jectnamesXsuchthatXisaninstanceofCTwillbGeenumerated.TheconcepttermCTcan]>bGeeiteravqariableoraconcepttermcontainingrolenamesbutnotgeneralroletermsonly*.AgainIExpprovidessomeexplanationwhythisistrue.MnIfM-isnotinstantiated,itwillenumerateallmoGdalcontextssuchthatXisaninstanceofC.Finally*,ifEnvNameisavqariable,itwillbGeinstantiatedUUwithanenvironmentsuchthatXisaninstanceofCinmoGdalcontextM.38realize(G+#EnvName,G+>M,G+X,GCL )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameOCLlistUUofconceptnamesOExpexplanation@pZtryUUit.getAllObjects(G+#EnvName,G+>M,GOL )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOOLlistUUofob8jectnames&MOListhelistofnamesofallob8jectsknowntoexistinenvironmentEnvNameandmoGdalcontext 38M.T*oUUgetinformationabGoutroleswehavethepredicateĻ21)썠:-iӍ{-deduce(G+ cEnvName,G+?M,roleFiller(G+X,G+?R,GL,GN),-Exp )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameORroleUUnameOLlistUUofob8jectnamesONnumbGerOExpexplanation[׍getszallob8jectsintherangeofroleRzforargumentXinenvironmentzEnvNameandmoGdalcontext 38M. 'L isinstantiatedwiththelistofalltheseob8jectsandNisthenumbGer 'ofelementsinthislist.38ItSispGossibletouseabductionto ndasetofhypothesises,i.e.terminologicalaxioms,suchthatsomeob8jectUUXisanelementofaconceptCifthesehypGothesisesaretrue.abduce(G+ cEnvName,G+?M,*H,elementOf(G+X,G+?C),G+Exp )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameOCconceptUUnameO*HsetUUofhypGothesisesOExpexplanationM砍F*or[agivenob8jectnameXAallconceptsCsuchthatXisaninstanceofCusingtheadditionalset+ofhypGothesiseswillbeenumerated.HExpprovidessomeexplanationwhythisistrue.HF*oragivenȇconceptnameCiallob8jectnamesXsuchthatXisaninstanceofCwillbGeenumerated.AgainIExpprovidessomeexplanationwhythisistrue.MnIfM-isnotinstantiated,itwillenumerateallmoGdalcontextssuchthatXisaninstanceofC.Finally*,ifEnvNameisavqariable,itwillbGeinstantiatedUUwithanenvironmentsuchthatXisaninstanceofCinmoGdalcontextM.Ļ22 R썠:-iӍ7IChapterF65 H(In)consistency538W*e4callaknowledgebaseinconsistent,ifwecanproveformsomeob8jectnameXmandsomeconceptname 38AUUthatX7isanelementofAandofnot(()!xA).qOtherwisetheknowledgebaseisconsistent.consistent[([G+#EnvName,][G+M] )]38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextčsucceedsUUiftheenvironmentUUEnvNameandmoGdalcontextMisconsistent.38inconsistent[([G+#EnvName,][G+M] )]Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextsucceedsUUiftheenvironmentUUEnvNameandmoGdalcontextMisinconsistent.Ļ23썠:-iӍ7IChapterF75 HFunctional Depvendencies538In*&thischapterwedescribGethecomponentofMOTEL*forspecifyingandreasoningaboutfunctionaldepen- 38denciesUUamongroles."7.1De nitionandRevisionofFuncionalDepuendenciesSF*unctionalUUdepGendenciesaredescribedusingfunctionaldependencyliteralsofthefollowingformĵinfl(G+#X,G+>Y,G+W ) 37posInfl(G+#X,G+>Y )negInfl(G+#X,G+>Y )noInfl(G+#X,G+>Y )change(G+#X,G+>W )increase(G+#X )decrease(G+#X )b:XandYdenoteroles/attributesandWdenotestheweightofXin uencingYorWdenotestheweightofchangeIofanattribute.mposInflisassignedtheweight1.0,L%negInfltheweight-1.0andnoInfltheweight0.0.qTheUUweightsforincrease,decreaseandnoChangeare1.0,-1.0and0.0,respGectively*.ThecommanddefcanbGeusedtode neafunctionaldependency*,thecommandundefcanbeusedtoremoveUUit.def([G+#EnvName],[G+MS],G+>F;act )Arguments:OEnvNameenvironmentUUname 37OMSmoGdalUUcontextOF;actfunctionalUUdepGendencyliteral&MThishpredicateisusedtoupGdatetheknowledgebaseofinformationaboutthefunctionalde-pGendencies.kTheCde nitionofmultiplein uencesbetweenCattributesandmultiplechangesonanattributeUUareprevented. sundef([G+#EnvName],[G+MS],G+?F;act )Arguments:OEnvNameenvironmentUUname 37OMSmoGdalUUcontextOF;actfunctionalUUdepGendencyliteral&MretractsUUallfactsmatchingF*act.With]thefollowingpredicatesitispGossibletodisplayinformationabGoutthefunctionaldependencieswhich 38areUUcurrentlyde ned.Ļ24썠:-iӍ{-showFDW([G+ cEnv] )38Arguments:OEnvl~environmentUUname(internalrepresentation) 38displaysUUtheuserde nedfunctionaldepGendenciesintheknowledgebase.38showInfl(G+ cEnv )Arguments:OEnvl~environmentUUname(internalrepresentation)displaysUUtheuserde nedin uencerelationshipsintheknowledgebase.38showChange(G+ cEnv )Arguments:OEnvl~environmentUUname(internalrepresentation)displaysUUtheuserde nedchangesintheknowledgebase.38showFD([G+ cEnv] )Arguments:OEnvl~environmentUUname(internalrepresentation)displays^theuserde nedfunctionaldepGendenciesintheknowledgebase.DSimilartoshowFDW,buttheUUdefaultreprsentationischosen.0ޘ7.2DeductionSdeduce([G+#EnvName],[G+MS],G+?Info,[G@E] )Arguments:OEnvNameenvironmentUUname 37OMSmoGdalUUcontextOInfoaUUliteraloftheappropriatekind,seedescriptionbGelowOEexplanationsUU(notasyetimplemented)32SucceedsifInfocanbGeinferredbydeduction. HereisashortdescriptionofInfothatcanbeinferred.38infl(G+ cX,G+?Y,G+W )7$XM" attribute/roleUUname 377$YM" attribute/roleUUname7$WM" listUUofweightsUUweight,avqalue&M+$computesDmthecumulativeDmweightWDiofallthein uencelinksbGetweentheattributesXDiand+$Y.simultInfl(G+ cXs,G+?Y,G+W )7$XsNlistUUofattributes/rolenames 377$YNattribute/roleUUname7$WNlistUUofweightsUUweight,avqalue&4+$checksvifthelistXsiswell-de ned(thatis,,~isXsaSETJofindepGendentattributes)and+$computesI thetotalweightI WHoftheattributesinthelistXssimultaneouslyin uencing+$attributeUUY.leastInfl(G+ cX,G+?Y )7$XJattribute/roleUUname 377$YJattribute/roleUUnameč+$succeedsUUifXisaleastattributein uencingY.Ļ25 썠:-iӍ{-leastInfls(G+ cXs,G+?Y ) 387$XsNlistUUofattributes/rolenames 377$YNattribute/roleUUnameč+$collectsUUtheleastattributesin uencingYinXs.38greatestInfl(G+ cX,G+?Y )7$XJattribute/roleUUname 377$YJattribute/roleUUname+$succeedsUUifYisagreatestattributein uencedbyX.38greatestInfls(G+ cXs,G+?Y )7$XNattribute/roleUUname 377$YsNlistUUofattributes/rolenames+$collectsUUthegreatestattributesin uencedbyXinYs.38maxPosInfl(G+ cX,G+?Y,G+Wmax )7$X_attribute/roleUUname 377$Y_attribute/roleUUname7$Wmax_weight,UUavqalue&M+$succeedsUUifWmaxisthegreatestweightUUwithwhichXin uencesYpGositively*.maxNegInfl(G+ cX,G+?Y,G+WMin )7$X^attribute/roleUUname 377$Y^attribute/roleUUname7$WMin^aUUvqalue&M+$succeedsUUifWMinisthegreatestweightUUwithwhichXin uencesYnegatively*.change(G+ cY,G+?W )7$YQ#attribute/roleUUname 377$WyQ#weightUUofchangeofYč+$determinesUUthechangeinY.posInfl(G+ cX,G+?Y )7$XJattribute/roleUUname 377$YJattribute/roleUUnameč+$succeedsUUifattributeXin uencesattributeYpGositively*.negInfl(G+ cX,G+?Y )7$XJattribute/roleUUname 377$YJattribute/roleUUnameč+$succeedsUUifattributeXin uencesattributeYnegatively*.noInfl(G+ cX,G+?Y )7$XJattribute/roleUUname 377$YJattribute/roleUUnameč+$succeedsUUifthecumulativeUUin uencebGetweenUUtheattributesXandYis0.0.simultPosInfl(G+ cXs,G+?Y )7$XsNlistUUofattributes/rolenames 377$YNattribute/roleUUnameč+$succeedsIifthesimultaneousin uenceoftheattributesinthelistXsontheattributeYIis+$pGositive.simultNegInfl(G+ cXs,G+?Y )7$XsNlistUUofattributes/rolenames 377$YNattribute/roleUUnameč+$succeedsIifthesimultaneousin uenceoftheattributesinthelistXsontheattributeYIis+$pGositive.Ļ26+썠:-iӍ{-simultNoInfl(G+ cXs,G+?Y ) 387$XsNlistUUofattributes/rolenames 377$YNattribute/roleUUnameč+$succeedsIifthesimultaneousin uenceoftheattributesinthelistXsontheattributeYIis+$pGositive.38increase(G+ cX )7$YJattribute/roleUUname+$succeedsUUifattributeYincreases.decrease(G+ cX )7$YJattribute/roleUUname+$succeedsUUifattributeYdecreases.noChange(G+ cX )7$YJattribute/roleUUname+$succeedsUUifattributeYdoGesnotchange(i.e.qthereisneitheranincreasenoradecrease).0ޘ7.3AbuductionSTheUUstandardqueryforabGductionis38abduce([G+#EnvName],[G+MS],G+?H,G+C,E )whereZoEnvNamedenotesanenvironmentZoname,[MSZnamoGdalcontextandEalistofexplanations.HandC 38repGectively-denoteahypGothesisanditsconsequent.[InthiscompGonentofMOTELHand-CcanalsobGelistsofhypGotheses,4respectively*,4consequents.DThedi erentpGossibilitiesarelistedbelow.DExplanationsarenotas(NyetgeneratedforinferencewithfunctionaldepGendencies.bProvisionwasmadeforfutureimplementation.abduce([G+#EnvName],[G+MS],G+?change(G+ cX,(G+Wx ),G+change(G+ cY,(G+Wy ),[])38Arguments:OEnvNameenvironmentUUname 37OMSmoGdalUUcontextOXattribute/roleUUnameOWxweightUUofchangeofXOYattribute/roleUUnameOWyweightUUofchangeofYM砍SucceedsUUif,underthehypGothesisofchange(G+ cX,G+?Wx ),change(G+Y,G+?Wy )follows.38abduce([G+#EnvName],[G+MS],G+?Hyp}'othesis,G+Conse}'quent,[] )Arguments:OEnvName?environmentUUname 37OMS?moGdalUUcontextOHyp}'othesis?aUUliteralofappropriatekindOConse}'quent?aUUliteralofappropriatekind32Succeeds@AifConse}'quentfollowsunderthehypGothesisHyp}'othesis.jHypothesis@AandConse}'quentare 38ofUUtheform:38'increase(G+ cX ),UUdecrease(G+X),UUnoChange(G+X).Ļ277x썠:-iӍ{-abduce([G+#EnvName],[G+MS],G+>Changes,G+?change(G+ cY,(G+Wy ),[])38Arguments:OEnvNameenvironmentUUname 37OMSmoGdalUUcontextOChangesaUUlistofliteralsoftheformchange(G+ cX,G+>W )OYattribute/roleUUnameOWyweightUUofchangeofYM砍SucceedsUUifchange(G+ cY,G+?W )followsunderthehypGothesesofChanges.38abduce([G+#EnvName],[G+MS],G+?Hyp}'otheses,G+Conse}'quent,[] )Arguments:OEnvName?environmentUUname 37OMS?moGdalUUcontextOHyp}'otheses?aUUlistofliteralsoftheappropriatekindOConse}'quent?aUUliteraloftheappropriatekind32SucceedsUUifConse}'quentfollowsunderthehypGothesesHyp}'otheses.qHypothesesUUisalistof38'increase(G+ cX ),UUdecrease(G+X),UUnoChange(G+X)literalsUUandConse}'quentisoneoftheseliterals.abduce([G+#EnvName],[G+MS],G+?Change,G+Changes,[] )38Arguments:OEnvNameenvironmentUUname 37OMSmoGdalUUcontextOChangeaUUliteraloftheformchange(G+ cX,G+?W )OChangesaUUlistofliteralsoftheformchange(G+ cX,G+?W )M砍SucceedsUUifChangesholdunderthehypGothesisthatChangeholds.abduce([G+#EnvName],[G+MS],G+?Hyp}'othesis,G+Conse}'quents,[] )Arguments:OEnvNameVenvironmentUUname 37OMSVmoGdalUUcontextOHyp}'othesisVaUUliteraloftheformVincrease(G+ cX )Vdecrease(G+ cX )VnoChange(G+ cX )OConse}'quentsVaUUlistofliteralsofthisform[׍SucceedsUUifConse}'quentsfollowunderthehypGothesisHyp}'othesis.Ļ28CJ썠:-iӍ7IChapterF85 HExamples;ԍ8.1MoudalOperatorsSLet's 2suppGosethatwehavesomeagenta1inourworld.]W*ecanformtheconceptcontainingeverything 38thata1bGelievestobeacarusingtheterminologicalaxiom(2)inthefollowingknowledgebase.9W*ecallthisconceptc1.ZF*urthermorewespGecifythata1believesthatc1istheconceptcontainingeverythinghebGelievestobeacarusingaxiom(4)._Andweassertthatprovqabilityforthebelieveofa1islikethemoGdallogicUUkd45.That)impliesthata1isabletopGerformpositiveintrospGection,1i.e.hebelieveswhathebelieves.c Supposeaudiisanelementofc1(axiom(6)).BIfc3istheconceptcontainingeverythingthata1bGelievestobGeanelementofc1(axiom(3))anda1bGelievesthatthisequivqalenceistrue,ܘthenaudimustbGeanelementofc3.#|k(1)?modalAxioms(kd45,believe,a1).#|k(2)?defconcept(c1,b(believe,a1,auto)).#|k(3)?defconcept(c3,b(believe,a1,c1)).#|k(4)?defconcept([b(believe,a1)],c1,b(believe,a1,auto)).#|k(5)?defconcept([b(believe,a1)],c3,b(believe,a1,c1)).#|k(6)?assertEff&fǫind(audi,c1).pW*eUUcancheckUUthisusingthequeryʍ&]cffwƾc͟s6 ffn0JCscmtt8J|@?-deduce(elementOf(audi,c3)).w-% ffڍ͟" s6ffnw-% s6ff s6͟" s6ffn0yesw-% s6ffffwƾ'S:SoUUthebGelievesofa1actlikeweexpGectthemtodo."ޘ8.2RoleclosureSuppGoseewede neaconceptonlyMaleChildrenusingtheterminologicalaxiom(1)inthefollowingknowledgeYAbase.}Thengiventheassertionalaxioms(2){(7)wecannotprovethattomisanelementofonlyMaleChildrenUUbGecausetheremightexistschildrenoftomwhicharenotmale.Buthusingtheaxiom(8)westatethatatanypGointoftimeweknowallob8jectswhicharerole llersoftheUUchildrolefortom.#|k(1)?defconcept(onlyMaleChildren,all(child,male)).#|k(2)?assertEff&fǫind(tom,peter,child).#|k(3)?assertEff&fǫind(tom,chris,child).Ļ29M썠:-iӍ{-#|k(4)?assertEff&fǫind(tom,tim,child). 38#|k(5)?assertEff&fǫind(peter,male).#|k(6)?assertEff&fǫind(chris,male).#|k(7)?assertEff&fǫind(tim,male).#|k(8)?defclosed(tom,Y,child).pSoUUwecanactuallyprovethattomisanelementofonlyMaleChildren.獍&]cffwƾc͟s6 ffn0J|@?-deduce(elementOf(tom,onlyMaleChildren)).w-% ffڍ͟" s6ffnw-% s6ff s6͟" s6ffn0yesw-% s6ffffwƾ'S:IfV@wegettoknowanewchildoftom,V{saybetty,V{whichisnotmale,V{wejustaddtheassertionalaxioms(9)andUU(10).#|k(10)?assertEff&fǫind(tom,betty,child)#|k(11)?assertEff&fǫind(betty,not(male))NowvwearenolongerabletodeducethattomisanelementofonlyMaleChildren,2butwearestillconsistent.+qԍ&]ffwƾc͟s6 ffn0J|@?-deduce(elementOf(tom,onlyMaleChildren)).w-% ffڍ͟" s6ffnw-% s6ff s6͟" s6ffn0now-% s6ff͟" s6ffn0|@?-consistent([]).w-% s6ff͟" s6ffnw-% s6ff͟" s6ffn0yesw-% s6ffffwƾA 8.3AbuductionSHereweconsiderthefamousnixon-diamond.SuppGosewespGecifythatsomebodywhoisaquakerandanormalQuakerisadove.pAndsomebGodywhoisarepublicanandanormalRepublicanisahawk.TheagentUUnixonisaquakerandarepublican.qThiscanbGedoneusingthefollowingaxioms:#|k(1)?defprimconcept(and([quaker,normalQuaker]),dove).#|k(2)?defprimconcept(and([republican,normalRepublican]),hawk).#|k(3)?assertEff&fǫind(nixon,quaker).#|k(4)?assertEff&fǫind(nixon,republican).NowUUweareneitherabletodeducethatnixonisadovenorthatheisahawk.+qԍ&]ffwƾc͟s6 ffn0J|@?-deduce(elementOf(nixon,dove)).w-% ffڍ͟" s6ffnw-% s6ff s6͟" s6ffn0now-% s6ff͟" s6ffn0|@?-deduce(elementOf(nixon,hawk)).w-% s6ff͟" s6ffnw-% s6ff͟" s6ffn0now-% s6ffffwƾ7 ButwecanusetheabGductiveinferencemechanismtogetinformationabGouttheadditionalknowledgeweneedUUtoinferethatnixonisadove.Ļ30W썠:-iӍ>&]aUffwƾc͟s6 ffn0J|@?-abdeduce(elementOf(nixon,dove),H,E).w-% ffڍ͟" s6ffnw-% s6ff s6͟" s6ffn0E@=proved(in([],dove,nixon),hyp([]),w-% s6ff͟" s6ffn%HbasedOn(and([proved(in([],quaker,nixon),hyp([]),basedOn(abox)),w-% s6ff͟" s6ffnSe|proved(in([],normalQuaker,nixon),hyp([]),w-% s6ff͟" s6ffn}basedOn(usingAbHyp(in(env(e4),rn(ffЎ^H,ffЎG,ffЎF,ffЎE),modal([]),w-% s6ff͟" s6ffn%normalQuaker,nixon,hyp(ffЎ^B),ab(ffЎD),call(ffЎC),w-% s6ff͟" s6ffn%proved(in([],normalQuaker,nixon),w-% s6ff͟" s6ffnhyp(ffЎ^B),basedOn(ffЎA))))))]))),w-% s6ff͟" s6ffn0H@=[in(env(e4),rn(ffЎ^P,ffЎO,ffЎN,ffЎM),modal([]),normalQuaker,nixon,hyp(ffЎJ),ab(ffЎL),w-% s6ff͟" s6ffn$Pcall(ffЎ^K),proved(in([],normalQuaker,nixon),hyp(ffЎJ),basedOn(ffЎI)))]@?w-% s6ff͟" s6ffnw-% s6ff͟" s6ffn0yesw-% s6ffffwƾZ5The7PROLOG7vqariableHisinstantiatedwiththesethypGothesisesthatweneedtoinferthatnixonisa 38dove._WHereweneededonlyonehypGothesis,)namlythatnixonisanormalQuaker._WThePROLOGvqariableEisrinstantiatedwiththeexplanationwhywewereabletoprovethatnixonisadove.TheproGofwasbasedonUUthefactthatnixonisaquakerandonthehypGothesisthatheisanormalQuaker.OfUUcourse,weabletoabGducethatnixonisahawk:Pō&]aUffwƾc͟s6 ffn0J|@?-abduce(H,elementOf(nixon,hawk),H).w-% ffڍ͟" s6ffnw-% s6ff s6͟" s6ffn0E@=proved(in([],hawk,nixon),hyp([]),w-% s6ff͟" s6ffn%HbasedOn(and([proved(in([],republican,nixon),hyp([]),basedOn(abox)),w-% s6ff͟" s6ffnSe|proved(in([],normalRepublican,nixon),hyp([]),w-% s6ff͟" s6ffn}basedOn(usingAbHyp(in(env(e4),rn(ffЎ^H,ffЎG,ffЎF,ffЎE),modal([]),w-% s6ff͟" s6ffn%normalRepublican,nixon,hyp(ffЎ^B),ab(ffЎD),call(ffЎC),w-% s6ff͟" s6ffn%proved(in([],normalRepublican,nixon),w-% s6ff͟" s6ffnhyp(ffЎ^B),basedOn(ffЎA))))))]))),w-% s6ff͟" s6ffn0H@=[in(env(e4),rn(ffЎ^P,ffЎO,ffЎN,ffЎM),modal([]),normalRepublican,nixon,hyp(ffЎJ),ab(ffЎL),w-% s6ff͟" s6ffn$Pcall(ffЎ^K),proved(in([],normalRepublican,nixon),hyp(ffЎJ),basedOn(ffЎI)))]@?w-% s6ff͟" s6ffnw-% s6ff͟" s6ffn0yesw-% s6ffffwƾex8.4DefaultsSInthisexamplewewanttospGecifythatchildrenofdoGctorsarerichpGersonbydefault.sSowehavesomerolehasChildandtotalkabGoutthechildrenofdoctorsweneedtherolehasDoctorParentwhichistherestrictionUUoftheinverseUUofhasChild,i.e.theparentrole,todoctor.#|k(1)?defprimrole(hasChild).#|k(2)?defrole(hasDoctorParent,restr(inverse(hasChild),doctor)).pSoifsomebGodyisinthedomainofhasDoctorParent,(Di.e._isachildofdoGctor,andwecannotprovethathe"isanelementofnot(richPerson),thenweexpGecthimtobeanelementofrichPerson..ThisiswhataxiomUU(3)says:#|k(3)?defprimconcept(and([some(hasDoctorParent,top),|#naf(not(richPerson))]),richPerson).Let'sUUaddsomeassertionalaxioms:#|k(4)?assertEff&fǫind(chris,doctor).#|k(5)?assertEff&fǫind(chris,tom,hasChild).BecauseUUtomisachildofadoctorhemustbGerich:&]cffwƾc͟s6 ffn0J|@?-deduce(elementOf(tom,richPerson)).w-% ffڍ͟" s6ffnw-% s6ff s6͟" s6ffn0yesw-% s6ffffwƾĻ31 b썠:-iӍ{-Onotheotherhand,wecanaddtoourknowledgethattomisnotrichusingtheassertionalaxiom(6). 38#|k(6)?assertEff&fǫind(tom,not(richPerson)).pNowUUwenolongerabletodeducethattomisarichPersonandwearestillconsistent.-c&]ffwƾc͟s6 ffn0J|@?-deduce(elementOf(tom,richPerson)).w-% ffڍ͟" s6ffnw-% s6ff s6͟" s6ffn0now-% s6ff͟" s6ffn0|@?-consistent([]).w-% s6ff͟" s6ffnw-% s6ff͟" s6ffn0yesw-% s6ffffwƾA 8.5En=umerationTypuesSSuppGosewearetalkingaboutsomebmw.W*eexpectthiscartobeeitheryellow,Hred,orred.W*ecanputthisUUinourknowledgebaseusingtheaxioms(1)and(2).#|k(1)?defconcept(c1,and([car,some(hasCol,set([yellow,blue,red])),<all(hasCol,set([yellow,blue,red]))])).#|k(2)?assertEff&fǫind(bmw,c1).Now+somebGodytellsusthatthebmwisnotyellow.cThenwecanaddthisknowledgebyaxioms(3)and(4).#|k(3)?defconcept(c2,some(hasCol,not(set([yellow])))).#|k(4)?assertEff&fǫind(bmw,c2).Ofcourse,I]weexpGectthebmwtobeeitherblueorred.uThereforewebuildthefollowingconceptc3:#|k(5)?defconcept(c3,some(hasCol,set([blue,red]))).andUUaskwetherbmwisanelementofc3.&]cffwƾc͟s6 ffn0J|@?-deduce(elementOf(bmw,c3)).w-% ffڍ͟" s6ffnw-% s6ff s6͟" s6ffn0yesw-% s6ffffwƾ'S:W*eUUgettheexpGectedanswer.Ļ32!v썠:-iӍ7IAppendixFA5 HQuin4tus PrologRelease3.1.1Spveci c! Predicates538ask(G+ cEnvName,G+?M,elementOf(G+X,G+?C),G+Exp )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameOCconceptUUnameOExpexplanation@iAUUsynonymforthededucepredicatedescribGedinchapter5.38ask(G+ cEnvName,G+?M,roleFiller(G+X,G+?R,GL,GN),-Exp )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameORroleUUnameOLlistUUofob8jectnamesONnumbGerOExpexplanation[׍AUUsynonymforthededucepredicatedescribGedinchapter5.saveMOTEL(G+#FileName )Arguments:OFileName leUUname 38Savesthewholeprogramstate,containingalluserde nedpredicates.7The leFileNamebGecomesanUUexecutable le.Ļ33"}썠:-iӍ7IAppendixFB5 HSICStus 2.1Spveci cPredicates538ask(G+ cEnvName,G+?M,elementOf(G+X,G+?C),G+Exp )38Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameOCconceptUUnameOExpexplanation@iAUUsynonymforthededucepredicatedescribGedinchapter5.38ask(G+ cEnvName,G+?M,roleFiller(G+X,G+?R,GL,GN),-Exp )Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameORroleUUnameOLlistUUofob8jectnamesONnumbGerOExpexplanation[׍AUUsynonymforthededucepredicatedescribGedinchapter5.saveMOTEL(G+#FileName )Arguments:OFileName leUUname 38Savesthewholeprogramstate,containingalluserde nedpredicates.7The leFileNamebGecomesanUUexecutable le.Ļ34#~썠:-iӍ7IAppendixFC5 HSB-LITTERS In4terface538sbEff&fǫdefenv(G+#EnvName,G+>Comment ) 38(SBEff&fhff&fVDEFENV?ENVNAMECOMMENT)38Arguments:OEnvNameenvironmentUUname 37OCommentstringčcreatesUUanewenvironmentUUwithidenti erEnvNameandassoGciatedcommentComment.38sbEff&fǫinitenv[(G+#EnvName )](SBEff&fhff&fVINITENV?[ENVNAME])Arguments:OEnvNameenvironmentUUnameinitializesUUenvironmentEnvNameorthecurrentenvironmentifnoargumentisgiven.38sbEff&fǫprimconcept([G+#EnvName,][G+M,]G+>CName1,[G+CSp}'ecList] )(SBEff&fhff&fVPRIMCONCEPT?[ENVNAME][(:LIST[(BOA)(DOA)(BCOA)(DCOA)]^,)CNAME1[K- cmcsc10KCSpecList])Arguments:OEnvName}environmentUUname 37OM}moGdalUUcontextOCName1}conceptUUnameOCSp}'ecList}SB-ONEUUconceptspGeci cation32impGosenecessaryconditionsontheinterpretationofCName1inenvironmentEnvNameandmoGdalUUcontextM.Theconditionsarespeci edbyCSp}'ecList.38sbEff&fǫdefconcept([G+#EnvName,][G+M,]G+>CName1,+CSpGecList )(SBEff&fhff&fVPRIMCONCEPT?[ENVNAME][(:LIST[(BOA)(DOA)(BCOA)(DCOA)]^,)CNAME1KCSpecList)Arguments:OEnvName}environmentUUname 37OM}moGdalUUcontextOCName1}conceptUUnameOCSp}'ecList}SB-ONEUUconceptspGeci cation32impGoseTWnecessaryandsucientconditionsontheinterpretationofCName1inenvironmentEn-vNameUUandmoGdalcontextM.Theconditionsarespeci edbyCSp}'ecList.38CSp}'ecListUUisalistofSB-ONEconceptspGeci cationelementshavingthefollowingform:Ļ35$썠:-iӍ{-supers([G+#C1|s,(::: w,G+>Cnq~]) 38(SUPERS?(:LISTC1ZC2:::eCnq~))spGeci esUUaconceptwhichistheconjunctionofC1|s,::: UO,Cnq~.38restrict_inh(G+#RName1,restricts(G+RName2,range(G+CName2,G+>CNameDef)))(RESTRICTEff&fhff&fVINH?RNAME1(RESTRICTSRNAME2(RANGECNAME2CNAMEDEF)))spGeci esaconceptwhichisthedomainofRName1.B_RName1istherestrictionofRName2totherangeCName2UUandtothedefaultrangeCNameDef.nr(G+#RName1,MinNr,G+>MaxNr,G+DefNr)(NR?RNAME1MINNRMAXNRDEFNR)spGeci esaconceptwhichcontainsallob8jecthavingatleastMinNr,atmostMaxNr,andbydefaultDefNrUUrole llersforroleRName1.sbEff&fǫprimelemrole([G+#EnvName,][G+MS,]G+>RName1,G+PrimRSp}'ec )(SBEff&fhff&fVPRIMELEMROLE?[ENVNAME][MS]RNAME1(DOMAIN-RANGECNAME1CNAME2CNAMEDEF))Arguments:OEnvName6environmentUUname 37OM6moGdalUUcontextORName16roleUUnameOPrimRSp}'ec6SB-ONEUUprimitiverolespGeci cation32impGoseFlnecessaryconditionsontheinterpretationofRName1inenvironmentEnvName1andmoGdal contextM.Theconditionsarespeci edbyPrimRSp}'ec.PrimRSpec takesthefollowingform:domain-range(G+#CName1,G+>CName2,G+CNameDef).This(Tde nesRName1tobGearolewith2domainCName1, rangeCName2anddefaultrangeCNameDefinenvironment2EnvNameandUUmoGdalcontextM.38sbEff&fǫdefelemrole([G+#EnvName,][G+M,]G+>RName1,G+RSp}'ec )(SBEff&fhff&fVDEFELEMROLE?[ENVNAME][M]RNAME1c(RESTRICTSRNAME2(RANGECNAME1CNAMEDEF)))Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextORName1roleUUnameORSp}'ecSB-ONEUUrolespGeci cation32impGoseQ`necessaryandsucientconditionsontheinterpretationofRName1inenvironmentEn-vName1andmoGdalcontextM.Theconditionsarespeci edbyRSp}'ecwhichtakestheformrestricts(G+#RName2,range(G+CName1,G+>CNameDef)). RName1kisamaximalsubsetoftheroleUURName2suchthateachrole llerofRName1isinCName1.38sbEff&fǫdisjoint([G+#EnvName,][G+M,]G+>CName1,G+CName2 )(SBEff&fhff&fVDISJOINT?[ENVNAME][M]CNAME1CNAME2)Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOCName1conceptUUnameOCName2conceptUUname32declaresUUtheconceptsCName1andCName2tobGedisjoint.38sbEff&fǫdefelem([G+#EnvName,][G+M,]G+>ICName1,G+ISp}'ecList )Ļ36%Ơ썠:-iӍ{-(SBEff&fhff&fVDEFELEM?[ENVNAME][M]ICNAME1ISPECLIST)ǤArguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOICName1ob8jectUUnameOISp}'ecListSB-ONEUUindividualspGeci cation32introGducestanob8jectinenvironmentEnvNameandmoGdalcontextMMwhichobGeystherestrictions 38givenUUinISp}'ecList.ڍAUUSB-ONEindividualspGeci cationtakesthefollowingformn[isa(G+#CName),G+IRSp}'ec1|s,:::,G+>IRSpecnq~]u(:LIST?(ISACNAME)IRSPEC1Z:::eIRSPECnq~)whereUUIRSp}'eciisxgirole(G+#RNameiTL,iname(G+IRNamei),G+>IRListi)vG(IROLE?RNAMEi(INAMEIRNAMEiTL)IRLISTi)and.theargumentIRListizisalistwhichiseitheremptyorcontainseithernr(G+#MinNriTL,G+>MaxNri,G+DefNri)(NR?MINNRiMAXNRiDEFNRi),UUvr(G+#ICNameiTL)(VR?ICNAMEi),orbGoth.The resultofsb_defelemistheintroGductionofanob8jectICName1whichisamembGerofCNameandpairs(ICName1,ICNameiTL)whichareelementsofIRNameiTL.UTheroleIRNamei &isasubsetofRNameiandhasUUatleastMinNrirole llersandatmostMaxNrirole llers.qThedefaultnumbGerUUofrole llersisDefNriTL.}nsbEff&fǫattributes([G+#EnvName,][G+M,]G+>CN,G+InfoList )(SBEff&fhff&fVATTRIBUTES?[ENVNAME][M]CNINFOLIST)Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOCNconceptUUnameOInfoListlistUUofinfonoGdes32attachessomeattributiveinformationtoconceptCN˕inenvironmentEnvNameandM.TheinformationUUistakenfromInfoListwhichisalistofinfonoGdesoftheform(Attribute,V;alue).LispUUsyntaxforINFOLIST:(:LIST?(:LISTA;TTR1VPALUE1):::I(:LISTATTRnVPALUEn))ڍsbEff&fǫattributes([G+#EnvName,][G+M,]G+>CN,G+RN,G+InfoList )(SBEff&fhff&fVATTRIBUTES?[ENVNAME][M]CNRNINFOLIST)Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOCNconceptUUnameORNroleUUnameOInfoListlistUUofinfonoGdes@iattachessomeattributiveinformationtoroleRNKatconceptCNinenvironmentEnvNameandM.The7informationistakenfromInfoListwhichisalistofinfonoGdesoftheform(Attribute,V;alue).LispUUsyntaxforINFOLIST:(:LIST?(:LISTA;TTR1VPALUE1):::I(:LISTATTRnVPALUEn))ڍsbEff&fǫfact([G+#EnvName,][G+M,]isa(G+ cX,G+?CT) )(SBEff&fhff&fVFACT?[ENVNAME][M](ISAXCT))Arguments:OEnvNameenvironmentUUname 37OMmoGdalUUcontextOXob8jectUUnameOCTconceptUUtermĻ37&썠:-iӍ{-F*or\agivenob8jectnameX\allconceptnamesCTsuchthatXisaninstanceofCTintheworld 38description!willbGeenumerated.Expprovidessomeexplanationwhythisistrue.F*oragivenconceptutermCTWallob8jectnamesXsuchthatXisaninstanceofCTintheworlddescriptionwillbGeenumerated.[TheconcepttermCTcanbeeiteravqariableoraconceptname.[AgainExpprovidesUUsomeexplanationwhythisistrue.38sbEff&fǫfact([G+#EnvName,][G+M,]irole(G+ Mg^This`macroworksinthesamewayasthelispDO=macro.BThegoalsaregiveninalistasinprolog-goal,TheUMvqariablesarelispsymbGolspre xedwith?. qTherestworkslikethedomacro:qThemacrocallsprolog-goalUUandprolog-nextineachloGopandbindsthevqariablesaccordingly*.Ļ43,彠썠:-iӍ{-D.6",HThemacroL(do-prolog-with-streams)SInordertousethedo-prologmacro(seeabGove)withaPROLOGfprocessdi erentfromthelastrecently 38created,UUyouhavetocall(do-prolog-with-stream?iep(do-prolog:::)).Ļ44-?썠:-iӍ7IAppendixFE5 HInstalling MOTEL;ԍE.1 Z]Requiremen=tsSY*ouUUneedoneofthefollowingPROLOGsystemstouseMOTEL:퍍QuintusUUProlog3.1.1SICStusUUProlog2.1PatchUUlevel5{Patchlevel7SWI-PrologUU(V*ersion1.6.10)ECRCUUCommonLogicProgrammingSystem(V*ersion3.2.2)TheUUinterfacebGetweenLispandPrologisonlyavqailableforLucidCommonLispandSICStusProlog."xE.2 Z]InstallationSTheMOTELdistributioncontainsonecompressedtar le,whichincludestheMOTELsystem.`T*oinstall 38theUUsystemonaSUN-4(SunOS4.1.x)executethefollowingsteps:UncompressUUthecompressedtar le#Սprompt(1)%?uncompressTmotel.tar.ZExtractUUthesource leanddoGcumentation lefromthetar le#Սprompt(2)%?tarTxvfmotel.tarThisresultsinthe lesREADME,int.c,int.o,int.pl,motel.lisp,motel.pl,motel.dvi,andhn.dvi.ZThe lecREADMEcgivesabriefdescriptionhowthesystemcanbGeused,gQthe lemotel.dviisthetheusermanualforktheMOTEL,hn.dvigivesanintroGductiontomodalterminologicallogics.vThe lemotel.plistheMOTELssourcet: le,the lesmotel.lisp,int.pl,andint.ocontainthecoGdefortheinterfacebGetweenLucidUUCommonLispandSICStusProlog.AfterUUstartingyourPROLOGsystemyouhavetoconsultthesource le.:؊0prompt(3)%?sicstus 37SICStus?2:1#5:TueJul2116:16:49METDST1992j??8xconsult(motel).fconsulting?motel:pl:::gfmotel:pl?consulted;5600msec329168bytesgyesj??Ļ45.썠:-iӍ{-NowUUyoucanworkwiththeMOTELsystemasdescribGedinthepreviouschapters. 38T*ousetheinterfacebGetweenLucidCommonLispandSICStusProlog,4youhavetomoGdifythe lemotel.lisp.qAtUUthebGeginningitcontainsthreesetq-commands:!𞍍(setqx8consultmotelstring"[^09=usr=local=motel=motel:pl^0]:") 37(setqx8prologexecutable"=usr=local=sicstus2:1=sicstus")(setqx8intEff&fǫdotEff&fplx"=HG=hiwis=timm=lucid=int:pl")!>Y*ouXshouldreplace/usr/local/motel/motel.plwiththe lenameofyourinstallationofthemotel.pl le.bF*urthermore&+youshouldreplace/usr/local/sicstus2.1/sicstuswiththe lenameofyouPROLOGsystem.qTheUUvqariable*int_dot_pl*containstheloGcationofthe leint.plincludedinthedistribution.NowUUyoucanloadthis leafteryouhavestartedLucidCommonLisp:q퍍Kprompt(3)%?lucid 37;;;Lucid?CommonLisp=SPARC;;;Application?EnvironmentVersion4:0:0;6July1990;;;Copyright?(C)1985;1986;1987;1988;1989;1990;1991byLucid;Inc:;;;All?RightsReserved;;;;;;This?softwareproductcontainsconfidentialandtradesecretinformation;;;belonging?toLucid;Inc: Itmaynotbecopiedforanyreasonotherthan;;;for?archivalandbackuppurposes:;;;;;;Lucid?andLucidCommonLisparetrademarksofLucid;Inc: Otherbrand;;;or?productnamesaretrademarksorregisteredtrademarksoftheir;;;respective?holders:Ϝ>(load"motel:lisp");;;Loading?sourcefile"motel:lisp";;;Warning:File?"motel:lisp"doesnotbeginwithIN8PACKAGE:+xLoading?intopackage"USER"#P"=usr=local=motel=src=motel=motel:lisp"Ϝ>ThenyouareabletoworkwiththeinterfacebGetweenLucidLispandSICStusPrologasdescribGedinchapter 38D."ޘReferencesSKFranzaBaaderandBernardHollunder,>[1990.K$RIS:8Knowledge܎RepresentationandInferenceSystem|SystemDescription|. T*echnicalMemoDFKI-TM-90-03,DeutschesF*orschunszentrumfGurKGunstlicheUUIntelligenz.38KAndreasNonnengarUTt,11992.^First-Order)MoGdalLogicTheoremProvingandStandardPROLOG.^Inter-nalUUrepGortMPI-I-92-228,Max-Planck-InstituteforComputerScience.Ļ46/썠:-iӍIHIndex7"Iabduce,UU19,25 38AgentUUnames,7ask,UU30,31assertEff&fǫind,UU938change,UU21,23{25classify,UU13clearEnvironment,UU5compileEnvironment,UU5Concept top,UU7ConceptUUnames,7Conjunction,UU7 role,UU7consistent,UU20copyEnvironment,UU5decrease,UU21,24,25deduce,UU18,19,22def,UU21defconcept,UU8defdisjoint,UU8defprimconcept,UU8defprimrole,UU8defrole,UU8deleteEff&fǫind,UU10Disjunction,UU7environment,UU5ExistsUUrestriction,7getAllFatherRoles,UU15getAllObjects,UU18getAllSonRoles,UU16getAllSubConcepts,UU14getAllSuperConcepts,UU14getCommonFatherRoles,UU17getCommonSonRoles,UU17getCommonSubConcepts,UU15getCommonSuperConcepts,UU15getConcepts,UU14getCurrentEnvironment,UU5IDgetDirectFatherRoles,UU15 38DgetDirectSonRoles,UU15DgetDirectSubConcepts,UU14DgetDirectSuperConcepts,UU14DgetHierarchy,UU13DgetKB,UU12DgetRoles,UU16DgreatestInfl,UU22DgreatestInfls,UU2338Dinconsistent,UU20Dincrease,UU21,23{25Dinfl,UU21,22DinitEnvironment,UU6DInversionDrole,UU7DKnowledgeUUsignature,7DKripkeUUclass,11DleastInfl,UU22DleastInfls,UU22DloadEnvironment,UU6DloadKB,UU12DmakeEnvironment,UU6DmaxNegInfl,UU23DmaxPosInfl,UU23DMoGdalUUconceptterms,7DMoGdalUUcontext,7DMoGdalUUoperators,7DmodalAxioms,UU12DNegation,UU7DNegationUUasfailure,7DnegInfl,UU21,23DnoChange,UU24,25DnoInfl,UU21,23DNumbGerUUrestriction,7DOb8jectUUnames,7DposInfl,UU21,23Ļ470 썠:-iӍ{-realize,UU18 38removeEnvironment,UU6renameEnvironment,UU6RoleUUnames,7RoleUUrestriction,7RoleUUterms,738saveEnvironment,UU6saveKB,UU12saveMOTEL,UU30,31sbEff&fǫask,UU34,35sbEff&fǫdefconcept,UU32sbEff&fǫdefelem,UU33sbEff&fǫdefelemrole,UU33sbEff&fǫdefenv,UU32sbEff&fǫdisjoint,UU33sbEff&fǫprimconcept,UU32sbEff&fǫprimelemrole,UU33SemanticUUnetwork,13showChange,UU22showEnvironment,UU6showFD,UU22showFDW,UU21showHierarchy,UU13showInfl,UU22simultInfl,UU22simultNegInfl,UU23simultNoInfl,UU23simultPosInfl,UU23subsumes,UU13switchToEnvironment,UU6T*erminologicalUUaxioms,8 moGdal,UU8testDirectFatherRole,UU16testDirectSonRole,UU16testDirectSubConcept,UU14testDirectSuperConcept,UU14testFatherRole,UU16testSonRole,UU16testSubConcept,UU15testSuperConcept,UU15T*opUUconcept,7undef,UU21undefconcept,UU9undefprimconcept,UU9V*alueUUrestriction,7Ļ48;y4̀3L cmmi10K`y cmr10 O!cmsy7 0ercmmi7ٓRcmr7