Line data Source code
1 : //* This file is part of the MOOSE framework 2 : //* https://mooseframework.inl.gov 3 : //* 4 : //* All rights reserved, see COPYRIGHT for full restrictions 5 : //* https://github.com/idaholab/moose/blob/master/COPYRIGHT 6 : //* 7 : //* Licensed under LGPL 2.1, please see LICENSE for details 8 : //* https://www.gnu.org/licenses/lgpl-2.1.html 9 : 10 : #include "VectorDiffusion.h" 11 : 12 : registerMooseObject("MooseApp", VectorDiffusion); 13 : 14 : InputParameters 15 29171 : VectorDiffusion::validParams() 16 : { 17 29171 : InputParameters params = VectorKernel::validParams(); 18 29171 : params.addClassDescription( 19 : "The Laplacian operator ($-\\nabla \\cdot \\nabla \\vec{u}$), with the weak " 20 : "form of $(\\nabla \\vec{\\phi_i}, \\nabla \\vec{u_h})$."); 21 29171 : return params; 22 0 : } 23 : 24 333 : VectorDiffusion::VectorDiffusion(const InputParameters & parameters) : VectorKernel(parameters) {} 25 : 26 : Real 27 83288013 : VectorDiffusion::computeQpResidual() 28 : { 29 83288013 : return _grad_u[_qp].contract(_grad_test[_i][_qp]); 30 : } 31 : 32 : Real 33 117209735 : VectorDiffusion::computeQpJacobian() 34 : { 35 117209735 : return _grad_phi[_j][_qp].contract(_grad_test[_i][_qp]); 36 : }