www.mooseframework.org
ImplicitEuler.C
Go to the documentation of this file.
1 /****************************************************************/
2 /* DO NOT MODIFY THIS HEADER */
3 /* MOOSE - Multiphysics Object Oriented Simulation Environment */
4 /* */
5 /* (c) 2010 Battelle Energy Alliance, LLC */
6 /* ALL RIGHTS RESERVED */
7 /* */
8 /* Prepared by Battelle Energy Alliance, LLC */
9 /* Under Contract No. DE-AC07-05ID14517 */
10 /* With the U. S. Department of Energy */
11 /* */
12 /* See COPYRIGHT for full restrictions */
13 /****************************************************************/
14 
15 #include "ImplicitEuler.h"
16 #include "NonlinearSystem.h"
17 
18 template <>
21 {
23 
24  return params;
25 }
26 
27 ImplicitEuler::ImplicitEuler(const InputParameters & parameters) : TimeIntegrator(parameters) {}
28 
30 
31 void
33 {
34  _u_dot = *_solution;
36  _u_dot *= 1 / _dt;
37  _u_dot.close();
38 
39  _du_dot_du = 1.0 / _dt;
40 }
41 
42 void
43 ImplicitEuler::postStep(NumericVector<Number> & residual)
44 {
45  residual += _Re_time;
46  residual += _Re_non_time;
47  residual.close();
48 }
NumericVector< Number > & _u_dot
solution vector for u^dot
NumericVector< Number > & _Re_non_time
residual vector for non-time contributions
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
virtual ~ImplicitEuler()
Definition: ImplicitEuler.C:29
InputParameters validParams< TimeIntegrator >()
virtual void computeTimeDerivatives()
Definition: ImplicitEuler.C:32
Real & _du_dot_du
solution vector for
Base class for time integrators.
InputParameters validParams< ImplicitEuler >()
Definition: ImplicitEuler.C:20
ImplicitEuler(const InputParameters &parameters)
Definition: ImplicitEuler.C:27
NumericVector< Number > & _Re_time
residual vector for time contributions
virtual void postStep(NumericVector< Number > &residual)
Callback to the TimeIntegrator called immediately after the residuals are computed in NonlinearSystem...
Definition: ImplicitEuler.C:43
const NumericVector< Number > & _solution_old
const NumericVector< Number > *& _solution
solution vectors