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 
00029 #include "UblasIncludes.hpp"
00030 #include "AbstractVanLeeuwen2009WntSwatCellCycleModel.hpp"
00031 
00032 AbstractVanLeeuwen2009WntSwatCellCycleModel::AbstractVanLeeuwen2009WntSwatCellCycleModel(boost::shared_ptr<AbstractCellCycleModelOdeSolver> pOdeSolver)
00033    : AbstractWntOdeBasedCellCycleModel(pOdeSolver)
00034 {
00035 }
00036 
00037 void AbstractVanLeeuwen2009WntSwatCellCycleModel::ChangeCellProliferativeTypeDueToCurrentBetaCateninLevel()
00038 {
00039     assert(mpOdeSystem != NULL);
00040     assert(mpCell != NULL);
00041     double beta_catenin_level =   mpOdeSystem->rGetStateVariables()[16]
00042                                 + mpOdeSystem->rGetStateVariables()[17]
00043                                 + mpOdeSystem->rGetStateVariables()[18]
00044                                 + mpOdeSystem->rGetStateVariables()[19];
00045 
00046     CellProliferativeType cell_type = TRANSIT;
00047 
00048     // For mitogenic stimulus of 1/25.0 in Wnt equations
00049     if (beta_catenin_level < 10.188)
00050     {
00051         cell_type = DIFFERENTIATED;
00052     }
00053 
00054     mCellProliferativeType = cell_type;
00055 }
00056 
00057 void AbstractVanLeeuwen2009WntSwatCellCycleModel::Initialise()
00058 {
00059     assert(mpOdeSystem == NULL);
00060     assert(mpCell != NULL);
00061 
00062     double wnt_level = GetWntLevel();
00063 
00064     InitialiseOdeSystem(wnt_level, mpCell->GetMutationState());
00065 
00066     mpOdeSystem->SetStateVariables(mpOdeSystem->GetInitialConditions());
00067 
00068     ChangeCellProliferativeTypeDueToCurrentBetaCateninLevel();
00069 }
00070 
00071 void AbstractVanLeeuwen2009WntSwatCellCycleModel::AdjustOdeParameters(double currentTime)
00072 {
00073     // Pass this time step's Wnt stimulus into the solver as a constant over this timestep.
00074     mpOdeSystem->rGetStateVariables()[21] = GetWntLevel();
00075 
00076     // Use the cell's current mutation status as another input
00077     static_cast<VanLeeuwen2009WntSwatCellCycleOdeSystem*>(mpOdeSystem)->SetMutationState(mpCell->GetMutationState());
00078 }
00079 
00080 double AbstractVanLeeuwen2009WntSwatCellCycleModel::GetMembraneBoundBetaCateninLevel()
00081 {
00082     return mpOdeSystem->rGetStateVariables()[13] + mpOdeSystem->rGetStateVariables()[14];
00083 }
00084 
00085 double AbstractVanLeeuwen2009WntSwatCellCycleModel::GetCytoplasmicBetaCateninLevel()
00086 {
00087     return  mpOdeSystem->rGetStateVariables()[7] + mpOdeSystem->rGetStateVariables()[8]
00088           + mpOdeSystem->rGetStateVariables()[9] + mpOdeSystem->rGetStateVariables()[10]
00089           + mpOdeSystem->rGetStateVariables()[11];
00090 }
00091 
00092 double AbstractVanLeeuwen2009WntSwatCellCycleModel::GetNuclearBetaCateninLevel()
00093 {
00094     return mpOdeSystem->rGetStateVariables()[16] +
00095            mpOdeSystem->rGetStateVariables()[17] +
00096            mpOdeSystem->rGetStateVariables()[18] +
00097            mpOdeSystem->rGetStateVariables()[19];
00098 }
00099 
00100 void AbstractVanLeeuwen2009WntSwatCellCycleModel::OutputCellCycleModelParameters(out_stream& rParamsFile)
00101 {
00102     // No new parameters to output
00103 
00104     // Call method on direct parent class
00105     AbstractWntOdeBasedCellCycleModel::OutputCellCycleModelParameters(rParamsFile);
00106 }
Generated on Thu Dec 22 13:00:05 2011 for Chaste by  doxygen 1.6.3