Toggle navigation
Documentation
Big picture
The finite element method
The data structure
Not-so-quick guide
Optimisation
Order of action functions
Example codes and tutorials
List of example codes and tutorials
Meshing
Solvers
MPI parallel processing
Post-processing/visualisation
Other
Change log
Creating documentation
Coding conventions
Index
FAQ
Installation
Installation guide
Copyright
About
People
Contact/Get involved
Publications
Acknowledgements
Picture show
Go
src
meshes
geompack_mesh.template.h
Go to the documentation of this file.
1
// LIC// ====================================================================
2
// LIC// This file forms part of oomph-lib, the object-oriented,
3
// LIC// multi-physics finite-element library, available
4
// LIC// at http://www.oomph-lib.org.
5
// LIC//
6
// LIC// Copyright (C) 2006-2024 Matthias Heil and Andrew Hazel
7
// LIC//
8
// LIC// This library is free software; you can redistribute it and/or
9
// LIC// modify it under the terms of the GNU Lesser General Public
10
// LIC// License as published by the Free Software Foundation; either
11
// LIC// version 2.1 of the License, or (at your option) any later version.
12
// LIC//
13
// LIC// This library is distributed in the hope that it will be useful,
14
// LIC// but WITHOUT ANY WARRANTY; without even the implied warranty of
15
// LIC// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16
// LIC// Lesser General Public License for more details.
17
// LIC//
18
// LIC// You should have received a copy of the GNU Lesser General Public
19
// LIC// License along with this library; if not, write to the Free Software
20
// LIC// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
21
// LIC// 02110-1301 USA.
22
// LIC//
23
// LIC// The authors may be contacted at oomph-lib@maths.man.ac.uk.
24
// LIC//
25
// LIC//====================================================================
26
#ifndef OOMPH_GEOMPACK_MESH_HEADER
27
#define OOMPH_GEOMPACK_MESH_HEADER
28
29
#include "../generic/geompack_scaffold_mesh.h"
30
31
namespace
oomph
32
{
33
//=========start_of_geompackquadmesh_class================================
34
/// Quadrilateral mesh generator; Uses input from Geompack++.
35
/// See: http://members.shaw.ca/bjoe/
36
/// Currently only for four-noded quads -- extension to higher-order
37
/// quads should be trivial (see the corresponding classes for
38
/// triangular meshes).
39
//========================================================================
40
template
<
class
ELEMENT>
41
class
GeompackQuadMesh
:
public
Mesh
42
{
43
public
:
44
/// Constructor with the input files
45
GeompackQuadMesh
(
const
std::string
& mesh_file_name,
46
const
std::string
& curve_file_name,
47
TimeStepper
* time_stepper_pt = &
Mesh::Default_TimeStepper
)
48
{
49
// Mesh can only be built with four-noded 2D Qelements.
50
MeshChecker::assert_geometric_element<QElementGeometricBase, ELEMENT>(2,
51
2);
52
53
// Build scaffold
54
Tmp_mesh_pt
=
55
new
GeompackQuadScaffoldMesh
(mesh_file_name, curve_file_name);
56
57
// Convert mesh from scaffold to actual mesh
58
build_from_scaffold
(time_stepper_pt);
59
60
// Kill the scaffold
61
delete
Tmp_mesh_pt
;
62
Tmp_mesh_pt
= 0;
63
}
64
65
/// Empty destructor
66
~GeompackQuadMesh
() {}
67
68
private
:
69
/// Temporary scaffold mesh
70
GeompackQuadScaffoldMesh
*
Tmp_mesh_pt
;
71
72
/// Build mesh from scaffold
73
void
build_from_scaffold
(
TimeStepper
* time_stepper_pt);
74
};
75
76
}
// namespace oomph
77
78
#endif
oomph::GeompackQuadMesh
Quadrilateral mesh generator; Uses input from Geompack++. See: http://members.shaw....
Definition:
geompack_mesh.template.h:42
oomph::GeompackQuadMesh::Tmp_mesh_pt
GeompackQuadScaffoldMesh * Tmp_mesh_pt
Temporary scaffold mesh.
Definition:
geompack_mesh.template.h:70
oomph::GeompackQuadMesh::build_from_scaffold
void build_from_scaffold(TimeStepper *time_stepper_pt)
Build mesh from scaffold.
Definition:
geompack_mesh.template.cc:42
oomph::GeompackQuadMesh::~GeompackQuadMesh
~GeompackQuadMesh()
Empty destructor.
Definition:
geompack_mesh.template.h:66
oomph::GeompackQuadMesh::GeompackQuadMesh
GeompackQuadMesh(const std::string &mesh_file_name, const std::string &curve_file_name, TimeStepper *time_stepper_pt=&Mesh::Default_TimeStepper)
Constructor with the input files.
Definition:
geompack_mesh.template.h:45
oomph::GeompackQuadScaffoldMesh
Mesh that is based on input files generated by the quadrilateral mesh generator Geompack.
Definition:
geompack_scaffold_mesh.h:39
oomph::Mesh
A general mesh class.
Definition:
mesh.h:67
oomph::Mesh::Default_TimeStepper
static Steady< 0 > Default_TimeStepper
Default Steady Timestepper, to be used in default arguments to Mesh constructors.
Definition:
mesh.h:75
oomph::TimeStepper
////////////////////////////////////////////////////////////////////// //////////////////////////////...
Definition:
timesteppers.h:231
oomph::Global_string_for_annotation::string
std::string string(const unsigned &i)
Return the i-th string or "" if the relevant string hasn't been defined.
Definition:
oomph_definitions.cc:286
oomph
//////////////////////////////////////////////////////////////////// ////////////////////////////////...
Definition:
advection_diffusion_elements.cc:30