|
Segregation,
Assimilation and Association Models
|
|
|
Dave's Deterrence Model after
Mark Kleiman-2007
|
| |
To Do:
Enable choosing a different mobility for each agent type.
Enable holding a space and making a delayed move.
Automatic switching between "moves" and "population"
for segregation vs. assimilation.
Enable individual differences (i.e. personality, memory) for agents within
each type. |
|
|
Segregation & Assimilation
Version 15 -April 2008
A changeTo()
function has been added to allow agents to change type. More functions
should be added to return the plurality or majority of agent types in
the six neighborhoods, but I leave that to you. At present, rule set #20
is an "ad hoc" set of "if"s, changing the agent's
type to whichever agent type is greater than the TRACKBAR number. You
need to keep pressing RUN since the simulation shuts down when there are
no moves, and no moves are specified. Try combining changeTo()
with some moveAndRender()s
to avoid stalling.
Lesson: When you change
the very essence of a simulation, you'll likely have to change a lot of
code.
|
|
|
Segregation-Version 14 -April
2008
You
can draw Cyan, Magenta, Yellow and Silver agents as well as Black empty
space and White barriers with pen Nibs of up to 10 pixels in size. Also,
you can save and open any current demographic pattern to and from a file.
The six neighborhood functions (8, 24 & 16 cell) report on all six
cell types (4 agents, empty & barrier).
|

Note: As with version 10, you can
import one bitmap to set up the
initial population and another to set up geographic characteristics.
|
Segregation-Version 11 -2008
Same
as version 10 except that a provision has been made for four different
agent types: Cyan, Magenta, Yellow and Red. The last item in the "Initial
Population ComboBox sets up a random population of 20% of each type including
empty cells. The statistical EditBoxes at the bottom have been corrected
to show both the population at any time AND the moves per frame. Notice
that the caption changes. The graph also shows the activity of Red agents.
The TrackBar, drawing and BitMap functions that setup the initial population
demographics have not been changed to accommodate Red.
None of the changes
that we made in class are included in Version 11 (i.e. no sounds, no new
rules, etc.).
|
|
|
Segregation-Version 10 -2007
You
may now create any initial condition using PhotoShop to draw a 200 x 200
pixel bitmap image in PURE Cyan, Magenta, Yellow, Black and White. You
may also draw individual pixels by picking up the agents' colors from
the TShape boxes and clicking or dragging on the PaintBox. Some .bmp configurations
are included below:
Boxes:
|
|
|
Segregation-Tweaked-2007
Explanation
and Notes
The code has been cleaned up. Functions have been added
to calculate a 24-cell neighborhood and a 16-cell "ring" neighborhood
by subtracting the 8-cell neighborhood from the 24-cell neighborhood.
Several new rules have been added to implement these new functions.
|
|
|
Assimilation - B
This basic application is modified from Conway's Game
of Life to provide cinematic polling in contrast to the random polling
for the segregation models. Functions provide the number of CYAN, MATENTA
and YELLOW neighbors, as well as the number of EMPTY cells. Functions
also provide the types of neighbors who are the most and the least prevalent.
Ties are not dealt with in functions. Only a few rather unimaginative
rules have been implemented.
|
|
|
Saeid Atoofi's Language Evolution
(on the assimilation of language elements)
|
|
|
Segregation-Tweaked-October-2006
The statistics panel, run-to-frame panel and mobility
of 5 bug have been fixed. Functions have been added to calculate a 24-cell
neighborhood and a "ring" neighborhood by subtracting the 8-cell
neighborhood from the 24-cell neighborhood. Several new rules have been
added to test these functions.
|
xxxxx xxxxx

Some of the patterned move rules in the version of segregation
below. Patterned perceptions are based upon agents being in a specific
loaction (in this instance diagonal, vertical or horizontal) relative
to the perceiving agent. The coding is a kludge since it does not wrap
around.
|
xxxxx xxxxx
Some of the totalizing move rules with different home and
destination parameters in the version of segregation below. Totalizing
perceptions are based upon the total number of agents of different types
irrespective of exactly where they are located.
|
|
|
Schelling's
"Segregation with Statistics
-April-2006"
A "frame" has been accurately redefined as
an average of one opportunity to move for each member of the population.
The number of moves made per frame is displayed and plotted. A "happiness"
statistic should also be added. More rule options have been added, some
as kludges. The TrackBar event handler has been deactivated...
|
|
|
Schelling's
"Segregation-April-2006"
Some small bugs have been worked out since the previous
version. Add two or
three more complex rule sets that produce interesting results
and don't forget that "historical" changes can make a difference
to the final pattern, as the screenshot at the left illustrates.
|
|
|
Schelling's "Segregation
IV"
At present, this version contains only one additional
rule which you will find it relatively easy to modify to your needs. The
rule allows for complex conditionals to be set and ignores the "Home
& Destination" option. It is "Case 5:". The window
has been enlarged to allow for longer rule names and statistics...
|
|
|
Schelling's "Segregation
III"
February 2006
Enhanced with different relative populations, different
neighborhood types, different move distances, rules applied to destination
only or both home and destination, and geographically applied rules including
preference, move distance and neighborhood type encoded in the Red, Green,
and Blue channels of a 200x200 pixel bitmap image.
|
|
|
Darryl Jung's Enhanced Segregation
Model
HCS Bragin Prize Winner
|
|
|
Schelling's Segregation Enhanced
January 2005
Try enhancing the model further by adding your own
options to the selections. You might add more choices to the choice of
the initial population or the distances agents may move. But the most
interesting results will probably result from adding more elaborate rules
or more involved geographies...
|
|
|
Segregation Twice - 2004
Two simulations of Schelling's segregation
run in two separate Windows. A third Window called "Control"
enables you to run side-by-side experiments in sync. Three Forms and three
Units are required.
|
|
|
Segregation 2004 - Incomplete
This is as far as we got at our first
class meeting. We will continue to code this example by hand at our second
meeting.
An outline for coding the complete
version of this simulation which will fit on one page. The details have
been omitted and the code will not run.
|
|
|
Segregation 2004
A simplified introductory version
of Schelling's segregation model. The source code is well annotated and
more complex preferences may be introduced into the code.
|
|
|
Segregation
An example of how preferences for having neighbors
like yourself can lead to segregated population distributions.
Note:
Open the .bmp files and save them to a new folder. Then run the application,
open either .bmp, render, transfer it to the array, and click "Enable
BMP Rule."
Project
Files Zipped
|
|
1
.....
2 .....
3 .....
4 .....
5 .....
6 
Segregation patterns produced by holding the number of preferred neighbors
like oneself constant through 999 frames.
|
|
3
then 4 .....3
then 4 then 5 
Segregation patterns produced by historically increasing the number of
preferred neighbors like oneself evenly through 999 frames.
|
|
|
Segregation Tweaked
Some enhancements in the rules are included, which
are commented out. You will have to uncomment them and comment out the
previous rules to observe the effects.
Note:
This was a classroom exercise in which we tried a number of different
twists on the general program
Project
Files Zipped
|
|
|
Segregation Three
In this version, the user may select different initial
ratios of Red, Green and Blue individuals and empty spaces. The user may
also select preference rules that apply differently to each type of individual.
Several buttons have been consolidated.
Note:
Open the .bmp files and save them to a folder. The "Import Bitmap"
button will load the images into the application.
Project
Files Zipped
|
.....
..... .....
Segregation patterns
produced with an initial population ration of 1 Red : 2 Blue : 4 Green
: 3 empty. With a preference of two neighbors like oneself, the pattern
to the left emerges. Beginning with that pattern, changing the preference
rules to Reds like at least 3 Reds, Blues like at least 2 Reds, and Greens
like any Greens, the pattern on the right emerges.
|
|
|
Naoko's Segregation Model
Lots of things going on
here. We'll let Naoko explain them...
|
|
|
Simone's "Population Distribution"
Simulates population movement in a city based on ethnic
preference, educational funding and level of education.
Executable
|
|
|
Kevin's Segregated
and Iterated Prisoner's Dilemma (IPD)
Agents play IPD with a user-selected neighborhood and
then move based upon their preferences for neighbors who cooperate or defect.
Executable
|
|
|
Gwen's Segregation based upon
Age, Sex and Status
Preferences can be selected for these three factors.
Executable
|
|
|
Bridget's Segregation based upon
Los Angeles Census Data.
Census data from Los
Angeles in 1990 and 2000 forms the basis for this
simulation.
Executable
|