www.mooseframework.org
ComputeResidualThread.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 COMPUTERESIDUALTHREAD_H
16 #define COMPUTERESIDUALTHREAD_H
17 
18 #include "ThreadedElementLoop.h"
19 
20 #include "libmesh/elem_range.h"
21 
22 // Forward declarations
23 class FEProblemBase;
25 class IntegratedBC;
26 class DGKernel;
27 class InterfaceKernel;
28 class TimeKernel;
29 class KernelBase;
30 class KernelWarehouse;
31 
32 class ComputeResidualThread : public ThreadedElementLoop<ConstElemRange>
33 {
34 public:
36  // Splitting Constructor
37  ComputeResidualThread(ComputeResidualThread & x, Threads::split split);
38 
39  virtual ~ComputeResidualThread();
40 
41  virtual void subdomainChanged() override;
42  virtual void onElement(const Elem * elem) override;
43  virtual void onBoundary(const Elem * elem, unsigned int side, BoundaryID bnd_id) override;
44  virtual void onInterface(const Elem * elem, unsigned int side, BoundaryID bnd_id) override;
45  virtual void onInternalSide(const Elem * elem, unsigned int side) override;
46  virtual void postElement(const Elem * /*elem*/) override;
47  virtual void post() override;
48 
49  void join(const ComputeResidualThread & /*y*/);
50 
51 protected:
54  unsigned int _num_cached;
55 
58 
61 
64 
69 };
70 
71 #endif // COMPUTERESIDUALTHREAD_H
virtual void onBoundary(const Elem *elem, unsigned int side, BoundaryID bnd_id) override
Called when doing boundary assembling.
Base class for assembly-like calculations.
virtual void postElement(const Elem *) override
Called after the element assembly is done (including surface assembling)
ComputeResidualThread(FEProblemBase &fe_problem, Moose::KernelType type)
virtual void subdomainChanged() override
Called every time the current subdomain changes (i.e.
void join(const ComputeResidualThread &)
static PetscErrorCode Vec x
const MooseObjectWarehouse< InterfaceKernel > & _interface_kernels
Reference to interface kernel storage structure.
const MooseObjectWarehouse< IntegratedBC > & _integrated_bcs
Reference to BC storage structures.
Specialization of SubProblem for solving nonlinear equations plus auxiliary equations.
Nonlinear system to be solved.
Moose::KernelType _kernel_type
This is the common base class for the two main kernel types implemented in MOOSE, EigenKernel and Ker...
Definition: KernelBase.h:47
const KernelWarehouse & _kernels
const MooseObjectWarehouse< DGKernel > & _dg_kernels
Reference to DGKernel storage structure.
The DGKernel class is responsible for calculating the residuals for various physics on internal sides...
Definition: DGKernel.h:47
Base class for deriving any boundary condition of a integrated type.
Definition: IntegratedBC.h:33
virtual void onElement(const Elem *elem) override
Assembly of the element (not including surface assembly)
InterfaceKernel is responsible for interfacing physics across subdomains.
KernelType
Definition: MooseTypes.h:162
MatType type
virtual void post() override
Called after the element range loop.
virtual void onInternalSide(const Elem *elem, unsigned int side) override
Called when doing internal edge assembling.
Holds kernels and provides some services.
All time kernels should inherit from this class.
Definition: TimeKernel.h:30
NonlinearSystemBase & _nl
virtual void onInterface(const Elem *elem, unsigned int side, BoundaryID bnd_id) override
Called when doing interface assembling.
boundary_id_type BoundaryID
Definition: MooseTypes.h:75