www.mooseframework.org
SmoothCircleBaseIC.h
Go to the documentation of this file.
1 /****************************************************************/
2 /* MOOSE - Multiphysics Object Oriented Simulation Environment */
3 /* */
4 /* All contents are licensed under LGPL V2.1 */
5 /* See LICENSE for full restrictions */
6 /****************************************************************/
7 #ifndef SMOOTHCIRCLEBASEIC_H
8 #define SMOOTHCIRCLEBASEIC_H
9 
10 #include "InitialCondition.h"
11 #include "MooseRandom.h"
12 
13 // Forward Declarations
14 class SmoothCircleBaseIC;
15 
16 template <>
17 InputParameters validParams<SmoothCircleBaseIC>();
18 
24 class SmoothCircleBaseIC : public InitialCondition
25 {
26 public:
27  SmoothCircleBaseIC(const InputParameters & parameters);
28 
29  virtual Real value(const Point & p);
30  virtual RealGradient gradient(const Point & p);
31 
32  virtual void initialSetup();
33 
34 protected:
35  virtual Real computeCircleValue(const Point & p, const Point & center, const Real & radius);
36  virtual RealGradient
37  computeCircleGradient(const Point & p, const Point & center, const Real & radius);
38 
39  virtual void computeCircleRadii() = 0;
40  virtual void computeCircleCenters() = 0;
41 
42  MooseMesh & _mesh;
43 
44  Real _invalue;
45  Real _outvalue;
46  Real _int_width;
49 
50  unsigned int _num_dim;
51 
52  std::vector<Point> _centers;
53  std::vector<Real> _radii;
54 
55  MooseRandom _random;
56 };
57 
58 #endif // SMOOTHCIRCLEBASEIC_H
virtual Real computeCircleValue(const Point &p, const Point &center, const Real &radius)
std::vector< Real > _radii
std::vector< Point > _centers
virtual Real value(const Point &p)
virtual RealGradient computeCircleGradient(const Point &p, const Point &center, const Real &radius)
SmoothCircleBaseIC(const InputParameters &parameters)
SmoothcircleBaseIC is the base class for all initial conditions that create circles.
virtual void initialSetup()
InputParameters validParams< SmoothCircleBaseIC >()
virtual RealGradient gradient(const Point &p)
virtual void computeCircleRadii()=0
virtual void computeCircleCenters()=0