MorphoGraphX
2.0-1-227
src
DynamXProcessCellDivide.hpp
Go to the documentation of this file.
1
//
2
// This file is part of MorphoGraphX - http://www.MorphoGraphX.org
3
// Copyright (C) 2012-2016 Richard S. Smith and collaborators.
4
//
5
// If you use MorphoGraphX in your work, please cite:
6
// http://dx.doi.org/10.7554/eLife.05864
7
//
8
// MorphoGraphX is free software, and is licensed under under the terms of the
9
// GNU General (GPL) Public License version 2.0, http://www.gnu.org/licenses.
10
//
11
12
#ifndef DYNAMX_PROCESS_CELL_DIVIDE_HPP
13
#define DYNAMX_PROCESS_CELL_DIVIDE_HPP
14
21
#include <
Process.hpp
>
22
#include <
CellTissue.hpp
>
23
#include <
MGXSubdivide.hpp
>
24
25
namespace
mgx
26
{
27
// Process to perform cell division in a 2D Tissue Mesh (MGX2D)
28
class
mgxBase_EXPORT
CellDivide
:
public
Process
29
{
30
public
:
31
CellDivide
(
const
Process
&process) :
Process
(process) {}
32
33
~CellDivide
() {}
34
35
// Initialize simulation, called from GUI thread
36
bool
initialize(QStringList &parms, QWidget* parent);
37
38
// Run a step of cell division
39
bool
step
(
const
QStringList &parms)
40
{
41
Mesh
*mesh = currentMesh();
42
MGXSubdivide
sDiv(mesh);
43
return
step(mesh, &sDiv);
44
}
45
46
// Run a step of cell division
47
virtual
bool
step(
Mesh
*mesh,
Subdivide
*sDiv);
48
49
// Cannot rewind subdivision, do nothing
50
bool
rewind
(QStringList &parms, QWidget *parent) {
return
true
; }
51
52
// Functions for Gui
53
QString
description
()
const
{
return
"Parameters for cell division on tissue mesh."
; }
54
55
QStringList
parmNames
()
const
56
{
57
QVector <QString> vec(
CellDivideMgx2d::pNumParms
);
58
59
vec[
CellDivideMgx2d::pCellMaxArea
] =
"CellMaxArea"
;
60
vec[
CellDivideMgx2d::pCellDivAlg
] =
"CellDivAlg"
;
61
vec[
CellDivideMgx2d::pCellWallSample
] =
"CellWallSample"
;
62
vec[
CellDivideMgx2d::pCellPinch
] =
"CellPinch"
;
63
vec[
CellDivideMgx2d::pCellMaxPinch
] =
"CellMaxPinch"
;
64
vec[
CellDivideMgx2d::pCellWallMin
] =
"CellWallMin"
;
65
66
return
vec.toList();
67
}
68
QStringList
parmDescs
()
const
69
{
70
QVector <QString> vec(
CellDivideMgx2d::pNumParms
);
71
72
vec[
CellDivideMgx2d::pCellMaxArea
] =
"Area threshold for cell division"
;
73
vec[
CellDivideMgx2d::pCellDivAlg
] =
"Division Algorithm"
;
74
vec[
CellDivideMgx2d::pCellWallSample
] =
"Cell wall sample size"
;
75
vec[
CellDivideMgx2d::pCellPinch
] =
"Amount to pinch walls"
;
76
vec[
CellDivideMgx2d::pCellMaxPinch
] =
"Max amount to pinch walls"
;
77
vec[
CellDivideMgx2d::pCellWallMin
] =
"Min dist during division to existing vertex"
;
78
79
return
vec.toList();
80
}
81
QStringList
parmDefaults
()
const
82
{
83
QVector <QString> vec(
CellDivideMgx2d::pNumParms
);
84
85
vec[
CellDivideMgx2d::pCellMaxArea
] =
"25"
;
86
vec[
CellDivideMgx2d::pCellDivAlg
] =
"Shortest Wall"
;
87
vec[
CellDivideMgx2d::pCellWallSample
] =
"0.05"
;
88
vec[
CellDivideMgx2d::pCellPinch
] =
"0.2"
;
89
vec[
CellDivideMgx2d::pCellMaxPinch
] =
"1"
;
90
vec[
CellDivideMgx2d::pCellWallMin
] =
"0.03"
;
91
92
return
vec.toList();
93
}
94
95
ParmChoiceMap
parmChoice
()
const
96
{
97
ParmChoiceMap
map
;
98
map
[1] = QStringList() <<
"Shortest Wall"
<<
"Closest Midpoint"
99
<<
"Closest Wall"
<<
"Shortest Direction"
;
100
return
map
;
101
}
102
103
// Icon file
104
QIcon
icon
()
const
{
return
QIcon(
":/images/CellDivide.png"
); }
105
106
private
:
107
Mesh
*mesh;
108
CellTissue
*T;
109
};
110
}
111
112
#endif
113
mgx::CellDivide::~CellDivide
~CellDivide()
Definition:
DynamXProcessCellDivide.hpp:33
mgx::CellDivideMgx2d::pCellWallMin
@ pCellWallMin
Definition:
CellTissue.hpp:43
Process.hpp
mgx::CellDivide::rewind
bool rewind(QStringList &parms, QWidget *parent)
Definition:
DynamXProcessCellDivide.hpp:50
mgx::CellDivide
Definition:
DynamXProcessCellDivide.hpp:28
mgx::CellDivideMgx2d::pCellMaxArea
@ pCellMaxArea
Definition:
CellTissue.hpp:43
mgx::CellTissue
Definition:
CellTissue.hpp:46
mgx::CellDivideMgx2d::pCellWallSample
@ pCellWallSample
Definition:
CellTissue.hpp:43
mgx::CellDivide::step
bool step(const QStringList &parms)
Definition:
DynamXProcessCellDivide.hpp:39
mgx
Distributed matrix library.
Definition:
Assert.hpp:26
mgx::CellDivide::parmNames
QStringList parmNames() const
Definition:
DynamXProcessCellDivide.hpp:55
CellTissue.hpp
mgx::Process
Definition:
Process.hpp:219
mgx::CellDivideMgx2d::pNumParms
@ pNumParms
Definition:
CellTissue.hpp:43
mgx::CellDivideMgx2d::pCellPinch
@ pCellPinch
Definition:
CellTissue.hpp:43
mgx::CellDivide::parmDescs
QStringList parmDescs() const
Definition:
DynamXProcessCellDivide.hpp:68
mgx::Mesh
Definition:
Mesh.hpp:54
mgx::CellDivide::icon
QIcon icon() const
Definition:
DynamXProcessCellDivide.hpp:104
mgx::CellDivideMgx2d::pCellMaxPinch
@ pCellMaxPinch
Definition:
CellTissue.hpp:43
mgx::MGXSubdivide
Definition:
MGXSubdivide.hpp:27
mgx::CellDivideMgx2d::pCellDivAlg
@ pCellDivAlg
Definition:
CellTissue.hpp:43
mgx::CellDivide::parmDefaults
QStringList parmDefaults() const
Definition:
DynamXProcessCellDivide.hpp:81
mgx::Subdivide
Definition:
Subdivide.hpp:25
MGXSubdivide.hpp
mgx::CellDivide::description
QString description() const
Definition:
DynamXProcessCellDivide.hpp:53
mgx::CellDivide::CellDivide
CellDivide(const Process &process)
Definition:
DynamXProcessCellDivide.hpp:31
mgx::map
CU_HOST_DEVICE Vector< dim, T > map(const T &(*fct)(const T1 &), const Vector< dim, T1 > &v)
Definition:
Vector.hpp:1380
mgx::CellDivide::parmChoice
ParmChoiceMap parmChoice() const
Definition:
DynamXProcessCellDivide.hpp:95
Generated on Fri Jul 9 2021 18:34:54 for MorphoGraphX by
1.8.17