swarm-modeling
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Swarm-Modelling] Modelling time as a real number - Total Newbie


From: Paul Johnson
Subject: Re: [Swarm-Modelling] Modelling time as a real number - Total Newbie
Date: Thu, 08 Sep 2005 23:03:11 -0500
User-agent: Mozilla Thunderbird 1.0.6-1.1.fc4 (X11/20050720)

Ah, now your original message appears. Although I filed this example in the objc dir, it appears to be java, but should be easy to translate back.

http://www.ku.edu/~pauljohn/SwarmFaq/WorkingExampleCode/objc/FloatingPointScheduling2.java

The basic framework will be as in the Opinion example I mentioned to you a few hours ago. Here you use the customizeBegin thing to create a concurrent group prototype (not actually a group, but rather an ideal type that the scheduler is then told to use as the base class for all concurrent groups). The "sub schedules" are created automatically, you don't control that.

(Note, that's different than an "action group". Totally different.)

Unfortunately, since I have not done this personally, I don't can't give you a working example in objc, my preferred language. but I suggest you take one of the other working examples in that same directory and see if you can get it to go. If you have trouble, post your working example code along with your questions. If you have trouble figuring how to compile the working examples, look at the examples and note many have a last part with the compile command. Those are for Emacs. Many of those details may need updating for your OS. I can say for sure I've had working examples within the last few months, sometime. In objc, I suppose I might start with this

http://www.ku.edu/~pauljohn/SwarmFaq/WorkingExampleCode/objc/SimpleScheduleExample.txt

pj

Vijay wrote:
Hi,
   I am trying to implement dynamic scheduling for an agent based model as 
follows. Whenever an event is executed the next interaction with the agent 
involved in the current event is scheduled at a random time in the (simulated) 
future which is picked from a continuous distribution. However I noticed that 
the swarm schedule collection handles time as an unsigned long int. So is there 
an easy way that an event based scheduling can be implemented within the swarm 
framework where time increases as a real number?

Thanks a lot in advance.
Vijay
_______________________________________________
Modelling mailing list
address@hidden
http://www.swarm.org/mailman/listinfo/modelling


--
Paul E. Johnson                       email: address@hidden
Dept. of Political Science            http://lark.cc.ku.edu/~pauljohn
1541 Lilac Lane, Rm 504
University of Kansas                  Office: (785) 864-9086
Lawrence, Kansas 66044-3177           FAX: (785) 864-5700


reply via email to

[Prev in Thread] Current Thread [Next in Thread]