NhsContractionModel.hpp

00001 /*
00002 
00003 Copyright (C) University of Oxford, 2005-2010
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 #ifndef NHSCONTRACTIONMODEL_HPP_
00029 #define NHSCONTRACTIONMODEL_HPP_
00030 
00031 #include "AbstractOdeBasedContractionModel.hpp"
00032 
00033 
00048 class NhsContractionModel  : public AbstractOdeBasedContractionModel
00049 {
00050 friend class TestContractionModels;
00051 
00052 protected :
00054     double mLambda;
00056     double mDLambdaDt;
00058     double mCalciumI;
00059 
00060 
00062     double mCalciumTrop50;
00063 
00065     double mK1;
00067     double mK2;
00068 
00069     // Parameters
00070 
00072     static const double mKon;
00073 
00075     static const double mKrefoff;
00076 
00078     static const double mGamma;
00079 
00081     static const double mCalciumTroponinMax;
00082 
00084     static const double mAlphaR1;
00085 
00087     static const double mAlphaR2;
00088 
00090     static const double mKZ;
00091 
00093     static const unsigned mNr;
00094 
00096     static const double mBeta1;
00097 
00099     static const double mAlpha0;
00100 
00102     static const unsigned mN;
00103 
00105     static const double mZp;
00106 
00108     static const double mCalcium50ref;
00109 
00111     static const double mTref;
00112 
00114     static const double mBeta0;
00115 
00117     static const double mA;
00118 
00120     static const double mA1;
00121 
00123     static const double mA2;
00124 
00126     static const double mA3;
00127 
00129     static const double mAlpha1;
00130 
00132     static const double mAlpha2;
00133 
00135     static const double mAlpha3;
00136 
00141     void CalculateCalciumTrop50();
00142 
00148     double CalculateT0(double z);
00149 
00150 public :
00155     NhsContractionModel();
00156 
00163     void SetStretchAndStretchRate(double lambda, double dlambdaDt);
00164 
00170     void SetInputParameters(ContractionModelInputParameters& rInputParameters);
00171 
00176     void SetIntracellularCalciumConcentration(double calciumConcentration);
00177 
00182     double GetCalciumTroponinValue();
00183 
00191     void EvaluateYDerivatives(double time, const std::vector<double> &rY, std::vector<double> &rDY);
00192 
00196     double GetActiveTension();
00197 
00203     double GetNextActiveTension()
00204     {
00205         EXCEPTION("If using this in an 'explicit manner' call UpdateStateVariables() and then GetActiveTension(), otherwise use NhsModelWithBackwardSolver");
00206     }
00207 
00211     bool IsStretchDependent()
00212     {
00213         return true;
00214     }
00215 
00219     bool IsStretchRateDependent()
00220     {
00221         return true;
00222     }
00223 };
00224 #endif /*NHSCONTRACTIONMODEL_HPP_*/

Generated by  doxygen 1.6.2