Study Aggregation Systems with Multiway Graphs as an approximation to the asymmetric tumor growth in a heterogeneous environment
Author
Lina Marcela Ruiz Galvis
Title
Study Aggregation Systems with Multiway Graphs as an approximation to the asymmetric tumor growth in a heterogeneous environment
Description
This is a first approach to the study of System Aggregation as a Multiway System to get insights into the rules behind the tumor growth
Category
Essays, Posts & Presentations
Keywords
System Aggregation, Multiway Systems, Tumor growth
URL
http://www.notebookarchive.org/2021-07-62nh6ox/
DOI
https://notebookarchive.org/2021-07-62nh6ox
Date Added
2021-07-13
Date Last Modified
2021-07-13
File Size
3.8 megabytes
Supplements
Rights
Redistribution rights reserved



WOLFRAM SUMMER SCHOOL 2021
Study Aggregation Systems with Multiway Graphs as an approximation to the asymmetric tumor growth in a heterogeneous environment
Study Aggregation Systems with Multiway Graphs as an approximation to the asymmetric tumor growth in a heterogeneous environment
Lina Marcela Ruiz Galvis
University of Antioquia
An Aggregation Systems can be simulated with a cellular automaton in which a randomness component is included in a totalistic rule. In each step a new cell is added at a randomly chosen location as long as this location matched the neighborhood pattern of one of the rules. Given an initial configuration and set of rules, the system could evolve through a finite number of new configurations to a fixed configuration in which the rules no longer apply or it could grow indefinitely . The final configuration may be reached by multiple different trajectories due to the inclusion of randomness, and thus represents a multiway system where it is possible to represent the whole set of possible states in time and space. Here we will study the structural properties of the multiway systems of different rule sets and random initial conditions. Finally, this is an approximation to the study of the asymmetric tumor growth in a heterogeneous environment where there are spatial and nutritional limitations in such way that it is not possible to grow continuously in space.
Introduction
Introduction
System Aggregation
System Aggregation
An Aggregation System describes the growth of clusters that follows a rule of aggregation. They can be simulated with a Cellular Automata with specific rules of growing. An example of this is the Eden growth model described in 1961 by Murray Eden. The idea of this model is to build up a cluster of black cells by adding just one new cell at each step . The position of this cell is chosen entirely at random, with the only constraint being that it should be adjacent to an existing cell in the cluster. However, the growing process could be more general and be described as follows: it occurs when a new black cell is added at each step and this happens in a position chosen at random among all the positions that have a certain number of black cells in its neighborhood.
The onePathSA function allows update one time step of a random CellularAutomaton. It is possible to use the whole set or rules of CellularAutomaton build-in function. To get a path of the system for thousands of time steps it should be used Nest or NestList.
onePathCA[rule_,iniCondi_]:=Module[{previousSatateAndPossibilities=({#1,Thread[Position[#2-#1,1]->1]}&@@CellularAutomaton[rule,{iniCondi,0},1(*steps*)])},NumericArray@ReplacePart[previousSatateAndPossibilities[[1]],previousSatateAndPossibilities[[2]]//RandomChoice]];(************************************************************)rule=<|"GrowthCases"->{1},"Dimension"->2,"Neighborhood"->"Moore"|>;init={{1}};states=NestList[onePathCA[rule,#]&,init,1000];systemAggregationExample=ArrayPlot/@states;ListAnimate[systemAggregationExample]
Out[]=
Here it is used the onePathCA function to get 4 images of the system each one after ten thousands steps. It means the last one is the update 40 000
figure1=Nest[onePathCA[rule,#]&,init,10000];ArrayPlot[figure1]figure2=Nest[onePathCA[rule,#]&,figure1,10000];ArrayPlot[figure2]figure3=Nest[onePathCA[rule,#]&,figure2,10000];ArrayPlot[figure3]figure4=Nest[onePathCA[rule,#]&,figure3,10000];ArrayPlot[figure4]
The randomness of this system is explicitly inserted from outside at each step in the evolution of the system. Due to this randomness the initial sates of the system are irregular and discontinuous but after many time steps it appears that continuous patterns of growth emerge. In this way the system aggregation in an example of a systems based on discrete components in which randomness at a microscopic level also leads to continuous behavior on a large scale. It happens because when randomness is present, such microscopic details often get averaged out, so that in the end no trace of discreteness is left, and the results appear to be smooth and continuous.
It is important to note that given an initial configuration and set of rules, the system could evolve through a finite number of new configurations to a fixed configuration in which the rules no longer apply. Or the system could grows indefinitely and form a continuous pattern as previously mentioned.
Multiway System of a System Aggregation
Multiway System of a System Aggregation
The update of a system aggregation in each time step represents one possible state from a set of possible states. It means that in each time step there are many possibilities to put a new black cell. And one realization of the system is only one path from a set of possible paths. The whole set of possible paths can be represented in a multiway system. And it could be explored the structural properties of the multiway graph to get insights into the growing pattern given a rule and initial condition.
To update the Multiway System and get the new possible states in each time steps it is used the functions newPossibilitiesSA, edgesAndNewPosibilitiesBystate, edgesAndNewPosibilitiesByAllstates, and iterationAllNewSates. To update the system for several steps it should be used Nest built-in function and to display the graph it should be used showGraph function. When the graph is big it is better to used Graph or GraphPlot build-in functions.
(*******************************Configuration*************************)rule=<|"GrowthCases"->{1},"Dimension"->2,"Neighborhood"->"Moore"|>;init={{1}};(******************TogettheMultiWaySystem************************)newPossibilitiesSA[rule_,iniCondi_]:=Module[{previousSatateAndPossibilities=({#1,Thread[Position[#2-#1,1]->1]}&@@CellularAutomaton[rule,{iniCondi,0},1(*steps*)])},Map[SparseArray@ReplacePart[previousSatateAndPossibilities[[1]],#]&,previousSatateAndPossibilities[[2]]]]edgesAndNewPosibilitiesBystate[state_,rule_]:=Thread[Hold[state]->newPossibilitiesSA[rule,state]]edgesAndNewPosibilitiesByAllstates[states_,rule_]:=Module[{edges},edges=ParallelMap[edgesAndNewPosibilitiesBystate[#,rule]&,states,Method"CoarsestGrained"];graph["Insert",edges];edges[[All,All,2]]]iterationAllNewSates[state_,rule_]:=DeleteDuplicates[Flatten[edgesAndNewPosibilitiesByAllstates[state,rule],1]](****************************Toplot*******************************)showGraph[g_]:=Graph[g,VertexShape((#->ArrayPlot[#,ImageSize15])&/@VertexList[g]),GraphLayout"LayeredDigraphEmbedding",ImageSizeFull,EdgeStyleOpacity[0.4,Red]];
As an example of the Multiway System of a System Aggregation it is used the set of functions to update the system from one initial black cell to the addition of a second one.
graph=CreateDataStructure["OrderedHashSet"];Nest[iterationAllNewSates[#,rule]&,{init},1];showGraph[ReleaseHold[Flatten[(#//Normal)]]]&@(Normal[graph])
Each one of the previous states is updated to get the next set of new possible state of the system.
graph=CreateDataStructure["OrderedHashSet"];Nest[iterationAllNewSates[#,rule]&,{init},2];showGraph[ReleaseHold[Flatten[(#//Normal)]]]&@(Normal[graph])
Out[]=
In a next iteration, the system becomes bigger. This is a example of a System Aggregation that grow exponentially.
graph=CreateDataStructure["OrderedHashSet"];Nest[iterationAllNewSates[#,rule]&,{init},3];Graph[ReleaseHold[Flatten[(#//Normal)]],ImageSizeMedium,EdgeStyleOpacity[0.4,Red],VertexStyleBlack]&@(Normal[graph])
Objective
Objective
Here it will be explored the structural properties of the Multiway System of a System Aggregation. The structural properties to evaluate are the number of new states in each time step, the vertex degree of input edges in each time step and in the whole system, the vertex degree of output edges in each time step and in the whole system, and the number of time steps that happen before the system stop its growth. These will be evaluated for a set of rules and random initial conditions.
Application
Application
This is an approximation to the study of the asymmetric tumor growth in a heterogeneous environment where there are spatial and nutritional limitations in such way that it is not possible to grow continuously in space
Experiments description
Experiments description
Rules
Rules
With the set of functions in this project it is possible to simulate whatever rule of the CellularAutomaton Built-in function. Specifically, for a System Aggregation it is used the keys “GrowthCases”, “Dimensions”, and “Neighborhood” to specify the rule as an Association. And to specify other rules of aggregation it was build a set of functions. The rules are described in the next table and some of them are plotted. Additionally, the whole set of rules are applied in two dimensions and in a Moore neighborhood
In[]:=
{{"N°","Rule expression","Description"},{"1",<|"GrowthCases"->{3},"Dimension"->2,"Neighborhood"->"Moore"|>,"Exaclty 3 neighbors in wathever position"},{"2",<|"GrowthCases"->{4},"Dimension"->2,"Neighborhood"->"Moore"|>,"Exactly 4 neighbors in wathever position"},{"3","r3[{{a_,b_,c_},{d_,i_,f_},{g_,j_,l_}}]:=If[Total[{a,b,c,d,i,f,g,j,l}]==3&&MemberQ[{{a,b,c},{b,c,f},{c,f,l},{f,l,j},{l,j,g},{j,g,d},{g,d,a},{d,a,b}},{1,1,1}],1,i]","Exaclty 3 neighbors in consecutive position"},{"4","r4[{{a_,b_,c_},{d_,i_,f_},{g_,j_,l_}}]:=If[Total[{a,b,c,d,i,f,g,j,l}]==4&&MemberQ[{{a,b,c,f},{b,c,f,l},{c,f,l,j},{f,l,j,g},{l,j,g,d},{j,g,d,a},{g,d,a,b},{d,a,b,c}},{1,1,1,1}],1,i]","Exaclty 4 neighbors in consecutive position"},{"5","r3[{{a_,b_,c_},{d_,i_,f_},{g_,j_,l_}}]:=If[MemberQ[{{a,b,c},{b,c,f},{c,f,l},{f,l,j},{l,j,g},{j,g,d},{g,d,a},{d,a,b}},{1,1,1}],1,i]","Minimum 3 neighbors in consecutive position"},{"6","r4[{{a_,b_,c_},{d_,i_,f_},{g_,j_,l_}}]:=If[MemberQ[{{a,b,c,f},{b,c,f,l},{c,f,l,j},{f,l,j,g},{l,j,g,d},{j,g,d,a},{g,d,a,b},{d,a,b,c}},{1,1,1,1}],1,i]","Minimum 4 neighbors in consecutive position"}}//Grid[#,FrameAll]&
Out[]=
N° | Rule expression | Description |
1 | GrowthCases{3},Dimension2,NeighborhoodMoore | Exaclty 3 neighbors in wathever position |
2 | GrowthCases{4},Dimension2,NeighborhoodMoore | Exactly 4 neighbors in wathever position |
3 | r3[{{a_,b_,c_},{d_,i_,f_},{g_,j_,l_}}]:=If[Total[{a,b,c,d,i,f,g,j,l}]==3&&MemberQ[{{a,b,c},{b,c,f},{c,f,l},{f,l,j},{l,j,g},{j,g,d},{g,d,a},{d,a,b}},{1,1,1}],1,i] | Exaclty 3 neighbors in consecutive position |
4 | r4[{{a_,b_,c_},{d_,i_,f_},{g_,j_,l_}}]:=If[Total[{a,b,c,d,i,f,g,j,l}]==4&&MemberQ[{{a,b,c,f},{b,c,f,l},{c,f,l,j},{f,l,j,g},{l,j,g,d},{j,g,d,a},{g,d,a,b},{d,a,b,c}},{1,1,1,1}],1,i] | Exaclty 4 neighbors in consecutive position |
5 | r3[{{a_,b_,c_},{d_,i_,f_},{g_,j_,l_}}]:=If[MemberQ[{{a,b,c},{b,c,f},{c,f,l},{f,l,j},{l,j,g},{j,g,d},{g,d,a},{d,a,b}},{1,1,1}],1,i] | Minimum 3 neighbors in consecutive position |
6 | r4[{{a_,b_,c_},{d_,i_,f_},{g_,j_,l_}}]:=If[MemberQ[{{a,b,c,f},{b,c,f,l},{c,f,l,j},{f,l,j,g},{l,j,g,d},{j,g,d,a},{g,d,a,b},{d,a,b,c}},{1,1,1,1}],1,i] | Minimum 4 neighbors in consecutive position |
This is for a graphic representation of rule 1. Rule 2 is almost the same but with more neighbors
RulePlot[CellularAutomaton["GrowthCases"{3},"Dimension"2,"Neighborhood""Moore"]]
Out[]=
This is for a graphic representation of rule 3. Rule 4 is almost the same but with more neighbors
ArrayPlot[SparseArray[{{1,2}->1,{1,3}->1,{2,3}->1},3],ImageSizeSmall,MeshTrue]->ArrayPlot[SparseArray[{{1,2}->1,{1,3}->1,{2,3}->1,{2,2}->1},3],ImageSizeSmall,MeshTrue]
Out[]=
This is for a graphic representation of rule 5. Rule 6 is almost the same but with more neighbors. For these are required a consecutive number of black neighbors cells and it could be other neighbors in whatever position.
In[]:=
ArrayPlot[SparseArray[{{1,2}->1,{1,3}->1,{2,3}->1,{3,1}->1},3],ImageSizeSmall,MeshTrue]->ArrayPlot[SparseArray[{{1,2}->1,{1,3}->1,{2,3}->1,{2,2}->1,{2,2}->1,{3,1}->1},3],ImageSizeSmall,MeshTrue]
Out[]=
Initial Conditions
Initial Conditions
The simulations were performed with a random set of initial conditions in which the probability to have a black cell (wBlack) was 0.3 or 0.7.
This is a graphic representation of initial conditions.
In[]:=
init=Table[SparseArray@RandomChoice[{wBlack,1-wBlack}->{1,0},{5,5}],{wBlack,{0.3,0.7}}];ArrayPlot[#,MeshTrue]&/@init
Out[]=
,
Simulations
Simulations
For those System Aggregation with small and finite growth, it was used the set of functions previously showed for the Multiway System but it was take off the option Parallelize from edgesAndNewPosibilitiesByAllstates
The function newPossibilitiesSA gives the new possible states from one previous state. The function edgesAndNewPosibilitiesBystate built the edges list of the MultiWay Graph. The function edgesAndNewPosibilitiesByAllstates maps the previous functions in the whole set of previous states and it gets the whole set of new edges, it save them in a global variable (graph) and return the new states. The function iterationAllNewSates deletes from the new states those who are duplicates and return the new states to be updated.
(***************TogettheMultiWaySystem*****************)newPossibilitiesSA[rule_,iniCondi_]:=Module[{previousSatateAndPossibilities=({#1,Thread[Position[#2-#1,1]->1]}&@@CellularAutomaton[rule,{iniCondi,0},1(*steps*)])},Map[SparseArray@ReplacePart[previousSatateAndPossibilities[[1]],#]&,previousSatateAndPossibilities[[2]]]]edgesAndNewPosibilitiesBystate[state_,rule_]:=Thread[Hold[state]->newPossibilitiesSA[rule,state]]edgesAndNewPosibilitiesByAllstates[states_,rule_]:=Module[{newEdges},newEdges=Map[edgesAndNewPosibilitiesBystate[#,rule]&,states];graph["Insert",newEdges];newEdges[[All,All,2]]]iterationAllNewSates[state_,rule_]:=DeleteDuplicates[Flatten[edgesAndNewPosibilitiesByAllstates[state,rule],1]](******************Toconfiguratetheparallelization*************)DistributeDefinitions[newPossibilitiesSA,edgesAndNewPosibilitiesBystate];LaunchKernels[];graphList={};SetSharedVariable[graphList](*******************Loop*************)ParallelDo[graph=CreateDataStructure["OrderedHashSet"];Nest[iterationAllNewSates3[#,rule]&,{init},steps];AppendTo[graphList,graph];,rep,Method"CoarsestGrained"](****************************************************************************************************)
For those System Aggregation with big and indefinite growth, it was used the set of functions previously showed for the Multiway System without any modification.
The function newPossibilitiesSA gives the new possible states from one previous state. The function edgesAndNewPosibilitiesBystate built the edges list of the MultiWay Graph. The function edgesAndNewPosibilitiesByAllstates maps in parallel the previous functions in the whole set of previous states and it gets the whole set of new edges, it save them in a global variable (graph) and return the new states. The function iterationAllNewSates deletes from the new states those who are duplicates and return the new states to be updated.
(******************TogettheMultiWaySystem************************)newPossibilitiesSA[rule_,iniCondi_]:=Module[{previousSatateAndPossibilities=({#1,Thread[Position[#2-#1,1]->1]}&@@CellularAutomaton[rule,{iniCondi,0},1(*steps*)])},Map[SparseArray@ReplacePart[previousSatateAndPossibilities[[1]],#]&,previousSatateAndPossibilities[[2]]]]edgesAndNewPosibilitiesBystate[state_,rule_]:=Thread[Hold[state]->newPossibilitiesSA[rule,state]]edgesAndNewPosibilitiesByAllstates[states_,rule_]:=Module[{edges},edges=ParallelMap[edgesAndNewPosibilitiesBystate[#,rule]&,states,Method"CoarsestGrained"];graph["Insert",edges];edges[[All,All,2]]]iterationAllNewSates[state_,rule_]:=DeleteDuplicates[Flatten[edgesAndNewPosibilitiesByAllstates[state,rule],1]](******************Toconfiguratetheparallelization*************)DistributeDefinitions[newPossibilitiesSA,edgesAndNewPosibilitiesBystate];LaunchKernels[];graphList={};(*******************Loop*************)Do[graph=CreateDataStructure["OrderedHashSet"];Nest[iterationAllNewSates3[#,rule]&,{init},steps];AppendTo[graphList,graph];,rep](***************************************************************************************************************************)
Analysis
Analysis
To analyze the structural properties of the Multiway System and its graph it was made the next plots:
The graphList contains all the graphs of each simulation. Each graph contains all the information necessary to analyze the system. The first thing is to order the edges of each graph from the graphList. In this way it is possible to get orderly the new edges and states in each time step for each graphs in graphList.
primero=ParallelMap[{#[[1]],Count[Flatten[#[[1]]],1]}->{#[[2]],Count[Flatten[Normal[#[[2]]]],1]}&,ReleaseHold[Flatten[Normal[#]]]&/@graphList,{2},Method->"CoarsestGrained"];segundo=Table[SortBy[GatherBy[i,#[[1,2]]&],#[[1,2]]&],{i,primero}];
Then it is measured the new states in each time steps for each graph and it is plotted the Mean of new states in each time step for all graphs.
newStatesInEachStep1=ParallelMap[{#,Length[#]}&,DeleteCases[Map[Length[DeleteDuplicates[#[[All,2]]]]&,segundo,{2}],{}],Method->"CoarsestGrained"];graphMaximalSteps=Max[newStatesInEachStep1[[All,2]]];data1=Mean[PadRight[#,graphMaximalSteps]&/@newStatesInEachStep1[[All,1]]];plot1=ListLinePlot[data1,Frame->True,FrameLabel->{"time","Number of possible states"},PlotLabel->"Number of possible states in each step",PlotStyle->Red,PlotRange->All];
Then it is measured the Convergence Level in time as the Mean of the vertex degree of input edges in each time step for all graphs.
In[]:=
data2=Mean[DeleteCases[Flatten[#],0]]&/@Transpose@(PadRight[#,graphMaximalSteps,List[{}]]&/@Map[VertexInDegree,segundo,{2}]);plot2=ListLinePlot[data2(*deletethe0sbecauseitrepresentstheinputoftheprevioussate*),Frame->True,FrameLabel->{"time","VertexInDegree"},PlotLabel->"Covergence level in time",PlotStyle->Red,PlotRange->All];
Then it is measured the Divergence Level in time as the Mean of the vertex degree of output edges in each time step for all graphs.
In[]:=
data3=Mean[DeleteCases[Flatten[#],0]]&/@Transpose@(PadRight[#,graphMaximalSteps,List[{}]]&/@Map[VertexOutDegree,segundo,{2}]);plot3=ListLinePlot[data3(*deletethe0sbecauseitrepresentstheinputoftheprevioussate*),Frame->True,FrameLabel->{"time","VertexOutDegree"},PlotLabel->"Divergence level in time",PlotStyle->Red,PlotRange->All];
Then it is plotted the number of time steps that happen before the system stop its growth
In[]:=
data4=newStatesInEachStep1[[All,2]];plot4=Histogram[data4,Automatic,"PDF",Frame->True,FrameLabel->{"Total number of steps","PDF"},PlotLabel->"Number of steps until stop growing"<>"\n %ocurrence: "<>ToString[Length@newStatesInEachStep1[[All,2]]/rep//N],ChartStyle->Opacity[0.7,Black]];
For small graphs it used this code which puts the plot of the states in each vertex
plot5=showGraph[ReleaseHold[Flatten[(#//Normal)]]]&/@(Normal[graphList])
For big graphs it used this code which does not puts the plot of the states in each vertex
plot5=Graph[ReleaseHold[Flatten[(#//Normal)]],EdgeStyleOpacity[0.4,Red]]&/@(Normal[graphList]);
Then it is measured the Convergence Level for the whole systems. It means for the whole graph of each graphs in graphList
In[]:=
data6=DeleteCases[Flatten[#],0]&@(VertexInDegree/@plot5);plot6=Histogram[data6,Automatic,"PDF",Frame->True,FrameLabel->{"Degree of input vertices","PDF"},PlotLabel->"Covergence level",ChartStyle->Opacity[0.5,Black]];
Then it is measured the Divergence Level for the whole systems. It means for the whole graph of each graphs in graphList
In[]:=
data7=DeleteCases[Flatten[#],0]&@(VertexOutDegree/@plot5);plot7=Histogram[data7,Automatic,"PDF",Frame->True,FrameLabel->{"Degree of output vertices","PDF"},PlotLabel->"Divergence level",ChartStyle->Opacity[0.3,Black]];
This function allows to get one path of the Multiway System that grows indefinitely
randomPath[graph_,state_]:=Module[{edges,chosenedge},edges=EdgeList[graph,state_];If[Length[edges]>0,chosenedge=RandomChoice[edges];Prepend[randomPath[graph,chosenedge[[2]]],chosenedge],{}]];plot8=showGraph[randomPath[plot5[[1]],Normal[init]]];
To export the plots and data
In[]:=
Export["plot1_"<>case<>".png",plot1];Export["plot2_"<>case<>".png",plot2];Export["plot3_"<>case<>".png",plot3];Export["plot4_"<>case<>".png",plot4];Export["plot6_"<>case<>".png",plot6];Export["plot7_"<>case<>".png",plot7];Export["plot8_"<>case<>".png",plot8];Export["data1_"<>case<>".csv",data1];Export["data2_"<>case<>".csv",data2];Export["data3_"<>case<>".csv",data3];Export["data4_"<>case<>".csv",data4];Export["data6_"<>case<>".csv",data6];Export["data7_"<>case<>".csv",data7];
Results
Results
It was made a set of simulations that are summary in the next table:
In[]:=
k=1;{{"Case","Rule","Initial condition","time steps","replicates"},Sequence@@Flatten[#,1]&@Table[{ToString[k++],"rule"<>ToString[i],"wBlack:"<>j},{i,6},{j,{"0.3","0.7"}}]};cases={{"Case","Rule","Initial condition","time steps","replicates"},{"1","rule1 ","wBlack:0.3",15,10},{"2","rule1 ","wBlack:0.7",15,10},{"3","rule2 ","wBlack:0.3",20,1000},{"4","rule2 ","wBlack:0.7",20,1000},{"5","rule3 ","wBlack:0.3",15,10},{"6","rule3 ","wBlack:0.7",15,10},{"7","rule4 ","wBlack:0.3",20,1000},{"8","rule4 ","wBlack:0.7",20,1000},{"9","rule5 ","wBlack:0.3",15,10},{"10","rule5 ","wBlack:0.7",15,10},{"11","rule6 ","wBlack:0.3",20,1000},{"12","rule6 ","wBlack:0.7",20,1000}};cases//Grid[#,FrameAll]&
Out[]=
Case | Rule | Initial condition | time steps | replicates |
1 | rule1 | wBlack:0.3 | 15 | 10 |
2 | rule1 | wBlack:0.7 | 15 | 10 |
3 | rule2 | wBlack:0.3 | 20 | 1000 |
4 | rule2 | wBlack:0.7 | 20 | 1000 |
5 | rule3 | wBlack:0.3 | 15 | 10 |
6 | rule3 | wBlack:0.7 | 15 | 10 |
7 | rule4 | wBlack:0.3 | 20 | 1000 |
8 | rule4 | wBlack:0.7 | 20 | 1000 |
9 | rule5 | wBlack:0.3 | 15 | 10 |
10 | rule5 | wBlack:0.7 | 15 | 10 |
11 | rule6 | wBlack:0.3 | 20 | 1000 |
12 | rule6 | wBlack:0.7 | 20 | 1000 |
The plots of the number of possible states in each time step show that for rules with less constraint (i.e. rules 1, 5, and 3) the growth is exponential. Rule 5 has more similar to rule 1 in its effect on growth than rule 3. The rules with higher constraints (i.e. rules 6, 4, and 2) drive a small growth and early stop in growing. The effect of the initial conditions is more evident in the rules with less constraint and the growth clearly increases when with the increase of black cells at the start.
Here it is uploaded the plots of the Number of possible states in each time step
In[]:=
SetDirectory["/home/lina/Documents/projectWSS2021/results/"];MapThread[Labeled[#1,Sequence@@StringJoin[#2],Top]&,{Table[Import["plot1_"<>ToString[case]<>".png"],{case,12}],cases[[2;;-1,2;;3]]}]
Out[]=
,
,
,
,
,
,
,
,
,
,
,
rule1 wBlack:0.3 |
rule1 wBlack:0.7 |
rule2 wBlack:0.3 |
rule2 wBlack:0.7 |
rule3 wBlack:0.3 |
rule3 wBlack:0.7 |
rule4 wBlack:0.3 |
rule4 wBlack:0.7 |
rule5 wBlack:0.3 |
rule5 wBlack:0.7 |
rule6 wBlack:0.3 |
rule6 wBlack:0.7 |
While the number of new states in time differs in orders of magnitude between rules, this does not happen with the level of convergence in time. The convergence level is low and it increases slowly in time. And in general, it looks very similar between rules and initial conditions. According to these plots. It appears that the growing systems do not converge a lot.
Here it is uploaded the plots of the Convergence level in each time step
In[]:=
MapThread[Labeled[#1,Sequence@@StringJoin[#2],Top]&,{Table[Import["plot2_"<>ToString[case]<>".png"],{case,12}],cases[[2;;-1,2;;3]]}]
Out[]=
,
,
,
,
,
,
,
,
,
,
,
rule1 wBlack:0.3 |
rule1 wBlack:0.7 |
rule2 wBlack:0.3 |
rule2 wBlack:0.7 |
rule3 wBlack:0.3 |
rule3 wBlack:0.7 |
rule4 wBlack:0.3 |
rule4 wBlack:0.7 |
rule5 wBlack:0.3 |
rule5 wBlack:0.7 |
rule6 wBlack:0.3 |
rule6 wBlack:0.7 |
Although the divergence as the convergence does not differ in orders of magnitude it is known that these little differences between rules drive big differences in a system that could grow exponentially. For the rules with the lowest constraints, the divergence increases slowly but it is necessary to make new simulations to see the long-time behaviour. As expected, the divergence is lowest at the end of the growth for rules with higher constraints.
Here it is uploaded the plots of the Divergence level in each time step
In[]:=
MapThread[Labeled[#1,Sequence@@StringJoin[#2],Top]&,{Table[Import["plot3_"<>ToString[case]<>".png"],{case,12}],cases[[2;;-1,2;;3]]}]
Out[]=
,
,
,
,
,
,
,
,
,
,
,
rule1 wBlack:0.3 |
rule1 wBlack:0.7 |
rule2 wBlack:0.3 |
rule2 wBlack:0.7 |
rule3 wBlack:0.3 |
rule3 wBlack:0.7 |
rule4 wBlack:0.3 |
rule4 wBlack:0.7 |
rule5 wBlack:0.3 |
rule5 wBlack:0.7 |
rule6 wBlack:0.3 |
rule6 wBlack:0.7 |
For the rule with lest constraint (i.e rule 1) the growth happens in almost all the replicates (i.e.% occurrence 0.8-1) and for the whole time of the simulation. For rules 3 and 5, the growth in the whole time of simulation only occurs for some replicates (i.e.% occurrence 0.4, 0.6, and 0.7). For the rules with higher constraints, the percentage of occurrence is lower and in any case, they always stop growing before the last time update.
Here it is uploaded the plots of the Number of steps until stop growing. Which also show the percentage of occurrence (% occurrence) between the replicates.
In[]:=
MapThread[Labeled[#1,Sequence@@StringJoin[#2],Top]&,{Table[Import["plot4_"<>ToString[case]<>".png"],{case,12}],cases[[2;;-1,2;;3]]}]
Out[]=
,
,
,
,
,
,
,
,
,
,
,
rule1 wBlack:0.3 |
rule1 wBlack:0.7 |
rule2 wBlack:0.3 |
rule2 wBlack:0.7 |
rule3 wBlack:0.3 |
rule3 wBlack:0.7 |
rule4 wBlack:0.3 |
rule4 wBlack:0.7 |
rule5 wBlack:0.3 |
rule5 wBlack:0.7 |
rule6 wBlack:0.3 |
rule6 wBlack:0.7 |
With these plots of the convergence level for the whole Multiway graph, it is possible to see that the convergence could be more different between rules than previously seen. It means that the temporal mean of the convergence represented in the previous temporal plot is not a good approximation to this variable. And it also means that the convergence level is bigger for the rules with lower constraints.
Here it is uploaded the plots of the Convergence level for the whole graph
In[]:=
MapThread[Labeled[#1,Sequence@@StringJoin[#2],Top]&,{Table[Import["plot6_"<>ToString[case]<>".png"],{case,12}],cases[[2;;-1,2;;3]]}]
Out[]=
,
,
,
,
,
,
,
,
,
,
,
rule1 wBlack:0.3 |
rule1 wBlack:0.7 |
rule2 wBlack:0.3 |
rule2 wBlack:0.7 |
rule3 wBlack:0.3 |
rule3 wBlack:0.7 |
rule4 wBlack:0.3 |
rule4 wBlack:0.7 |
rule5 wBlack:0.3 |
rule5 wBlack:0.7 |
rule6 wBlack:0.3 |
rule6 wBlack:0.7 |
According to these plots the divergence level represented in the previous temporal plots is a good approximation for the rules with lower constraints but not for those with higher constraints. And also as was previously mentioned the first ones diverge more than the second ones.
Here it is uploaded the plots of the Convergence level for the whole graph
In[]:=
MapThread[Labeled[#1,Sequence@@StringJoin[#2],Top]&,{Table[Import["plot7_"<>ToString[case]<>".png"],{case,12}],cases[[2;;-1,2;;3]]}]
Out[]=
,
,
,
,
,
,
,
,
,
,
,
rule1 wBlack:0.3 |
rule1 wBlack:0.7 |
rule2 wBlack:0.3 |
rule2 wBlack:0.7 |
rule3 wBlack:0.3 |
rule3 wBlack:0.7 |
rule4 wBlack:0.3 |
rule4 wBlack:0.7 |
rule5 wBlack:0.3 |
rule5 wBlack:0.7 |
rule6 wBlack:0.3 |
rule6 wBlack:0.7 |
Finally, the next table shows some of the multiway systems that are getting for each rule. For those rules which drive a big growth (i.e. rule1, rule4, and rule 5) the system is only updated 5 times and some possible path are shown.
Here it is imported some of the multiway systems with the plot of each state as a vertex
In[]:=
{{"Rule 1"},{""},{"Rule 2"},{},{"Rule 3"},{},{"Rule 4"},{""},{"Rule 5"},{},{"Rule 6"},{}}//Grid[#,FrameAll]&
"Rule 1" |
"Rule 2" |
"Rule 3" |
"Rule 4" |
"Rule 5" |
"Rule 6" |
Concluding remarks
Concluding remarks
■
Here it was explored some minimal conditions for growth in a System Aggregation. This due to it was not possible to simulate for long time periods the multiway systems that grow exponentially.
■
Random initial conditions represents in a better way the initial states of tumor growing.
■
The rule is the main driver of the growth pattern and the initial conditions do not have a major impact on this pattern. However, the initial conditions determine if the system starts growing.
■
It was build an efficient and simple function to track the growth of a System Aggregation.
■
The set of functions to get the Multiway System of a System Aggregation work well for rules that drive small growth. However for rules that drives exponential growth it is necessary to improve the performance of the functions in such way that it is spent less memory. One possible idea is to split the possible new states in groups that are evaluated sequentially but evaluate in parallel each group. In this way it is reduced the amount of memory require to process the states in each iteration.
Keywords
Keywords
◼
System Aggregation
◼
Multiway System
◼
Tumor growth
Acknowledgment
Acknowledgment
I would like to express my special thanks of gratitude to Stephen Wolfram who gave me the golden opportunity to do this wonderful Summer School and project. My special thanks to my mentor Jesse Galef for the constant support and very nice ideas. Also thanks to Robert Nachbar and Xerxes Arsiwalla for their advice. I also wanted to thanks the TAs team in special to Jesse Friedman, Daniel Sanchez, and Silvia Hao. And last but not least thanks to Erin Cherry, Mads Bahrami, and Danielle Rommel.
References
References


Cite this as: Lina Marcela Ruiz Galvis, "Study Aggregation Systems with Multiway Graphs as an approximation to the asymmetric tumor growth in a heterogeneous environment" from the Notebook Archive (2021), https://notebookarchive.org/2021-07-62nh6ox

Download

