unsteady_solver.h
Go to the documentation of this file.00001 // The libMesh Finite Element Library. 00002 // Copyright (C) 2002-2012 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner 00003 00004 // This library is free software; you can redistribute it and/or 00005 // modify it under the terms of the GNU Lesser General Public 00006 // License as published by the Free Software Foundation; either 00007 // version 2.1 of the License, or (at your option) any later version. 00008 00009 // This library is distributed in the hope that it will be useful, 00010 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00012 // Lesser General Public License for more details. 00013 00014 // You should have received a copy of the GNU Lesser General Public 00015 // License along with this library; if not, write to the Free Software 00016 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 00017 00018 00019 00020 #ifndef LIBMESH_UNSTEADY_SOLVER_H 00021 #define LIBMESH_UNSTEADY_SOLVER_H 00022 00023 // Local includes 00024 #include "libmesh/auto_ptr.h" 00025 #include "libmesh/libmesh_common.h" 00026 #include "libmesh/numeric_vector.h" 00027 #include "libmesh/time_solver.h" 00028 00029 // C++ includes 00030 00031 namespace libMesh 00032 { 00033 00034 // Forward Declarations 00035 class UnsteadySolver; 00036 00051 // ------------------------------------------------------------ 00052 // UnsteadySolver class definition 00053 class UnsteadySolver : public TimeSolver 00054 { 00055 public: 00060 explicit 00061 UnsteadySolver (sys_type& s); 00062 00066 virtual ~UnsteadySolver (); 00067 00072 virtual void init (); 00073 00079 virtual void init_data (); 00080 00085 virtual void reinit (); 00086 00092 virtual void solve (); 00093 00100 virtual void advance_timestep (); 00101 00107 virtual void adjoint_advance_timestep (); 00108 00113 virtual void retrieve_timestep (); 00114 00122 virtual Real error_order () const = 0; 00123 00128 Number old_nonlinear_solution (const dof_id_type global_dof_number) const; 00129 00133 AutoPtr<NumericVector<Number> > old_local_nonlinear_solution; 00134 00144 virtual Real du(const SystemNorm& norm) const; 00145 00149 virtual bool is_steady() const { return false; } 00150 00151 protected: 00152 00157 bool first_solve; 00158 00163 bool first_adjoint_step; 00164 }; 00165 00166 00167 } // namespace libMesh 00168 00169 00170 #endif // LIBMESH_UNSTEADY_SOLVER_H
Site Created By: libMesh Developers
Last modified: February 05 2013 19:54:49 UTC
Hosted By: