Collagen
Model was written in NetLogo 5.0.5
•
Viewed 392 times
•
Downloaded 38 times
•
Run 0 times
Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)
Comments and Questions
Click to Run Model
breed [collagen] breed [inhibitor] turtles-own [ ;; The easiest way to handle the clusters is to designate one ;; node in the cluster as the "leader". It doesn't really matter ;; which node it is; the choice is arbitrary, but it gives us a way ;; to identify the cluster. Every node knows who the leader of ;; its cluster is. leader ;; This is used to make all of the nodes in a cluster turn by ;; the same number of degrees. Each leader chooses a random ;; amount, then everyone else uses the amount from their leader. turn-amount ] collagen-own [ blocked ] to setup clear-all set-default-shape collagen "collagen" set-default-shape inhibitor "circle" create-collagen population [ set size 2.5 set color white setxy random-xcor random-ycor rt random-float 360 ;; initially, every node leads its own cluster of one set leader self set blocked 0] create-inhibitor Inhibitors ; number of inhibitors from slider [ set color green set size 0.5 setxy random-xcor random-ycor rt random-float 360 ;; initially, every node leads its own cluster of one set leader self] reset-ticks end to go ;; All the leaders choose turn amounts ask collagen with [leader = self] [ set turn-amount 0 ;random 10 - random 10 ] ;; All nodes follow their leaders ask collagen [ rt [turn-amount] of leader fd 0.1 ] ask inhibitor with [leader = self] [ set turn-amount random 10 - random 10 ] ask inhibitor [ rt [turn-amount] of leader fd 0.1 ] ;; Here's the tricky part. We check whether any pairs ;; of clusters are touching, and if they are, we merge them. ask collagen [ ifelse blocked < 3 [let candidates collagen in-radius 1 with [leader != [leader] of myself] if any? candidates [ create-links-with candidates [ hide-link ] ask candidates [ merge ] ] ] [ stop ] let binders inhibitor in-radius 1 with [leader != [leader] of myself] if any? binders [ create-links-with binders [ hide-link ] set blocked blocked + 1 ask binders [ merge ] ] ] ; do-plots tick end ;to do-plots ; set-current-plot "Width" ; set-current-plot-pen "max group" ; plot count collagen ; end ;; This is a recursive procedure -- it calls itself. ;; That way the new leader propagates through the entire ;; cluster. to merge ;; node procedure ;; First this node merges. set leader [leader] of myself set heading [heading] of leader set color yellow ;; Then any neighboring nodes that haven't merged yet ;; merge. ask link-neighbors with [leader != [leader] of myself] [ merge ] end ; Public Domain: ; To the extent possible under law, Uri Wilensky has waived all ; copyright and related or neighboring rights to this model. ; ; Modified March 4, 2014 ; George Dombi
There are 3 versions of this model.
Attached files
File | Type | Description | Last updated | |
---|---|---|---|---|
Collagen.png | preview | Collagen and inhibitors | almost 11 years ago, by George Dombi | Download |
Collagen02_5.1 view.png | png | Start-up image | almost 11 years ago, by George Dombi | Download |
This model does not have any ancestors.
This model does not have any descendants.
George Dombi
Collagen (Question)
Hi, I need some help. I have a series of questions, but 2 at a time. 1) I have a model with 2 breeds. Rod shaped collagen and circle shaped inhibitor. As set-up now, collagen rods interact. How do I get inhibitor circles to interact with collagen rods but not with each other. 2) If a inhibitor circle binds to a collagen rod, no other rod can bind to the circle, but another collagen rod can bind to the first. 3) if two or more inhibitor circles bind to a collagen rod, then it is out of action and nothing else can bind. 4) is there a way to plot the average number of collagen rods in a the various clusters?
Posted almost 11 years ago
Cecilia Herbert
Clue (edited)
Hi, I only briefly looked at your code, but I have some ideas that might or might not help. 1) I don't see any inhibitors interacting with each other. Could you maybe give an example of where this happens? 2) and 3) Maybe you could specify a property for each breed which gives information on its linked status. Ex: inhibitor-own [bound] and collagen-own [blocked]. When you merge clusters in your ask collagen procedure, you could set the bound property of inhibitors to yes whenever collagen binds to inhibitor. For the blocked property of collagen, you could have a counter. +1 for each inhibitor that the collagen merges to, up to a max of 2. At the beginning of the ask collagen procedure, you would have to check and see if bound = yes, ignore that inhibitor. If blocked = 2, ignore that collagen rod. Otherwise, proceed with merge. 4) Isn't this count collagen/# leaders ? Hope any of this helps.
Posted almost 11 years ago
George Dombi
Collagen model - inhibitors don't interact.
Hi Cecilia, I took your advice, as I could implement it and now the collagen binds only 2 inhibitors before no longer binding to self. This is a definite improvement. Now what to know how to change leader so that when single collagen binds to an existing group, the direction of the leader is in the group not the direction of the newly added collagen. Please take a look when you have time. Bye for now, George
Posted over 10 years ago