[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Heatbug related inquiries...
From: |
Ken Cline |
Subject: |
Re: Heatbug related inquiries... |
Date: |
Fri, 1 Aug 1997 18:09:55 -0400 (EDT) |
On Fri, 1 Aug 1997 address@hidden wrote:
> Would it be possible to have another heatspace window, up showing
> another varible spatially (ie. unhappiness)?
Our first model had 4 views of the "world" for 4 separate
types of data (eg altitude, vegetation, risk, etc). The
type of data determines which structure (eg discrete2d,
diffusion2d, etc.) you choose to hold the data.
> And how does the various gradations of red get displayed for the heat.
> That is, how are various levels of heat actually drawn in the code?
Red(x,y) = Heat(x,y) / 512 + 0, Note: integer division
Green(x,y) = 0
Blue(x,y) = 0
>From HeatbugObserverSwarm.m
// Colours [0,64) are assigned to the range Red [0, 1), for heat display.
for (i = 0; i < 64; i++)
[colormap setColor: i ToRed: (double)i / 63.0 Green: 0 Blue: 0];
and
[heatDisplay setDisplayMappingM: 512 C: 0]; // turn [0,32768) -> [0,64)
Also see Value2dDisplay.
> PS. Is it possible to add bugs to the simulation while it runs? (like
> they are reproducing?)
See "addHeatbug" method in HeatbugModelSwarm.
As far as "reproducing", were you interested in giving the
heatbugs a lifecycle?
The purpose of Heatbugs is to be more of a learning tool --
complex enough to showoff a modest number of Swarm's
features without adding a so much as to make it
overwhelming. (I personally think it fills this role
wonderfully.)
There are several other models written by others that
include biological processes amoung other things. Take a
look at some of the user links on the Swarm Community page.
Ken.
PS: I don't have a lot of time right now so I had to make my
response rather short.
All: Have a great weekend!
_________________________________________________________
Ken Cline address@hidden
SAIC VOICE (410) 571-0413
Annapolis, MD FAX (301) 261-8427
==================================
Swarm-Support is for discussion of the technical details of the day
to day usage of Swarm. For list administration needs (esp.
[un]subscribing), please send a message to <address@hidden>
with "help" in the body of the message.
==================================