www.mooseframework.org
FDKernel.h
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 #ifndef FDKERNEL_H
16 #define FDKERNEL_H
17 
18 #include "Kernel.h"
19 
20 class FDKernel;
21 
22 template <>
24 
25 class FDKernel : public Kernel
26 {
27 public:
29 
30  virtual void computeJacobian();
34  virtual void computeOffDiagJacobian(unsigned int jvar);
39  virtual void computeOffDiagJacobianScalar(unsigned int jvar);
40 
41 protected:
47  virtual DenseVector<Number> perturbedResidual(unsigned int ivar,
48  unsigned int i,
49  Real perturbation_scale,
50  Real & perturbation);
51 
52  Real _scale;
53 };
54 
55 #endif /* FDKERNEL_H */
virtual DenseVector< Number > perturbedResidual(unsigned int ivar, unsigned int i, Real perturbation_scale, Real &perturbation)
Computes the residual when the current state of j-th variable at element node i is perturbed by pertu...
Definition: FDKernel.C:42
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
Real _scale
Definition: FDKernel.h:52
InputParameters validParams< FDKernel >()
Definition: FDKernel.C:27
virtual void computeOffDiagJacobianScalar(unsigned int jvar)
Computes jacobian block with respect to a scalar variable.
Definition: FDKernel.C:105
virtual void computeOffDiagJacobian(unsigned int jvar)
Computes d-residual / d-jvar...
Definition: FDKernel.C:68
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseObject.h:53
Definition: Kernel.h:25
virtual void computeJacobian()
Compute this Kernel&#39;s contribution to the diagonal Jacobian entries.
Definition: FDKernel.C:62
FDKernel(const InputParameters &parameters)
Definition: FDKernel.C:33