https://mooseframework.inl.gov
FVInitialConditionTempl.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 "FVInitialConditionBase.h"
13 #include "MooseVariableFEBase.h"
14 
15 // libMesh
16 #include "libmesh/point.h"
17 #include "libmesh/vector_value.h"
18 #include "libmesh/elem.h"
19 
20 // forward declarations
21 class FEProblemBase;
22 template <typename>
24 
31 template <typename T>
33 {
34 public:
41 
42  virtual ~FVInitialConditionTempl();
43 
45 
46  virtual MooseVariableFEBase & variable() override;
47 
48  virtual void computeElement(const ElemInfo & elem_info) override;
49 
55  virtual T value(const Point & p) = 0;
56 
57 protected:
60 
62  Real & _t;
63 
66 
68  unsigned int _dim;
69 };
70 
71 template <typename T>
74 {
76 }
77 
79 
80 // Prevent implicit instantiation in other translation units where these classes are used
81 extern template class FVInitialConditionTempl<Real>;
FVInitialConditionTempl< Real > FVInitialCondition
FVInitialConditionTempl(const InputParameters &parameters)
Constructor.
virtual void computeElement(const ElemInfo &elem_info) override
Workhorse method for computing the initial conditions for block-restricted initial conditions...
Class for stuff related to variables.
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
This class provides an interface for common operations on field variables of both FE and FV types wit...
virtual MooseVariableFEBase & variable() override
retrieves the MOOSE variable that this initial condition acts upon
Specialization of SubProblem for solving nonlinear equations plus auxiliary equations.
MooseVariableField< T > & _base_var
The variable that this initial condition is acting upon.
unsigned int _dim
the mesh dimension
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static InputParameters validParams()
virtual T value(const Point &p)=0
The value of the variable at a point.
const InputParameters & parameters() const
Get the parameters of the object.
static InputParameters validParams()
Class used for caching additional information for elements such as the volume and centroid...
Definition: ElemInfo.h:25
This is a template class that implements the workhorse compute and computeNodal methods.
unsigned int THREAD_ID
Definition: MooseTypes.h:209