首页 课程资源 C/C++     /    数据结构课设-模拟电梯

数据结构课设-模拟电梯

上传者: qq_43497224 | 上传时间:2025/5/8 10:04:09 | 文件大小:17.04MB | 文件类型:zip
数据结构课设-模拟电梯
设计一个电梯模拟系统。
这是一个离散的模拟程序,由随机事件驱动,以模拟时钟决定乘客或电梯的动作发生的时刻和顺序,系统在某个模拟瞬间处理有待完成的各种事情,然后把模拟时钟推进到某个动作预定要发生的下一时刻。
要求:(1)模拟某校九层教学楼的电梯系统。
该楼有一个自动电梯,能在每层停留,其中第一层是大楼的进出层,即是电梯的“本垒层”,电梯“空闲”时,将来到该层候命。
电梯一共有八个状态,即正在开门(Opening)、已开门(Opened)、正在关门(Closing)、已关门(Closed)、等待(Waiting)、移动(Moving)、加速(Accelerate)、减速(Decelerate)。
(2)乘客可随机地进出于任何层。
对每个人来说,他有一个能容忍的最长等待时间,一旦等候电梯时间过长,他将放弃。
最后一个人放弃能不能取消按键?(3)模拟时钟从0开始,时间单位为0.1秒。
人和电梯的各种动作均要消耗一定的时间单位(简记为t),比如:有人进出时,电梯每隔40t测试一次,若无人进出,则关门;
关门和开门各需要20t;
每个人进出电梯均需要25t;
电梯加速需要15t;
下行时要不要加速?上升时,每一层需要51t,减速需要14t;
每一层和减速?下降时,每一层需要61t,减速需要23t;
如果电梯在某层静止时间超过300t,则驶回1层候命。
驶回本垒层间接到消息?(4)电梯调度规则如下:①就近原则:电梯的主要调度策略是首先响应沿当前行进方向上最近端的请求直到满足最远端请求。
若该方向上无请求时,就改变移动方向;
②在就近原则无法满足的情况下,首先满足更高层的请求;
③电梯的最大承载人数为13人,电梯人数达到13人后,在有人出电梯之前,不接受进入电梯的请求;
④乘客上下电梯时先出后进。
进电梯时乘客是按发出乘坐请求的顺序依次进入,每次只能进入一人且每个人花费的时间都为25t;
⑤电梯在关门期间(电梯离开之前)所在层提出请求的乘客同样允许进入。
(5)按时序显示系统状态的变化过程,即发生的全部人和电梯的动作序列。
扩展要求:实现电梯模拟的可视化界面。
用动画显示电梯的升降,人进出电梯。
设计有下列对象:电梯、人、电梯控制板及其上各种按钮、模拟时钟等。
本软件ID:12045842

文件下载

资源详情

[{"title":"(37个子文件17.04MB)数据结构课设-模拟电梯","children":[{"title":"模拟电梯","children":[{"title":".vs","children":[{"title":"模拟电梯","children":[{"title":"v15","children":[{"title":"Browse.VC.db <span style='color:#111;'>5.18MB</span>","children":null,"spread":false},{"title":".suo <span style='color:#111;'>54.50KB</span>","children":null,"spread":false},{"title":"ipch","children":[{"title":"AutoPCH","children":[{"title":"cec9e5a631563721","children":[{"title":"图的遍历-邻接表.ipch <span style='color:#111;'>72.44MB</span>","children":null,"spread":false}],"spread":true}],"spread":true},{"title":"1e79c1d3d1207885.ipch <span style='color:#111;'>320.00KB</span>","children":null,"spread":false},{"title":"f4f7feccebcd5da5.ipch <span style='color:#111;'>320.00KB</span>","children":null,"spread":false}],"spread":true}],"spread":true}],"spread":true}],"spread":true},{"title":"模拟电梯","children":[{"title":"Elevator.h <span style='color:#111;'>2.33KB</span>","children":null,"spread":false},{"title":"pch.h <span style='color:#111;'>639B</span>","children":null,"spread":false},{"title":"Text.txt <span style='color:#111;'>212B</span>","children":null,"spread":false},{"title":"pch.cpp <span style='color:#111;'>200B</span>","children":null,"spread":false},{"title":"模拟电梯.vcxproj <span style='color:#111;'>8.40KB</span>","children":null,"spread":false},{"title":"OrignFunction.cpp <span style='color:#111;'>11.64KB</span>","children":null,"spread":false},{"title":"main.cpp <span style='color:#111;'>243B</span>","children":null,"spread":false},{"title":"模拟电梯.vcxproj.user <span style='color:#111;'>165B</span>","children":null,"spread":false},{"title":"Debug","children":[{"title":"原语函数.obj <span style='color:#111;'>189.50KB</span>","children":null,"spread":false},{"title":"模拟电梯.obj <span style='color:#111;'>38.22KB</span>","children":null,"spread":false},{"title":"pch.obj <span style='color:#111;'>3.95KB</span>","children":null,"spread":false},{"title":"模拟电梯.Build.CppClean.log <span style='color:#111;'>1.48KB</span>","children":null,"spread":false},{"title":"模拟电梯.tlog","children":[{"title":"CL.write.1.tlog <span style='color:#111;'>1.56KB</span>","children":null,"spread":false},{"title":"CL.read.1.tlog <span style='color:#111;'>26.78KB</span>","children":null,"spread":false},{"title":"unsuccessfulbuild <span style='color:#111;'>0B</span>","children":null,"spread":false},{"title":"CL.command.1.tlog <span style='color:#111;'>5.18KB</span>","children":null,"spread":false},{"title":"link.write.1.tlog <span style='color:#111;'>688B</span>","children":null,"spread":false},{"title":"link.command.1.tlog <span style='color:#111;'>2.85KB</span>","children":null,"spread":false},{"title":"link.read.1.tlog <span style='color:#111;'>2.96KB</span>","children":null,"spread":false},{"title":"模拟电梯.lastbuildstate <span style='color:#111;'>243B</span>","children":null,"spread":false}],"spread":false},{"title":"elevator.obj.enc <span style='color:#111;'>301.04KB</span>","children":null,"spread":false},{"title":"模拟电梯.pch <span style='color:#111;'>1.94MB</span>","children":null,"spread":false},{"title":"模拟电梯.log <span style='color:#111;'>7.48KB</span>","children":null,"spread":false},{"title":"Elevator.obj <span style='color:#111;'>295.86KB</span>","children":null,"spread":false},{"title":"vc141.idb <span style='color:#111;'>275.00KB</span>","children":null,"spread":false},{"title":"vc141.pdb <span style='color:#111;'>572.00KB</span>","children":null,"spread":false}],"spread":false},{"title":"Elevator.cpp <span style='color:#111;'>7.06KB</span>","children":null,"spread":false},{"title":"模拟电梯.vcxproj.filters <span style='color:#111;'>1.51KB</span>","children":null,"spread":false}],"spread":false},{"title":"Debug","children":[{"title":"模拟电梯.pdb <span style='color:#111;'>996.00KB</span>","children":null,"spread":false},{"title":"模拟电梯.exe <span style='color:#111;'>136.00KB</span>","children":null,"spread":false},{"title":"模拟电梯.ilk <span style='color:#111;'>783.32KB</span>","children":null,"spread":false}],"spread":true},{"title":"模拟电梯.sln <span style='color:#111;'>1.42KB</span>","children":null,"spread":false}],"spread":true}],"spread":true}]

评论信息

免责申明

【好快吧下载】的资源来自网友分享,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,【好快吧下载】 无法对用户传输的作品、信息、内容的权属或合法性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论 【好快吧下载】 经营者是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。
本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二条之规定,若资源存在侵权或相关问题请联系本站客服人员,8686821#qq.com,请把#换成@,本站将给予最大的支持与配合,做到及时反馈和处理。关于更多版权及免责申明参见 版权及免责申明