https://mooseframework.inl.gov
AnnularMesh.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 "MooseMesh.h"
13 
17 class AnnularMesh : public MooseMesh
18 {
19 public:
21 
23  AnnularMesh(const AnnularMesh & /* other_mesh */) = default;
24 
25  // No copy
26  AnnularMesh & operator=(const AnnularMesh & other_mesh) = delete;
27 
28  virtual std::unique_ptr<MooseMesh> safeClone() const override;
29 
30  virtual void buildMesh() override;
31  virtual Real getMinInDimension(unsigned int component) const override;
32  virtual Real getMaxInDimension(unsigned int component) const override;
33  virtual void prepared(bool state) override;
34 
35 protected:
37  const unsigned _nr;
38 
40  const unsigned _nt;
41 
43  const Real _rmin;
44 
46  const Real _rmax;
47 
49  const Real _dmin;
50 
52  const Real _dmax;
53 
55  const bool _radians;
56 
58  const Real _growth_r;
59 
61  const Real _len;
62 
64  const bool _full_annulus;
65 
68 
71 
74 };
virtual std::unique_ptr< MooseMesh > safeClone() const override
A safer version of the clone() method that hands back an allocated object wrapped in a smart pointer...
Definition: AnnularMesh.C:156
virtual void buildMesh() override
Must be overridden by child classes.
Definition: AnnularMesh.C:162
static InputParameters validParams()
Definition: AnnularMesh.C:20
bool prepared() const
Setter/getter for whether the mesh is prepared.
Definition: MooseMesh.C:3132
const Real _growth_r
Bias on radial meshing.
Definition: AnnularMesh.h:58
virtual Real getMinInDimension(unsigned int component) const override
Returns the min or max of the requested dimension respectively.
Definition: AnnularMesh.C:118
const SubdomainID _tri_subdomain_id
Subdomain ID of created tri elements (that only exist if rmin=0)
Definition: AnnularMesh.h:70
const Real _rmin
Minimum radius.
Definition: AnnularMesh.h:43
const Real _rmax
Maximum radius.
Definition: AnnularMesh.h:46
const unsigned _nr
Number of elements in radial direction.
Definition: AnnularMesh.h:37
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
AnnularMesh(const InputParameters &parameters)
Definition: AnnularMesh.C:68
AnnularMesh & operator=(const AnnularMesh &other_mesh)=delete
const bool _radians
Bool to check if radians are given in the input file.
Definition: AnnularMesh.h:55
const bool _full_annulus
Whether a full annulus (as opposed to a sector) will needs to generate.
Definition: AnnularMesh.h:64
const SubdomainID _quad_subdomain_id
Subdomain ID of created quad elements.
Definition: AnnularMesh.h:67
MooseMesh wraps a libMesh::Mesh object and enhances its capabilities by caching additional data and s...
Definition: MooseMesh.h:88
const Real _len
rmax = rmin + len + len*g + len*g^2 + len*g^3 + ... + len*g^(nr-1) = rmin + len*(1 - g^nr)/(1 - g) ...
Definition: AnnularMesh.h:61
Mesh generated from parameters.
Definition: AnnularMesh.h:17
virtual Real getMaxInDimension(unsigned int component) const override
Definition: AnnularMesh.C:137
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
const Real _dmin
Minimum angle in degrees.
Definition: AnnularMesh.h:49
const InputParameters & parameters() const
Get the parameters of the object.
bool _dims_may_have_changed
Boolean to indicate that dimensions may have changed.
Definition: AnnularMesh.h:73
const Real _dmax
Maximum angle in degrees.
Definition: AnnularMesh.h:52
const unsigned _nt
Number of elements in angular direction.
Definition: AnnularMesh.h:40