DASPK.h

Go to the documentation of this file.
00001 /*
00002 
00003 Copyright (C) 1996-2012 John W. Eaton
00004 
00005 This file is part of Octave.
00006 
00007 Octave is free software; you can redistribute it and/or modify it
00008 under the terms of the GNU General Public License as published by the
00009 Free Software Foundation; either version 3 of the License, or (at your
00010 option) any later version.
00011 
00012 Octave is distributed in the hope that it will be useful, but WITHOUT
00013 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00014 FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
00015 for more details.
00016 
00017 You should have received a copy of the GNU General Public License
00018 along with Octave; see the file COPYING.  If not, see
00019 <http://www.gnu.org/licenses/>.
00020 
00021 */
00022 
00023 #if !defined (octave_DASPK_h)
00024 #define octave_DASPK_h 1
00025 
00026 #include <cfloat>
00027 
00028 #include "DASPK-opts.h"
00029 #include "lo-math.h"
00030 
00031 class
00032 OCTAVE_API
00033 DASPK : public DAE, public DASPK_options
00034 {
00035 public:
00036 
00037   DASPK (void)
00038     : DAE (), DASPK_options (), initialized (false), liw (0), lrw (0),
00039       info (), iwork (), rwork (), abs_tol (), rel_tol () { }
00040 
00041   DASPK (const ColumnVector& s, double tm, DAEFunc& f)
00042     : DAE (s, tm, f), DASPK_options (), initialized (false), liw (0),
00043       lrw (0), info (), iwork (), rwork (), abs_tol (), rel_tol () { }
00044 
00045   DASPK (const ColumnVector& s, const ColumnVector& deriv,
00046          double tm, DAEFunc& f)
00047     : DAE (s, deriv, tm, f), DASPK_options (), initialized (false),
00048       liw (0), lrw (0), info (), iwork (), rwork (), abs_tol (),
00049       rel_tol () { }
00050 
00051   ~DASPK (void) { }
00052 
00053   ColumnVector do_integrate (double t);
00054 
00055   Matrix do_integrate (const ColumnVector& tout);
00056 
00057   Matrix do_integrate (const ColumnVector& tout, const ColumnVector& tcrit);
00058 
00059   Matrix integrate (const ColumnVector& tout, Matrix& xdot_out);
00060 
00061   Matrix integrate (const ColumnVector& tout, Matrix& xdot_out,
00062                     const ColumnVector& tcrit);
00063 
00064   std::string error_message (void) const;
00065 
00066 private:
00067 
00068   bool initialized;
00069 
00070   octave_idx_type liw;
00071   octave_idx_type lrw;
00072 
00073   Array<octave_idx_type> info;
00074   Array<octave_idx_type> iwork;
00075 
00076   Array<double> rwork;
00077 
00078   Array<double> abs_tol;
00079   Array<double> rel_tol;
00080 };
00081 
00082 #endif
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines