AbstractVanLeeuwen2009WntSwatCellCycleModel.cpp

00001 /*
00002 
00003 Copyright (C) University of Oxford, 2005-2011
00004 
00005 University of Oxford means the Chancellor, Masters and Scholars of the
00006 University of Oxford, having an administrative office at Wellington
00007 Square, Oxford OX1 2JD, UK.
00008 
00009 This file is part of Chaste.
00010 
00011 Chaste is free software: you can redistribute it and/or modify it
00012 under the terms of the GNU Lesser General Public License as published
00013 by the Free Software Foundation, either version 2.1 of the License, or
00014 (at your option) any later version.
00015 
00016 Chaste is distributed in the hope that it will be useful, but WITHOUT
00017 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00018 FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public
00019 License for more details. The offer of Chaste under the terms of the
00020 License is subject to the License being interpreted in accordance with
00021 English Law and subject to any action against the University of Oxford
00022 being under the jurisdiction of the English Courts.
00023 
00024 You should have received a copy of the GNU Lesser General Public License
00025 along with Chaste. If not, see <http://www.gnu.org/licenses/>.
00026 
00027 */
00028 #include "UblasIncludes.hpp"
00029 #include "AbstractVanLeeuwen2009WntSwatCellCycleModel.hpp"
00030 
00031 AbstractVanLeeuwen2009WntSwatCellCycleModel::AbstractVanLeeuwen2009WntSwatCellCycleModel(boost::shared_ptr<AbstractCellCycleModelOdeSolver> pOdeSolver)
00032    : AbstractWntOdeBasedCellCycleModel(pOdeSolver)
00033 {
00034 }
00035 
00036 void AbstractVanLeeuwen2009WntSwatCellCycleModel::ChangeCellProliferativeTypeDueToCurrentBetaCateninLevel()
00037 {
00038     assert(mpOdeSystem != NULL);
00039     assert(mpCell != NULL);
00040     double beta_catenin_level =   mpOdeSystem->rGetStateVariables()[16]
00041                                 + mpOdeSystem->rGetStateVariables()[17]
00042                                 + mpOdeSystem->rGetStateVariables()[18]
00043                                 + mpOdeSystem->rGetStateVariables()[19];
00044 
00045     CellProliferativeType cell_type = TRANSIT;
00046 
00047     // For mitogenic stimulus of 1/25.0 in Wnt equations
00048     if (beta_catenin_level < 10.188)
00049     {
00050         cell_type = DIFFERENTIATED;
00051     }
00052 
00053     mCellProliferativeType = cell_type;
00054 }
00055 
00056 void AbstractVanLeeuwen2009WntSwatCellCycleModel::Initialise()
00057 {
00058     assert(mpOdeSystem == NULL);
00059     assert(mpCell != NULL);
00060 
00061     double wnt_level = GetWntLevel();
00062 
00063     InitialiseOdeSystem(wnt_level, mpCell->GetMutationState());
00064 
00065     mpOdeSystem->SetStateVariables(mpOdeSystem->GetInitialConditions());
00066 
00067     ChangeCellProliferativeTypeDueToCurrentBetaCateninLevel();
00068 }
00069 
00070 void AbstractVanLeeuwen2009WntSwatCellCycleModel::AdjustOdeParameters(double currentTime)
00071 {
00072     // Pass this time step's Wnt stimulus into the solver as a constant over this timestep.
00073     mpOdeSystem->rGetStateVariables()[21] = GetWntLevel();
00074 
00075     // Use the cell's current mutation status as another input
00076     static_cast<VanLeeuwen2009WntSwatCellCycleOdeSystem*>(mpOdeSystem)->SetMutationState(mpCell->GetMutationState());
00077 }
00078 
00079 double AbstractVanLeeuwen2009WntSwatCellCycleModel::GetMembraneBoundBetaCateninLevel()
00080 {
00081     return mpOdeSystem->rGetStateVariables()[13] + mpOdeSystem->rGetStateVariables()[14];
00082 }
00083 
00084 double AbstractVanLeeuwen2009WntSwatCellCycleModel::GetCytoplasmicBetaCateninLevel()
00085 {
00086     return  mpOdeSystem->rGetStateVariables()[7] + mpOdeSystem->rGetStateVariables()[8]
00087           + mpOdeSystem->rGetStateVariables()[9] + mpOdeSystem->rGetStateVariables()[10]
00088           + mpOdeSystem->rGetStateVariables()[11];
00089 }
00090 
00091 double AbstractVanLeeuwen2009WntSwatCellCycleModel::GetNuclearBetaCateninLevel()
00092 {
00093     return mpOdeSystem->rGetStateVariables()[16] +
00094            mpOdeSystem->rGetStateVariables()[17] +
00095            mpOdeSystem->rGetStateVariables()[18] +
00096            mpOdeSystem->rGetStateVariables()[19];
00097 }
00098 
00099 void AbstractVanLeeuwen2009WntSwatCellCycleModel::OutputCellCycleModelParameters(out_stream& rParamsFile)
00100 {
00101     // No new parameters to output
00102 
00103     // Call method on direct parent class
00104     AbstractWntOdeBasedCellCycleModel::OutputCellCycleModelParameters(rParamsFile);
00105 }

Generated on Tue May 31 14:31:41 2011 for Chaste by  doxygen 1.5.5