How can set a layer of cells that get together like a thin film?

10 months ago by
I want to use some cells set a thin film but when model starts running those cells won't stay together and disperse. I know "Cell Type" plugin that has a function named  "freeze". But the "Freeze" function will not let cells to be altered by pixel copies. I wonder if there are some other methods which can keep cells stay together like a film during simulation.
Community: CompuCell3D

3 Answers

10 months ago by
There are a couple ways to make cells form a layer.
1. You can have the cells stick to the wall of the bounding box (but then you can only access one face of the cell layer).
2. You could make a curved cell layer ala the cell sorting demos where your cell layer is actually spherical (the "noncondensing" cells in the cell sort demos).
3. You can use compartmentalized cells that have basal, apical and lateral faces defined.
4. You can add distance constraints between cells using "Elasticity Plugin" or "FocalPointPlasticity Plugin". Constraints on contact neighbors keep the sheet intact. If the distance constraints go beyond first neighbors then the constraint will tend to keep the sheet flat.


Are you working in 2D or 3D?
I agree with Jim's 4. suggestion. This would be the most robust way to have cells stay together. Relying purely on contact energy may not be sufficient. It would help us if you could post the geometry of the tissue you are trying to model. 
written 10 months ago by Maciek Swat  
i just want to make cells form a layer to simulate a rectangular hydrogel film,so that i can simulate the mechanical properties of hydrogel in simulation。
written 10 months ago by dali Zan  
If the hydrogel is coating some object (e.g. tissue) then all you need to do is to create a blob of tissue, cover it with gel and choose appropriate adhesion (ContactPlugin) coefficients

<CompuCell3D Revision="20170429" Version="3.7.6">
      <Dimensions x="100" y="100" z="1"/>
   <Plugin Name="CellType">
      <CellType TypeId="0" TypeName="Medium"/>
      <CellType TypeId="1" TypeName="Gel"/>
      <CellType TypeId="2" TypeName="Tissue"/>
   <Plugin Name="Volume"/>
   <Plugin Name="CenterOfMass"/>
   <Plugin Name="Contact">
      <Energy Type1="Medium" Type2="Medium">10.0</Energy>
      <Energy Type1="Medium" Type2="Gel">25.0</Energy>
      <Energy Type1="Medium" Type2="Tissue">25.0</Energy>
      <Energy Type1="Gel" Type2="Gel">12.0</Energy>
      <Energy Type1="Tissue" Type2="Tissue">5.0</Energy>
      <Energy Type1="Gel" Type2="Tissue">10.0</Energy>
import sys
from os import environ
from os import getcwd
import string


import CompuCellSetup

sim,simthread = CompuCellSetup.getCoreSimulationObjects()
# add extra attributes here
# Definitions of additional Python-managed fields go here
#Add Python steppables here
from HydrogelSteppables import HydrogelSteppable
from PySteppables import *
import CompuCell
import sys

class HydrogelSteppable(SteppableBasePy):    

    def __init__(self,_simulator,_frequency=1):
        SteppableBasePy.__init__(self, _simulator, _frequency)
    def start(self):
        cell_size = 5
        rows = 10
        cols = 10
        blob_pos_vec = [20, 20, 0]
        for r in range(rows):
            for c in range(cols):            
                new_cell = self.newCell(self.TISSUE) 
                x_pos = r*cell_size + blob_pos_vec[0]
                y_pos = c*cell_size + blob_pos_vec[1]
                self.cellField[x_pos:x_pos+cell_size, y_pos:y_pos+cell_size, 0] = new_cell
                if r==0 or c==0 or r==rows-1 or c==cols-1:
                    new_cell.type = self.GEL    

        #setting up volume constraint
        for cell in self. cellList:
            cell.targetVolume = 25
            cell.lambdaVolume = 2.0
            if cell.type == self.GEL:
                cell.targetVolume = 30
                cell.lambdaVolume = 2.0
    def step(self,mcs):        


Let me know if this helps. If you are looking for a different initial geometry let us know but the idea will be similar. If you want to avoid blob-like shape but prefer a flat layer of cells. then you might need to use PeriodicBoundary Conditions for Cell Lattice along x-direction (assuming that your layer will be spread along x direction)
written 10 months ago by Maciek Swat  
Deeply thanks for your help,and sorry for my unclear expression. The tissue is not coated by hydrogel but cultured on hydrogel. Assuming a simulation has 2 units of z axis, one unit is a layer of hydrogel and another unit is a 2d tissue cultured on that hydrogel. Can this be achieved in cc3d?  
written 10 months ago by dali Zan  
10 months ago by
"Playing" with the contact energy may help. If the contact energy between cells of the same type is decreased, affinity is increased, so dispersion is less likely, though they may clump together instead. For a layer of cells (L) sitting on top of another group of cells (S), you want the contact energies to be S-S < S-L < L-L < L-medium I believe.
thanks for your help
written 10 months ago by dali Zan  
10 months ago by
Attached is a zip file with a CC3D model of a layer of cells in 2D (basically a line of cells). The line is maintained using focal point plasticity links. The sim first creates the line of cells, it then displaces the central cell upwards and the end cells downward showing the sheet stays intact (though holes open transiently). It then pulls the ends together into a circle.

It should be possible to convert into a 3D model.

CC3D files: File attached: (1.05 MB)

An animation of the output: File attached: output_ObCKSA.mp4 (141.98 KB)


Thanks for your help,my previous expression is not clear. The supplementary explanation is under Maciek Swat’s comment. 
written 10 months ago by dali Zan  
Please login to add an answer/comment or follow this question.

Similar posts:
Search »