GRINS-0.8.0
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
src
solver
include
grins
mesh_adaptive_solver_base.h
Go to the documentation of this file.
1
//-----------------------------------------------------------------------bl-
2
//--------------------------------------------------------------------------
3
//
4
// GRINS - General Reacting Incompressible Navier-Stokes
5
//
6
// Copyright (C) 2014-2017 Paul T. Bauman, Roy H. Stogner
7
// Copyright (C) 2010-2013 The PECOS Development Team
8
//
9
// This library is free software; you can redistribute it and/or
10
// modify it under the terms of the Version 2.1 GNU Lesser General
11
// Public License as published by the Free Software Foundation.
12
//
13
// This library is distributed in the hope that it will be useful,
14
// but WITHOUT ANY WARRANTY; without even the implied warranty of
15
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16
// Lesser General Public License for more details.
17
//
18
// You should have received a copy of the GNU Lesser General Public
19
// License along with this library; if not, write to the Free Software
20
// Foundation, Inc. 51 Franklin Street, Fifth Floor,
21
// Boston, MA 02110-1301 USA
22
//
23
//-----------------------------------------------------------------------el-
24
25
#ifndef GRINS_MESH_ADAPTIVE_SOLVER_BASE_H
26
#define GRINS_MESH_ADAPTIVE_SOLVER_BASE_H
27
28
// C++
29
#include <string>
30
31
// GRINS
32
#include "
grins/mesh_adaptivity_options.h
"
33
#include "
grins/error_estimator_options.h
"
34
35
//libMesh
36
#include "libmesh/libmesh.h"
37
#include "libmesh/mesh_refinement.h"
38
#include "libmesh/auto_ptr.h"
39
40
// libMesh forward declarations
41
class
GetPot;
42
namespace
libMesh
43
{
44
class
MeshBase;
45
class
ErrorVector;
46
}
47
48
namespace
GRINS
49
{
50
class
SolverContext;
51
52
class
MeshAdaptiveSolverBase
53
{
54
public
:
55
56
MeshAdaptiveSolverBase
(
const
GetPot& input );
57
58
virtual
~MeshAdaptiveSolverBase
(){}
59
60
protected
:
61
62
ErrorEstimatorOptions
_error_estimator_options
;
63
MeshAdaptivityOptions
_mesh_adaptivity_options
;
64
65
enum
RefinementFlaggingType
{
INVALID
= 0,
66
ERROR_TOLERANCE
,
67
N_ELEM_TARGET
,
68
ERROR_FRACTION
,
69
ELEM_FRACTION
,
70
MEAN_STD_DEV
};
71
72
RefinementFlaggingType
_refinement_type
;
73
74
libMesh::UniquePtr<libMesh::MeshRefinement>
_mesh_refinement
;
75
76
void
build_mesh_refinement
( libMesh::MeshBase& mesh );
77
78
void
set_refinement_type
(
const
GetPot& input,
79
const
MeshAdaptivityOptions
& mesh_adaptivity_options,
80
RefinementFlaggingType
& refinement_type );
81
82
bool
check_for_convergence
(
SolverContext
& context,
83
const
libMesh::ErrorVector& error )
const
;
84
85
void
flag_elements_for_refinement
(
const
libMesh::ErrorVector& error );
86
87
void
estimate_error_for_amr
(
SolverContext
& context, libMesh::ErrorVector& error );
88
89
void
perform_amr
(
SolverContext
& context,
const
libMesh::ErrorVector& error );
90
91
private
:
92
93
MeshAdaptiveSolverBase
();
94
95
};
96
97
}
// end namespace GRINS
98
99
#endif // GRINS_MESH_ADAPTIVE_SOLVER_BASE_H
GRINS::MeshAdaptiveSolverBase::N_ELEM_TARGET
Definition:
mesh_adaptive_solver_base.h:67
GRINS::MeshAdaptiveSolverBase::set_refinement_type
void set_refinement_type(const GetPot &input, const MeshAdaptivityOptions &mesh_adaptivity_options, RefinementFlaggingType &refinement_type)
Definition:
mesh_adaptive_solver_base.C:64
error_estimator_options.h
GRINS::MeshAdaptiveSolverBase::MEAN_STD_DEV
Definition:
mesh_adaptive_solver_base.h:70
GRINS::MeshAdaptiveSolverBase::INVALID
Definition:
mesh_adaptive_solver_base.h:65
GRINS::MeshAdaptiveSolverBase::ERROR_FRACTION
Definition:
mesh_adaptive_solver_base.h:68
mesh_adaptivity_options.h
GRINS::MeshAdaptiveSolverBase::~MeshAdaptiveSolverBase
virtual ~MeshAdaptiveSolverBase()
Definition:
mesh_adaptive_solver_base.h:58
GRINS::MeshAdaptiveSolverBase::build_mesh_refinement
void build_mesh_refinement(libMesh::MeshBase &mesh)
Definition:
mesh_adaptive_solver_base.C:48
libMesh
Definition:
bc_builder.h:43
GRINS::MeshAdaptiveSolverBase::perform_amr
void perform_amr(SolverContext &context, const libMesh::ErrorVector &error)
Definition:
mesh_adaptive_solver_base.C:221
GRINS::MeshAdaptiveSolverBase::estimate_error_for_amr
void estimate_error_for_amr(SolverContext &context, libMesh::ErrorVector &error)
Definition:
mesh_adaptive_solver_base.C:205
GRINS::MeshAdaptiveSolverBase::ERROR_TOLERANCE
Definition:
mesh_adaptive_solver_base.h:66
GRINS::MeshAdaptiveSolverBase::check_for_convergence
bool check_for_convergence(SolverContext &context, const libMesh::ErrorVector &error) const
Definition:
mesh_adaptive_solver_base.C:120
GRINS
GRINS namespace.
Definition:
arrhenius_catalycity.h:31
GRINS::MeshAdaptiveSolverBase::flag_elements_for_refinement
void flag_elements_for_refinement(const libMesh::ErrorVector &error)
Definition:
mesh_adaptive_solver_base.C:153
GRINS::MeshAdaptivityOptions
Container for mesh adaptivity options.
Definition:
mesh_adaptivity_options.h:39
GRINS::ErrorEstimatorOptions
Container for ErrorEstimator options.
Definition:
error_estimator_options.h:37
GRINS::MeshAdaptiveSolverBase::ELEM_FRACTION
Definition:
mesh_adaptive_solver_base.h:69
GRINS::MeshAdaptiveSolverBase::_refinement_type
RefinementFlaggingType _refinement_type
Definition:
mesh_adaptive_solver_base.h:72
GRINS::MeshAdaptiveSolverBase::_error_estimator_options
ErrorEstimatorOptions _error_estimator_options
Definition:
mesh_adaptive_solver_base.h:62
GRINS::MeshAdaptiveSolverBase::MeshAdaptiveSolverBase
MeshAdaptiveSolverBase()
GRINS::SolverContext
Simple class to hold objects passed to Solver::solve.
Definition:
solver_context.h:51
GRINS::MeshAdaptiveSolverBase::_mesh_refinement
libMesh::UniquePtr< libMesh::MeshRefinement > _mesh_refinement
Definition:
mesh_adaptive_solver_base.h:74
GRINS::MeshAdaptiveSolverBase::RefinementFlaggingType
RefinementFlaggingType
Definition:
mesh_adaptive_solver_base.h:65
GRINS::MeshAdaptiveSolverBase
Definition:
mesh_adaptive_solver_base.h:52
GRINS::MeshAdaptiveSolverBase::_mesh_adaptivity_options
MeshAdaptivityOptions _mesh_adaptivity_options
Definition:
mesh_adaptive_solver_base.h:63
Generated on Tue Dec 19 2017 12:47:28 for GRINS-0.8.0 by
doxygen
1.8.9.1