欢迎来到天天文库
浏览记录
ID:61530240
大小:154.00 KB
页数:15页
时间:2021-02-24
《用AnyLogic进行多智能体仿真.ppt》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、第5讲用AnyLogic进行MAS仿真5.1先看一个例子5.2对此例子进行概览5.3具体的学习5.4主要的statechartcomponents5.5动画的表示之前的之前要看的视频观看视频:航天神五、神六发射时,飞行控制室实况录相。注意,哪些地方应用了仿真技术为什么要用?不用行不行?5.1例子:熟读唐诗三百首,不会作诗也会呤销售渠道的模拟:背景:ThisisanAgentBasedmodelofasalesprocessinabusinesswhereclientsaretobereviewe
2、dbythecompany:e.g.thiscouldbeinsurance,banking,leasing,etc.TheprocesshasseveralstagesthataremodeledbydifferentstatesinthestatechartofaCustomerobject:initialcontact,quote,creditreview.Thecustomermayleaveoneachstage,andthecompany,inturn,mayrejectthecus
3、tomer.Themodelhelpsyoutoexaminehowtheskilllevelandsizeofthesalesforceandthecreditreviewteamaffecttheefficiencyofthewholeprocess.5.2Agent的形成A初始状态和属性Prospect的最初位置:Getx和getY状态图Statechart:Agent的各种状态在这里用图形方式表达,状态图中,将各种状态变化时的行为或者属性更改在此处写出,这里(可能需要用到各种Anylog
4、ic里的编程对象)例如:潜在客户prospect的变化状态。在mainmodel中进行调用用get返回对模型中各种对象的引用在不同的状态图中对这些对象进行编程和调用各种变量和参数(二者有何区别?)Mainmodel中的参数与变量各个不同的状态图中的参变量统计状态与表示思考:哪些变量要放在statechart中哪些要放在Mainmodel中?集成运行展示:salesfunnel5.3具体的学习StatechartEntryPoint、FinalstateStatechartentrypointis
5、usedtoindicatetheinitialstateofthestatechart. Thereshouldbeexactlyonestatechartentrypointdefinedforeachstatechart.Youmaydefineseveralindependentstatechartsforthesameactiveobject,eachonedescribingsomeparticularprocess.InthiscaseAnyLogicwilldistinguish
6、howmany distinctstatechartstherearebyanalyzingthenumberofstatechartentrypoints.GeneralpropertiesofstatechartentrypointName–Thenameofthestatechartentrypoint. Thenameisusedtoidentify andaccesstheentrypointfromcode.Showname–Ifselected,the nameofthestate
7、chartentrypointisdisplayedonapresentationdiagram.Ignore–Ifselected,thestatechartentrypointisexcludedfromthemodel.Public– Defines,whetherthestatechartentrypointisvisibleonapresentationdiagramoftheownerofthisactiveobjectclass. Sincestatechartelementsca
8、nnotappearonownerclass'presentation,thischeckboxisalwaysdeselectedanddisabled.Show atruntime–Ifselected,thestatechartentrypointisvisibleonapresentationatruntime.Action– SequenceofJavastatementsexecutedwhenthestatechartentrypointforwardsthecontroltoan
此文档下载收益归作者所有