www.mooseframework.org
CoupledMaterialDerivative.h
Go to the documentation of this file.
1 /****************************************************************/
2 /* MOOSE - Multiphysics Object Oriented Simulation Environment */
3 /* */
4 /* All contents are licensed under LGPL V2.1 */
5 /* See LICENSE for full restrictions */
6 /****************************************************************/
7 #ifndef COUPLEDMATERIALDERIVATIVE_H
8 #define COUPLEDMATERIALDERIVATIVE_H
9 
10 #include "Kernel.h"
11 #include "JvarMapInterface.h"
12 #include "DerivativeMaterialInterface.h"
13 
14 // Forward Declaration
16 
17 template <>
19 
23 class CoupledMaterialDerivative : public DerivativeMaterialInterface<JvarMapKernelInterface<Kernel>>
24 {
25 public:
26  CoupledMaterialDerivative(const InputParameters & parameters);
27  virtual void initialSetup() override;
28 
29 protected:
30  virtual Real computeQpResidual() override;
31  virtual Real computeQpJacobian() override;
32  virtual Real computeQpOffDiagJacobian(unsigned int jvar) override;
33 
34  std::string _v_name;
35  unsigned int _v_var;
36 
38  const MaterialProperty<Real> & _dFdv;
39 
41  const MaterialProperty<Real> & _d2Fdvdu;
42 
44  const MaterialProperty<Real> & _d2Fdv2;
45 
47  const unsigned int _nvar;
48 
50  std::vector<const MaterialProperty<Real> *> _d2Fdvdarg;
51 };
52 
53 #endif // COUPLEDMATERIALDERIVATIVE_H
InputParameters validParams< CoupledMaterialDerivative >()
virtual Real computeQpOffDiagJacobian(unsigned int jvar) override
const MaterialProperty< Real > & _d2Fdvdu
Free energy 2nd order derivative w.r.t. v then u.
This kernel adds the term (dFdv, test), where v is a coupled variable.
const unsigned int _nvar
Number of coupled variables.
virtual void initialSetup() override
const MaterialProperty< Real > & _d2Fdv2
Free energy 2nd order derivative w.r.t. v.
virtual Real computeQpResidual() override
CoupledMaterialDerivative(const InputParameters &parameters)
virtual Real computeQpJacobian() override
std::vector< const MaterialProperty< Real > * > _d2Fdvdarg
Reaction rate derivatives w.r.t. other coupled variables.
const MaterialProperty< Real > & _dFdv
Free Energy derivative w.r.t. v.