Agent-based Modelling of Collective and Coordinated Behaviour
For this course work you must submit three NetLogo Models (as .nlogo files) on the slot made available on Canvas (Unit 6 Course Work Assignments). In Model 1 turtles pile up “chips”, in Model 2 the turtles form grouping patterns based on attraction and repulsion and Model 3 integrates the grouping patterns that emerge in Model 2 with the collecting activities of Model 1.
Make sure to put your last name and Student Registration Number in the name of the submitted NetLogo files (for example as in “patil123.nlogo”). If you do this course work in pairs, names and SRN numbers of both participants should be in the title of the .nlogo file (for example “smith234brown567.nlogo”).
The Models should show and contain the following
Model 1 “Collecting”:
This model can be built by adapting and extending NetLogo’s “Termites” model (Models Library > Biology > Termites) or the equivalent mode set up in Practical 3 (Agent-Based Models 1).
Model 2 “Flocking”:
This model is a simplified version of NetLogo’s “Flocking” model (Models Library > Biology > Flocking) and how it can be built is outlined in the description of Practical 4 (Agent-Based Models 2).
Model 3 “Flocking with Collecting”:
Your understanding of the models will be assessed in some of the multiple choice questions that make up Course Work 3
NetLogo Models to use:
However, for a better understanding of the working of the parameter settings, it is advised to also investigate the model as originally written in “observer-mode” (this mode allows you to switch the cone on/off and combined with a travel-line this helps in interpreting the actions of the turtles and the resulting grouping patterns).
The sets of parameter values 1 – 8 should be exactly as given in the practical description.
Changes and Extensions to the “Termites” Model.
The original “Termites” (or the equivalent “Agent Based Model 1”) model should be altered as follows:
and extended by:
Get this done by writing in the ask patches (in the to setup procedure)
statements of the form:
if (distancexy (x) (y) < Object#Size [set pcolor sky]
where (x) and (y) are scaled x- and y-coordinates of the form:
x = object#-xcor * max-pxcor
y = object#-ycor * max-pxcor
The scaling factors for x (object#-xcor) and y (object#-ycor) should range between -1 and 1 (with increments of 0.1) and be adjustable by dedicated sliders. The symbol # indicates the object number (i.e. 1 or 2).
Consult NetLogo’s dictionary for detailed information about the distancexy reporter.
Connecting the Models
The integrated model should be set up in such a way that the turtles are first of all splitting and joining as dictated by fission-fusion model (Agent Based Model 2) but start collecting when they run into a chip. It is therefore essential that you do not change anything in the code of Agent Based Model 2 (i.e. the to flock procedure).
There are various ways to integrate the two models (NB both should be in turtle-mode). One way of doing this is outlined below.
Note that the two models have the procedure “wiggle” (P2) in common. This suggests a “connecting” procedure, for instance with the name to move, which includes a conditional call to P2 (“wiggle”).
The connecting procedure is called in a to go. This to go furthermore contains a switch, “collect-on?”. If this switch is ON, to collect (i.e. model 1) is activated.
The connecting procedure to move is defined outside the to go and includes calling P2 (“wiggle”), but only IF a switch (that controls flocking) is OFF, ELSE to flock will be executed.
In the to collect procedure all calls to P2 (“wiggle”) should be replaced by a call which takes care of the suggested linking . Also, if “collecting?” is ON, the outward appearance of the turtles should be adjusted in order to assure that extension ii is not violated.
Suggestions for experiments
The “world settings” for all models are:
Location of origin: Center.
max-pxcor = max -pycor = 100, Patch size = 2.5 (but see the note on run times at the end of this document).
World wrapped horizontally and vertically.
Default number of turtles: 20
Size of turtles: 4
Default density of coloured patches: 10%
For Model 1: Number of turtles should be no more than 100, but it is worthwhile to see what happens with a population as small as 10 turtles.
The density for chips should not exceed 10% and the slider should increment with steps of 0.01. Check what happens for very low percentages (e.g. 0.15, 0.25).
You could also play with some intrinsic values of the collecting model, like the “forward 20” step in the procedure “Search-for-chip” (P1).
What happens if this number of steps is much lower for the blue chips (e.g. fd 1) than for the green chips (fd 20) (or the other way around)?
Run the model with one circular object and vary its size (for example 5, 10, and 15). Run the model several times for each size. Also run the model with two objects and let them be either of the same size (both small = size 5, or both large = size 15) or one large (15) and the other small (5).
The “Info” tab on the “termites” model also offers nice suggestions and provides valuable background information.
For Model 2: Run the various settings 1 – 8 and try to figure out how the change in parameter values (look what happens with the sliders if you select a particular setting from the “Chooser”) affect the grouping patterns. You may also want to experiment with settings other than offered by the “Chooser”. For this, you need to override the “Chooser” by turning a switch (called “choose settings?”) OFF.
For Model 3: Switch both “collecting?” and “flocking?” on and pick a particular flocking setting and see how the type of grouping influences the piling up of the chips. Also switch collecting on and off during the run of a particular setting of flocking (and the other way around, i.e. choose different flocking settings during a run).
For all Models: To understand the working of the models it is helpful if you can switch on/off the turtles leaving a trail behind.
Some of the settings may take quite some time before a pattern becomes apparent. For the “Termites” model, using its original settings (chip density = 20%, 400 turtles), it takes more than 10 minutes when running at normal speed (and ~ 7 minutes at full speed) as measured by an online stopwatch (https://www.on-linestopwatch.com) on my laptop. Using a of density (10%) and 100 turtles for the “Termites” model requires ~ 1 – 1.5 minutes at full speed for one type of chips but takes more time for two types (blue and green). Completion time can be reduced by running the simulation in a smaller world (50 x 50, patch size = 5, density 10%, 100 turtles, ~ 20 seconds at normal speed for the “Termites”), but this goes at the expense of a poorer resolution.
Our motto is deliver assignment on Time. Our Expert writers deliver quality assignments to the students.
Get reliable and unique assignments by using our 100% plagiarism-free.
Get connected 24*7 with our Live Chat support executives to receive instant solutions for your assignment.
Get Help with all the subjects like: Programming, Accounting, Finance, Engineering, Law and Marketing.
Get premium service at a pocket-friendly rate at AssignmentHippo
I was struggling so hard to complete my marketing assignment on brand development when I decided to finally reach to the experts of this portal. They certainly deliver perfect consistency and the desired format. The content prepared by the experts of this platform was simply amazing. I definitely owe my grades to them.