[Updates] SimSwift - a transport of a DES - Discrete Event Simulator from SimPy

Gareth Harris garethharris at mac.com
Fri Oct 2 16:13:22 EDT 2015


SimSwift 

In the past, I wrote simulator/control programs to handle processes such as factories, warehouses and scientific instrument systems. I wrote these programs in Python using Simpy. Now I would like to write them in Swift. This would enable these programs to run natively in the Apple OSX environment and also possibly to be used in IOS. I also believe that Swift will be almost as easy to write as Python, being similar, plus much faster.

The major python support package for this type of work is SimPy - a discrete event simulator for python. I like this package because it is simple and mature. It can also support simulation and online control either in clock [real] time or varying event speeds.

First I intend to create SimSwift as a transport of the SimPy library from Python.
I am soliciting your help in this project.

Our target demo will be the simple machine shop example in python: https://simpy.readthedocs.org/en/latest/examples/machine_shop.html

To accomplish this, I need to:
1 - Learn Swift - yes, the time has come
2 - Learn GCD - Grand Central Dispatch = also the time has come
            see:    http://www.raywenderlich.com/79149/grand-central-dispatch-tutorial-swift-part-1
3 - Make generators work in Swift - generators are a very useful language feature of python and now also javascript. 
     They support "yield" and "resume" capability for functions, iterators and closures.
          see:     https://github.com/aliceatlas/hexagen
4 - And the doc of Simpy starts at:
         https://simpy.readthedocs.org/en/latest/

I may need your help starting with step 3 - generators in swift:
     using the github entry "hexagen" The author says it works - but leaks.
     see:    https://github.com/aliceatlas/hexagen

I hope this is enough starting info. Let me know if you have ideas.

Gareth

======================================================================
= Gareth Scott Harris  -   garethharris at mac.com <mailto:garethharris at mac.com>  -  505-358-6668
= location: 3308 Morris St. NE #19, Albuquerque, NM 87111
= web:   technical:  GarethHarris.com <http://garethharris.com/>  --  personal:   SentimentalStargazer.com <http://sentimentalstargazer.com/>
======================================================================
Quote of the Day: 
The early bird gets the worm,
but the second mouse gets the cheese.
======================================================================







-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cocoaconspiracy.com/pipermail/updates/attachments/20151002/5a80fcb9/attachment-0001.html>


More information about the Updates mailing list