www.mooseframework.org
ElementIntegralIndicator.C
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://www.mooseframework.org
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 
11 
12 // MOOSE includes
13 #include "MooseVariableFE.h"
14 
15 #include "libmesh/quadrature.h"
16 
19 {
21  return params;
22 }
23 
25  : ElementIndicator(parameters)
26 {
27 }
28 
29 void
31 {
32  Real sum = 0;
33  for (_qp = 0; _qp < _qrule->n_points(); _qp++)
34  sum += _JxW[_qp] * _coord[_qp] * computeQpIntegral();
35 
36  // sum = std::sqrt(sum);
37 
39 }
40 
41 Real
43 {
44  return _u[_qp];
45 }
static InputParameters validParams()
virtual void computeIndicator() override
Pure virtual that must be overridden.
const MooseArray< Real > & _coord
virtual void setNodalValue(const OutputType &value, unsigned int idx=0) override
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
const MooseArray< Real > & _JxW
const QBase *const & _qrule
MooseVariable & _field_var
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static InputParameters validParams()
ElementIntegralIndicator(const InputParameters &parameters)
unsigned int _qp
const VariableValue & _u
Holds the solution at current quadrature points.