VPTissue Reference Manual
cell2cell_transport/Blad.cpp
Go to the documentation of this file.
1 /*
2  * Copyright 2011-2016 Universiteit Antwerpen
3  *
4  * Licensed under the EUPL, Version 1.1 or as soon they will be approved by
5  * the European Commission - subsequent versions of the EUPL (the "Licence");
6  * You may not use this work except in compliance with the Licence.
7  * You may obtain a copy of the Licence at: http://ec.europa.eu/idabc/eupl5
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the Licence is distributed on an "AS IS" basis,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the Licence for the specific language governing
13  * permissions and limitations under the Licence.
14  */
20 #include "Blad.h"
21 
22 #include "bio/Cell.h"
23 #include "bio/Wall.h"
24 
25 namespace SimPT_Blad {
26 namespace CellToCellTransport {
27 
28 using namespace std;
29 using namespace boost::property_tree;
30 
31 Blad::Blad(const CoreData& cd)
32 {
33  Initialize(cd);
34 }
35 
36 void Blad::Initialize(const CoreData& cd)
37 {
38  m_cd = cd;
39  const auto& p = m_cd.m_parameters;
40  m_M_diffusion_constant = p->get<double>("blad.M_diffusion_constant");
41 }
42 
43 void Blad::operator()(Wall* w, double* dchem_c1, double* dchem_c2)
44 {
45 
46  if ( !(w->GetC1()->IsBoundaryPolygon()) && !(w->GetC2()->IsBoundaryPolygon()) )
47  {
48  const double apoplast_thickness = 2.;
49 
50  //morphogen - chemical '1'
51  const double phi2 = (w->GetLength() / ( apoplast_thickness ) ) * m_M_diffusion_constant * ( ( w->GetC2()->GetChemical(1) / (w->GetC2()->GetArea()) )
52  - ( w->GetC1()->GetChemical(1) / (w->GetC1()->GetArea()) ) );
53 
54  dchem_c1[1] += phi2 ;
55  dchem_c2[1] -= phi2 ;
56  }
57 }
58 
59 } // namespace
60 } // namespace
61 
Namespace for components of the Blad model group.
Core data with mesh, parameters, random engine and time data.
Definition: CoreData.h:38
STL namespace.
void operator()(Wall *w, double *dchem_c1, double *dchem_c2)
Execute.
void Initialize(const CoreData &cd)
Initialize or re-initialize.
Interface for Cell.
Blad(const CoreData &cd)
Initializing constructor.
double GetLength() const
Returns (and calculates, if length marked as dirty) the length along all nodes.
Definition: Wall.cpp:97
CellToCellTransport for Blad model.
double GetArea() const
Return the area of the cell.
Definition: Cell.cpp:178
A cell wall, runs between cell corner points and consists of wall elements.
Definition: Wall.h:48
Interface for Wall.