Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!.POSTED!not-for-mail From: Roedy Green Newsgroups: comp.lang.java.help Subject: Re: Java Algorithm for elevator system Date: Sun, 02 Oct 2011 06:24:34 -0700 Organization: Canadian Mind Products Lines: 28 Message-ID: <7bpg87hqteconm56si749996nlc0s3kkt9@4ax.com> References: <59e09820-015b-4187-82a5-b29dce2afde5@g29g2000yqh.googlegroups.com> Reply-To: Roedy Green NNTP-Posting-Host: RCd/Ul4tyxGUBII8WGwa5g.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Complaints-To: abuse@aioe.org X-Notice: Filtered by postfilter v. 0.8.2 X-Newsreader: Forte Agent 6.00/32.1186 Xref: x330-a1.tempe.blueboxinc.net comp.lang.java.help:1184 On Sat, 1 Oct 2011 23:58:40 -0700 (PDT), Anshu wrote, quoted or indirectly quoted someone who said : > >I'm looking for some java based algorithm for elevator simulation, >which will control elevator movement. If any one can give any pointers >on this, it will be of great help to my research paper. The algorithm >need not be a complex one but i need some fancy algorithm as mentioned >in wikipedia like SCAN, LOOK, FCFS, etc. Just play with some toys to represent the cars. Just move the cars in the "sensible" way without thinking about why you are doing anything. After you get the hang of things and have the elevators behaving reasonably, write down your moves. Then look at them and see if you can reproduce them with a set of rules of thumb. Based on that, perhaps you can improve the rules. The more info you have, the better you can do, e.g. total weight of passenger is the car, how many people are waiting at a given spot. -- Roedy Green Canadian Mind Products http://mindprod.com It should not be considered an error when the user starts something already started or stops something already stopped. This applies to browsers, services, editors... It is inexcusable to punish the user by requiring some elaborate sequence to atone, e.g. open the task editor, find and kill some processes.