VPTissue Reference Manual
PINFlux2.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 "PINFlux2.h"
21 
22 #include "bio/Cell.h"
23 #include "bio/ReduceCellWalls.h"
24 
25 using namespace std;
26 using boost::property_tree::ptree;
27 
28 namespace SimPT_Default {
29 namespace CellChemistry {
30 
31 PINFlux2::PINFlux2(const CoreData& cd)
32 {
33  Initialize(cd);
34 }
35 
36 void PINFlux2::Initialize(const CoreData& cd)
37 {
38  m_cd = cd;
39  const auto& p = m_cd.m_parameters->get_child("auxin_transport");
40 
41  m_aux_breakdown = p.get<double>("aux_breakdown");
42  m_k1 = p.get<double>("k1");
43  m_k2 = p.get<double>("k2");
44  m_km = p.get<double>("km");
45  m_kr = p.get<double>("kr");
46  m_r = p.get<double>("r");
47 }
48 
49 void PINFlux2::operator()(Cell* cell, double* dchem)
50 {
51  // sum all incoming fluxes of PINs
52  dchem[1] = -SumFluxFromWalls( cell );
53  // auxin degradation
54  dchem[0] = -m_aux_breakdown * cell->GetChemical(0);
55 }
56 
57 double PINFlux2::SumFluxFromWalls(Cell* cell)
58 {
59  using std::placeholders::_1;
60  using std::placeholders::_2;
61  using std::placeholders::_3;
62 
63  function<double(Cell*, Cell*, Wall*)> f = bind(&PINFlux2::Flux, this, _1, _2, _3);
64  double const sum = ReduceCellWalls<double>(cell, f);
65  return sum;
66 }
67 
68 double PINFlux2::Flux(Cell* this_cell, Cell* adjacent_cell, Wall* w)
69 {
70  // PIN1 localization at wall
71  // Note: chemical 0 is Auxin (intracellular storage only)
72  // PIN1 is Chemical 1 (both in walls and intracellular storage)
74  // Note that Pij is measured in term of concentration (mol/L)
75  // Pi in terms of quantity (mol)
76  // Equations as in Merks et al., Trends in Plant Science 2007
77 
78  // calculate PIN translocation rate from cell to membrane
79  double const adj_auxin = adjacent_cell->GetChemical(0);
80  double const receptor = adj_auxin * m_r / (m_kr + adj_auxin);
81 
82  // pick the correct side of the Wall
83  double pin_atwall;
84  if (w->GetC1() == this_cell) {
85  pin_atwall = w->GetTransporters1(1);
86  } else {
87  pin_atwall = w->GetTransporters2(1);
88  }
89 
90  // note: pin_flux is net flux from endosome to wall
91  double const chem = this_cell->GetChemical(1);
92  double const pin_flux = m_k1 * chem * receptor / (m_km + chem) - m_k2 * pin_atwall;
93  return pin_flux;
94 }
95 
96 } // namespace
97 } // namespace
Core data with mesh, parameters, random engine and time data.
Definition: CoreData.h:38
STL namespace.
A cell contains walls and nodes.
Definition: Cell.h:48
Namespace for components of the Default model group.
Interface for Cell.
CellChemistry::PINFlux2 header file.
Interface/Implementation for ReduceCellWalls.
A cell wall, runs between cell corner points and consists of wall elements.
Definition: Wall.h:48