/[escript]/trunk/finley/src/CPPAdapter/MeshAdapterFactory.h
ViewVC logotype

Contents of /trunk/finley/src/CPPAdapter/MeshAdapterFactory.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 472 - (show annotations)
Fri Jan 27 01:50:59 2006 UTC (13 years, 2 months ago) by jgs
File MIME type: text/plain
File size: 5438 byte(s)
rationalise all #includes

1 /* $Id$ */
2 /*
3 ******************************************************************************
4 * *
5 * COPYRIGHT ACcESS 2004 - All Rights Reserved *
6 * *
7 * This software is the property of ACcESS. No part of this code *
8 * may be copied in any form or by any means without the expressed written *
9 * consent of ACcESS. Copying, use or modification of this software *
10 * by any unauthorised person is illegal unless that person has a software *
11 * license agreement with ACcESS. *
12 * *
13 ******************************************************************************
14 */
15
16 #if !defined finley_MeshAdapterFactory_20040526_H
17 #define finley_MeshAdapterFactory_20040526_H
18
19 extern "C" {
20 #include "Finley.h"
21 #include "Mesh.h"
22 #include "RectangularMesh.h"
23 }
24
25 #include "MeshAdapter.h"
26 #include "FinleyError.h"
27
28 #include "escript/Data/AbstractContinuousDomain.h"
29
30 #include <boost/python/list.hpp>
31 #include <boost/python/extract.hpp>
32
33 #include <iostream>
34 #include <sstream>
35
36 namespace finley {
37 /**
38 \brief
39 A suite of factory methods for creating various MeshAdapters.
40
41 Description:
42 A suite of factory methods for creating various MeshAdapters.
43 */
44
45 /**
46 \brief
47 Read a mesh from a file
48 \param fileName Input - The name of the file.
49 \param integrationOrder Input - order of the quadrature scheme.
50 If integrationOrder<0 the integration order is selected independently.
51 */
52 escript::AbstractContinuousDomain* readMesh(const std::string& fileName,
53 int integrationOrder=-1);
54 /**
55 \brief
56 Creates a rectangular mesh with n0 x n1 x n2 elements over the brick
57 [0,l0] x [0,l1] x [0,l2].
58
59 \param n0,n1,n2 Input - number of elements in each dimension
60 \param order Input - =1 or =2 gives the order of shape function
61 \param l0,l1,l2 Input - length of each side of brick
62 \param integrationOrder Input - order of the quadrature scheme.
63 \param useElementsOnFace Input - whether or not to use elements on face
64 \param periodic0, periodic1, periodic2 Input - whether or not boundary
65 conditions of the dimension are periodic
66 */
67 escript::AbstractContinuousDomain* brick(int n0=1,int n1=1,int n2=1,int order=1,
68 double l0=1.0,double l1=1.0,double l2=1.0,
69 int periodic0=0,int periodic1=0,
70 int periodic2=0,
71 int integrationOrder=-1,
72 int useElementsOnFace=0);
73 /**
74 \brief
75 Creates a rectangular mesh with n0 x n1 elements over the brick
76 [0,l0] x [0,l1].
77
78 \param n0,n1 Input - number of elements in each dimension
79 \param order Input - =1 or =2 gives the order of shape function
80 \param l0,l1 Input - length of each side of brick
81 \param integrationOrder Input - order of the quadrature scheme.
82 If integrationOrder<0 the integration order is selected
83 independently.
84 \param periodic0, periodic1 Input - whether or not the boundary
85 conditions of the dimension are periodic
86 \param useElementsOnFace Input - whether or not to use elements on face
87 */
88 escript::AbstractContinuousDomain* rectangle(int n0=1,int n1=1,int order=1,
89 double l0=1.0, double l1=1.0,
90 int periodic0=false,int periodic1=false,
91 int integrationOrder=-1,
92 int useElementsOnFace=false);
93 /**
94 \brief
95 Creates an equidistant mesh with n elements over the interval [0,l].
96 \param n0 Input - number of elements
97 \param order Input - =1 or =2 gives the order of shape function.
98 \param l0 Input - length of the brick
99 \param integrationOrder Input - order of the quadrature scheme.
100 If integrationOrder<0 the integration order is selected
101 independently.
102 \param periodic0 Input - whether or not the boundary conditions are
103 periodic
104 \param useElementsOnFace Input - whether or not to use the elements
105 on the face
106 */
107 escript::AbstractContinuousDomain* interval(int n0=1,int order=1,double l0=1.0,
108 int periodic0=false,
109 int integrationOrder=-1,
110 int useElementsOnFace=false);
111 /**
112 \brief
113 Merges a list of meshes into one list.
114 \param meshList Input - The list of meshes.
115 */
116 escript::AbstractContinuousDomain* meshMerge(const boost::python::list& meshList);
117 /**
118 \brief
119 Detects matching faces in the mesh, removes them from the mesh
120 and joins the elements touched by the face elements.
121 \param meshList Input - The list of meshes.
122 \param safetyFactor Input - ??
123 \param tolerance Input - ??
124 */
125 escript::AbstractContinuousDomain* glueFaces(const boost::python::list& meshList,
126 double safetyFactor=0.2,
127 double tolerance=100.*std::numeric_limits<double>::epsilon());
128 /**
129 \brief
130 Detects matching faces in the mesh and replaces them by joint elements.
131 \param meshList Input - The list of meshes.
132 \param safetyFactor Input - ??
133 \param tolerance Input - ??
134 */
135 escript::AbstractContinuousDomain* joinFaces(const boost::python::list& meshList,
136 double safetyFactor=0.2,
137 double tolerance=100.*std::numeric_limits<double>::epsilon());
138
139 } // end of namespace
140 #endif

Properties

Name Value
svn:eol-style native
svn:keywords Author Date Id Revision

  ViewVC Help
Powered by ViewVC 1.1.26