Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?

Discrete event simulation

by toma (Vicar)
on May 27, 2007 at 03:00 UTC ( #617716=perlquestion: print w/replies, xml ) Need Help??

toma has asked for the wisdom of the Perl Monks concerning the following question:

I need a discrete event simulator, and I have been using the Simpy ( discrete event simulation package. Simpy doesn't happen to be written in Perl, so I have been using this project as an excuse to try Python again.

However, I am still interested in something like Simpy for Perl. Does anyone know of a discrete event simulation package for Perl? I would like to hand off this project at some point. We possess plenty of Perl people but paltry Python programmers.

It should work perfectly the first time! - toma

Replies are listed 'Best First'.
Re: Discrete event simulation
by shmem (Chancellor) on May 27, 2007 at 03:27 UTC
    Skimming the Simpy overview, its core looks a lot like POE to me. Together with a GUI Toolkit like Tk, GtK or Qt such a system could easily be built in perl, just connecting the dots.


    _($_=" "x(1<<5)."?\n".q·/)Oo.  G°\        /
                                  /\_¯/(q    /
    ----------------------------  \__(m.====·.(_("always off the crowd"))."·
    ");sub _{s./.($e="'Itrs `mnsgdq Gdbj O`qkdq")=~y/"-y/#-z/;$e.e && print}
Re: Discrete event simulation
by agentz (Novice) on May 27, 2007 at 21:22 UTC
    I've produced an event simulator named Sim which is somewhat similar to Simpy in my SVN repos:

    The Sim Simulator

    Only 2 .pm files, pretty simple to implement, but still rather powerful ;)

    It's truly general-purpose and thoroughly tested at the moment though it's currently a subproject of my logic circuit simulator, Tesla , which uses it as the core.

    There is some (English) POD in the .pm files of Sim and I've also written a trivial M/M/1 and M/M/m sample app here:

    SuperMarcket Simulation

    A corresponding report with some code snippets and interesting pictures can also be found here:


    Sorry for the Chinese characters in this report, but there is always a Google Translate :)

    If you find this thing useful, I may feel like putting it onto CPAN.

    Hope this helps.

    Cheers, agentz

      I think this is really interesting, AND useful. You should definitely put it on CPAN.

        Glad you like it :)

        Will do in the next few days.

        Sim 0.02 has just been uploaded to CPAN. Enjoy~ :)

        - agentz

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://617716]
Approved by naikonta
Front-paged by Old_Gray_Bear
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (3)
As of 2023-12-09 17:45 GMT
Find Nodes?
    Voting Booth?
    What's your preferred 'use VERSION' for new CPAN modules in 2023?

    Results (38 votes). Check out past polls.