https://mooseframework.inl.gov
Loading...
Searching...
No Matches
SideIntegralPostprocessor.h
Go to the documentation of this file.
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#pragma once
11
12#include "SidePostprocessor.h"
13
21{
22public:
24
26
27 virtual void initialSetup() override;
28 virtual void initialize() override;
29 virtual void execute() override;
30 virtual void finalize() override;
31 virtual Real getValue() const override;
32 virtual void threadJoin(const UserObject & y) override;
33
34protected:
35 virtual Real computeQpIntegral() = 0;
36 virtual Real computeFaceInfoIntegral(const FaceInfo * /* fi */)
37 {
38 mooseError("Integral over faces have not been implemented for this postprocessor");
39 };
40 virtual Real computeIntegral();
41
45 virtual void errorNoFaceInfo() const
46 {
47 mooseError("Face info integration was specified, but the mesh contains no face info objects.");
48 }
49
51 unsigned int _qp;
52
55
58};
void mooseError(Args &&... args)
Emit an error message with the given stringified, concatenated args and terminate the application.
Definition MooseError.h:311
This data structure is used to store geometric and variable related metadata about each cell face in ...
Definition FaceInfo.h:38
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system.
const InputParameters & parameters() const
Get the parameters of the object.
Definition MooseBase.h:131
This postprocessor computes a surface integral of the specified variable on a sideset on the boundary...
bool _qp_integration
Whether to integrate over quadrature points or FaceInfos.
virtual void threadJoin(const UserObject &y) override
Must override.
static InputParameters validParams()
virtual void initialize() override
Called before execute() is ever called so that data can be cleared.
virtual void errorNoFaceInfo() const
Error method to call when face info is needed but not available.
Real _integral_value
Holds the postprocessor result, the integral.
virtual Real computeQpIntegral()=0
virtual Real computeFaceInfoIntegral(const FaceInfo *)
virtual void initialSetup() override
Gets called at the beginning of the simulation before this object is asked to do its job.
virtual void execute() override
Execute method.
unsigned int _qp
The local quadrature point index when computing an integral over quadrature points.
virtual void finalize() override
This is called after execute() and after threadJoin()! This is probably where you want to do MPI comm...
virtual Real getValue() const override
This will get called to actually grab the final value the postprocessor has calculated.
Base class for postprocessors executed on one or more sidesets.
Base class for user-specific data.
Definition UserObject.h:20