Solved

Traffic simulator in container shipping yard

Posted on 2013-02-05
5
161 Views
Last Modified: 2013-02-11
Hello again, Experts!

I have been tasked by my manager to write an app that would simulate traffic in a container shipping yard.  The premise is that there are 8 entry gates that trucks could come in, wait for a minute to complete their transaction, then move on to the drop-off point.  My problem is that when two or more trucks overlap within the 1 minute interval, the next truck should get in through the next available gate while the previous truck continues its process.  So I am thinking that this would most likely employ multi-threading.

I have only been writing apps using VB.NET for a little over a year and I am still learning new things everyday. However, most of the apps I've written merely involves data access and reporting, which I'm already comfortable with.  This is the first time that I would be writing a simulator app so any ideas or references you could point me to would be very much appreciated.

Thanks!
Rick0124
0
Comment
Question by:Rick0124
  • 3
5 Comments
 
LVL 75

Expert Comment

by:käµfm³d 👽
ID: 38856785
Not to question your abilities, but a year isn't a great deal of experience, and multi-threading is a very advanced topic--very easy to screw up. Are you sure you're ready for something of that caliber?

Not attempting to dissuade you, but I don't want to BS you either  : )
0
 

Accepted Solution

by:
Rick0124 earned 0 total points
ID: 38856818
Thanks, Kaufmed.  

I understand that multi-threading is very advanced indeed for my experience that is why I am also open to other suggestions.  But I would rather learn it the hard way than have this work outsourced, LOL!

If you have links that I could read about or maybe even watch, I would very much appreciate it.

Regards,
Rick0124
0
 
LVL 12

Expert Comment

by:profgeek
ID: 38859943
What you're wanting to do is a system simulation, which is best done using a language specifically tailored for that task.  In the old (mainframe) days we used GPSS (General Purpose System Simulation), but it's not easy to find anymore.  There are some simulation language packages, however:

http://www.wolverinesoftware.com/   (uses GPSS/H)

http://webgpss.com/index.html  (web GPSS)

http://www.minutemansoftware.com/simulation.htm

Simulations are very difficult to program from scratch, as they are based upon statistical modeling.  I used to give my advanced VB students a "simple" one line / one server simulation to write in VB and it was over most of their heads.  Even advanced VB programmers would be hard-pressed.  It's not the programming, it's the conceptual framework of a real-time simulation where you are modeling reality.  First of all, there are myriad parameters you need to input to your model.  Second, there are variations in run-time variables like arrival times, service times, resource availability, dependancies, etc..  It is well worth the time and money to learn and use something like GPSS, where the statistical algorithms are already built in.  

One more thing is that simulation does require a working knowledge of statistics.  If you are rusty there, but have some background, you can probably refresh as you go.  If you have no statistical background, you will be in over your head in no time at all.
0
 

Author Comment

by:Rick0124
ID: 38860329
Thank you for the suggestion, ProfGeek.  You are spot on with the parameters required for the simulator app I am trying to write.  I surely would like to be in one of your classes! :)  I will look at the links you provided and go from there.

Thanks again!
Rick0124
0
 

Author Closing Comment

by:Rick0124
ID: 38875499
Although ProfGeek's answer did not directly answer my question, it did however, gave me ideas on where to go from there.
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

In my previous two articles we discussed Binary Serialization (http://www.experts-exchange.com/A_4362.html) and XML Serialization (http://www.experts-exchange.com/A_4425.html). In this article we will try to know more about SOAP (Simple Object Acces…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now