Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Nektar
Nektar
Commits
82ba5c00
Commit
82ba5c00
authored
Nov 19, 2012
by
Dave Moxey
Browse files
Fixed compiler warnings in SpatialDomains.
parent
7b441300
Changes
25
Hide whitespace changes
Inline
Side-by-side
library/SpatialDomains/Conditions.cpp
View file @
82ba5c00
...
...
@@ -43,8 +43,9 @@ namespace Nektar
namespace
SpatialDomains
{
BoundaryConditions
::
BoundaryConditions
(
const
LibUtilities
::
SessionReaderSharedPtr
&
pSession
,
const
MeshGraphSharedPtr
&
meshGraph
)
:
m_session
(
pSession
),
m_meshGraph
(
meshGraph
)
:
m_meshGraph
(
meshGraph
),
m_session
(
pSession
)
{
Read
(
m_session
->
GetElement
(
"Nektar/Conditions"
));
}
...
...
@@ -80,8 +81,6 @@ namespace Nektar
TiXmlElement
*
boundaryRegions
=
conditions
->
FirstChildElement
(
"BOUNDARYREGIONS"
);
ASSERTL0
(
boundaryRegions
,
"Unable to find BOUNDARYREGIONS block."
);
int
regionIndx
=
0
;
// See if we have boundary regions defined.
TiXmlElement
*
boundaryRegionsElement
=
boundaryRegions
->
FirstChildElement
(
"B"
);
...
...
library/SpatialDomains/GeomFactors1D.cpp
View file @
82ba5c00
...
...
@@ -315,7 +315,6 @@ namespace Nektar
}
int
i
;
StdRegions
::
ExpansionType
shape
=
m_coords
[
0
]
->
DetExpansionType
();
NekDouble
fac
;
// Regular geometry case
...
...
library/SpatialDomains/GeomFactors2D.cpp
View file @
82ba5c00
...
...
@@ -1076,10 +1076,6 @@ namespace Nektar
m_laplacianMetricIsZero
=
Array
<
OneD
,
bool
>
(
3
,
false
);
m_isUsingLaplMetrics
=
true
;
// Get hold of the quadrature weights
const
Array
<
OneD
,
const
NekDouble
>&
w0
=
tbasis
[
0
]
->
GetW
();
const
Array
<
OneD
,
const
NekDouble
>&
w1
=
tbasis
[
1
]
->
GetW
();
switch
(
shape
)
{
case
StdRegions
::
eQuadrilateral
:
...
...
library/SpatialDomains/GeomFactors3D.cpp
View file @
82ba5c00
...
...
@@ -301,7 +301,8 @@ namespace Nektar
// Get hold of the quadrature weights
const
Array
<
OneD
,
const
NekDouble
>&
w0
=
tbasis
[
0
]
->
GetW
();
const
Array
<
OneD
,
const
NekDouble
>&
w1
=
tbasis
[
1
]
->
GetW
();
const
Array
<
OneD
,
const
NekDouble
>&
w2
=
tbasis
[
2
]
->
GetW
();
/// @todo Is this a bug?
//const Array<OneD, const NekDouble>& w2 = tbasis[2]->GetW();
// Multiply the jacobian with the quadrature weights
switch
(
shape
)
...
...
library/SpatialDomains/Geometry.cpp
View file @
82ba5c00
...
...
@@ -182,6 +182,10 @@ namespace Nektar
return
v_GetEid
(
i
);
}
int
Geometry
::
GetFid
(
int
i
)
const
{
return
v_GetFid
(
i
);
}
int
Geometry
::
GetNumVerts
()
const
{
...
...
@@ -321,21 +325,20 @@ namespace Nektar
return
0
;
}
void
Geometry
::
v_GenGeomFactors
(
const
Array
<
OneD
,
const
LibUtilities
::
BasisSharedPtr
>&
tbasis
)
int
Geometry
::
v_GetFid
(
int
i
)
const
{
NEKERROR
(
ErrorUtil
::
efatal
,
"This function is only valid for shape type geometries"
);
"This function is only valid for expansion type geometries"
);
return
0
;
}
int
Geometry
::
v_GetVid
(
int
i
)
const
void
Geometry
::
v_GenGeomFactors
(
const
Array
<
OneD
,
const
LibUtilities
::
BasisSharedPtr
>&
tbasis
)
{
NEKERROR
(
ErrorUtil
::
efatal
,
"This function is only valid for expansion type geometries"
);
return
0
;
"This function is only valid for shape type geometries"
);
}
int
Geometry
::
v_GetNumVerts
()
const
{
NEKERROR
(
ErrorUtil
::
efatal
,
...
...
library/SpatialDomains/Geometry.h
View file @
82ba5c00
...
...
@@ -130,7 +130,8 @@ namespace Nektar
SPATIAL_DOMAINS_EXPORT
int
GetGlobalID
(
void
);
SPATIAL_DOMAINS_EXPORT
void
SetGlobalID
(
int
globalid
);
SPATIAL_DOMAINS_EXPORT
int
GetVid
(
int
i
)
const
;
SPATIAL_DOMAINS_EXPORT
int
GetEid
(
int
i
=
0
)
const
;
SPATIAL_DOMAINS_EXPORT
int
GetEid
(
int
i
)
const
;
SPATIAL_DOMAINS_EXPORT
int
GetFid
(
int
i
)
const
;
SPATIAL_DOMAINS_EXPORT
int
GetNumVerts
()
const
;
SPATIAL_DOMAINS_EXPORT
StdRegions
::
Orientation
GetEorient
(
const
int
i
)
const
;
...
...
@@ -151,27 +152,20 @@ namespace Nektar
SPATIAL_DOMAINS_EXPORT
static
GeomFactorsSharedPtr
ValidateRegGeomFactor
(
GeomFactorsSharedPtr
geomFactor
);
static
GeomFactorsVector
m_regGeomFactorsManager
;
/// coordinate dimension
int
m_coordim
;
GeomFactorsSharedPtr
m_geomFactors
;
/// enum identifier to determine if quad points are filled
GeomState
m_state
;
static
GeomFactorsVector
m_regGeomFactorsManager
;
GeomShapeType
m_geomShapeType
;
int
m_globalID
;
GeomType
m_geomType
;
GeomShapeType
m_geomShapeType
;
int
m_globalID
;
void
GenGeomFactors
(
const
Array
<
OneD
,
const
LibUtilities
::
BasisSharedPtr
>&
tbasis
);
private:
GeomType
m_geomType
;
//---------------------------------------
// Element connection functions
//---------------------------------------
...
...
@@ -183,15 +177,15 @@ namespace Nektar
int
locid
);
virtual
int
v_NumElmtConnected
()
const
;
//---------------------------------------
// Helper functions
//---------------------------------------
virtual
int
v_GetEid
(
int
i
)
const
;
virtual
int
v_GetVid
(
int
i
)
const
;
virtual
int
v_GetFid
(
int
i
)
const
;
virtual
void
v_GenGeomFactors
(
const
Array
<
OneD
,
const
LibUtilities
::
BasisSharedPtr
>&
tbasis
);
virtual
int
v_GetVid
(
int
i
)
const
;
virtual
int
v_GetNumVerts
()
const
;
virtual
StdRegions
::
Orientation
v_GetEorient
(
const
int
i
)
const
;
...
...
@@ -230,7 +224,6 @@ namespace Nektar
int
i
;
size_t
seed
=
0
;
int
nVert
=
p
->
GetNumVerts
();
int
nEdge
=
p
->
GetNumEdges
();
std
::
vector
<
unsigned
int
>
ids
(
nVert
);
for
(
i
=
0
;
i
<
nVert
;
++
i
)
...
...
library/SpatialDomains/Geometry1D.cpp
View file @
82ba5c00
...
...
@@ -74,7 +74,10 @@ namespace Nektar
v_WriteToFile
(
outfile
,
dumpVar
);
}
int
Geometry1D
::
GetEid
()
const
{
return
v_GetEid
();
}
int
Geometry1D
::
v_GetShapeDim
()
const
...
...
library/SpatialDomains/Geometry1D.h
View file @
82ba5c00
...
...
@@ -69,8 +69,11 @@ namespace Nektar
SPATIAL_DOMAINS_EXPORT
void
WriteToFile
(
std
::
ofstream
&
outfile
,
const
int
dumpVar
);
SPATIAL_DOMAINS_EXPORT
int
GetEid
()
const
;
private:
protected:
using
Geometry
::
v_GetEid
;
virtual
int
v_GetShapeDim
()
const
;
virtual
int
v_GetEid
()
const
;
virtual
int
v_GetVid
(
int
i
)
const
;
...
...
library/SpatialDomains/Geometry2D.h
View file @
82ba5c00
...
...
@@ -71,7 +71,7 @@ namespace Nektar
// Helper functions
//---------------------------------------
SPATIAL_DOMAINS_EXPORT
int
GetFid
()
const
;
SPATIAL_DOMAINS_EXPORT
int
GetFid
()
const
;
SPATIAL_DOMAINS_EXPORT
const
VertexComponentSharedPtr
GetVertex
(
int
i
)
const
;
SPATIAL_DOMAINS_EXPORT
const
Geometry1DSharedPtr
...
...
@@ -104,11 +104,11 @@ namespace Nektar
Array
<
OneD
,
StdRegions
::
StdExpansion2DSharedPtr
>
m_xmap
;
private:
//---------------------------------------
// Helper functions
//---------------------------------------
using
Geometry
::
v_GetFid
;
virtual
int
v_GetShapeDim
()
const
;
virtual
int
v_GetFid
()
const
;
...
...
library/SpatialDomains/Geometry3D.cpp
View file @
82ba5c00
...
...
@@ -88,14 +88,6 @@ namespace Nektar
return
v_GetFaceOrient
(
i
);
}
/**
* @brief Return the ID of face i in this element.
*/
int
Geometry3D
::
GetFid
(
int
i
)
const
{
return
v_GetFid
(
i
);
}
//---------------------------------------
// 3D Geometry Methods
...
...
@@ -167,8 +159,7 @@ namespace Nektar
void
Geometry3D
::
v_GenGeomFactors
(
const
Array
<
OneD
,
const
LibUtilities
::
BasisSharedPtr
>
&
tbasis
)
{
GeomType
Gtype
=
eRegular
;
GeomShapeType
GSType
=
eQuadrilateral
;
GeomType
Gtype
=
eRegular
;
v_FillGeom
();
...
...
library/SpatialDomains/Geometry3D.h
View file @
82ba5c00
...
...
@@ -81,8 +81,6 @@ namespace Nektar
GetFace
(
int
i
);
SPATIAL_DOMAINS_EXPORT
StdRegions
::
Orientation
GetFaceOrient
(
const
int
i
)
const
;
SPATIAL_DOMAINS_EXPORT
int
GetFid
(
int
i
)
const
;
SPATIAL_DOMAINS_EXPORT
StdRegions
::
StdExpansion3DSharedPtr
GetXmap
(
const
int
i
);
...
...
library/SpatialDomains/MeshComponents.h
View file @
82ba5c00
...
...
@@ -134,14 +134,6 @@ namespace Nektar
int
m_vid
;
int
m_coordim
;
std
::
list
<
CompToElmt
>
m_elmtMap
;
private:
virtual
int
v_GetVid
(
void
)
{
return
GetVid
();
}
};
// -----------------------------------------------------------------------
...
...
library/SpatialDomains/MeshGraph.cpp
View file @
82ba5c00
...
...
@@ -243,7 +243,6 @@ namespace Nektar
void
MeshGraph
::
ReadGeometry
(
TiXmlDocument
&
doc
)
{
TiXmlHandle
docHandle
(
&
doc
);
TiXmlNode
*
node
=
NULL
;
TiXmlElement
*
mesh
=
NULL
;
TiXmlElement
*
master
=
NULL
;
// Master tag within which all data is contained.
...
...
@@ -818,7 +817,6 @@ namespace Nektar
CompositeMap
compositeVector
;
GetCompositeList
(
compositeListStr
,
compositeVector
);
bool
useExpansionType
=
false
;
ExpansionType
expansion_type_x
,
expansion_type_y
,
expansion_type_z
;
int
num_modes_x
,
num_modes_y
,
num_modes_z
;
...
...
@@ -1839,8 +1837,6 @@ namespace Nektar
SpatialDomains
::
FieldDefinitionsSharedPtr
fielddef
=
MemoryManager
<
SpatialDomains
::
FieldDefinitions
>::
AllocateSharedPtr
(
shape
,
elementIds
,
basis
,
UniOrder
,
numModes
,
Fields
,
numHomoDir
,
homoLengths
,
homoZIDs
,
homoYIDs
,
points
,
pointDef
,
numPoints
,
numPointDef
);
int
datasize
=
CheckFieldDefinition
(
fielddef
);
fielddefs
.
push_back
(
fielddef
);
element
=
element
->
NextSiblingElement
(
"ELEMENTS"
);
...
...
library/SpatialDomains/MeshGraph1D.cpp
View file @
82ba5c00
...
...
@@ -59,7 +59,7 @@ namespace Nektar
}
// \brief Read segments (and general MeshGraph) given filename.
void
MeshGraph1D
::
ReadGeometry
(
std
::
string
&
infilename
)
void
MeshGraph1D
::
ReadGeometry
(
const
std
::
string
&
infilename
)
{
TiXmlDocument
doc
(
infilename
);
...
...
@@ -80,7 +80,6 @@ namespace Nektar
MeshGraph
::
ReadGeometry
(
doc
);
TiXmlHandle
docHandle
(
&
doc
);
TiXmlNode
*
node
=
NULL
;
TiXmlElement
*
mesh
=
NULL
;
/// Look for all geometry related data in GEOMETRY block.
...
...
library/SpatialDomains/MeshGraph1D.h
View file @
82ba5c00
...
...
@@ -52,7 +52,7 @@ namespace Nektar
SPATIAL_DOMAINS_EXPORT
MeshGraph1D
(
const
LibUtilities
::
SessionReaderSharedPtr
&
pSession
);
SPATIAL_DOMAINS_EXPORT
virtual
~
MeshGraph1D
();
SPATIAL_DOMAINS_EXPORT
void
ReadGeometry
(
std
::
string
&
infilename
);
SPATIAL_DOMAINS_EXPORT
void
ReadGeometry
(
const
std
::
string
&
infilename
);
SPATIAL_DOMAINS_EXPORT
void
ReadGeometry
(
TiXmlDocument
&
doc
);
SPATIAL_DOMAINS_EXPORT
void
ReadElements
(
TiXmlDocument
&
doc
);
SPATIAL_DOMAINS_EXPORT
void
ReadComposites
(
TiXmlDocument
&
doc
);
...
...
library/SpatialDomains/MeshGraph2D.cpp
View file @
82ba5c00
...
...
@@ -58,7 +58,7 @@ namespace Nektar
ReadExpansions
(
pSession
->
GetDocument
());
}
void
MeshGraph2D
::
ReadGeometry
(
std
::
string
&
infilename
)
void
MeshGraph2D
::
ReadGeometry
(
const
std
::
string
&
infilename
)
{
TiXmlDocument
doc
(
infilename
);
bool
loadOkay
=
doc
.
LoadFile
();
...
...
@@ -79,7 +79,6 @@ namespace Nektar
MeshGraph
::
ReadGeometry
(
doc
);
TiXmlHandle
docHandle
(
&
doc
);
TiXmlNode
*
node
=
NULL
;
TiXmlElement
*
mesh
=
NULL
;
/// Look for all geometry related data in GEOMETRY block.
...
...
@@ -119,7 +118,6 @@ namespace Nektar
/// missing element numbers due to the text block format.
std
::
string
edgeStr
;
int
i
,
indx
;
int
err
=
0
;
int
nextEdgeNumber
=
-
1
;
// Curved Edges
...
...
library/SpatialDomains/MeshGraph2D.h
View file @
82ba5c00
...
...
@@ -61,7 +61,7 @@ namespace Nektar
SPATIAL_DOMAINS_EXPORT
MeshGraph2D
(
const
LibUtilities
::
SessionReaderSharedPtr
&
pSession
);
SPATIAL_DOMAINS_EXPORT
virtual
~
MeshGraph2D
();
SPATIAL_DOMAINS_EXPORT
void
ReadGeometry
(
std
::
string
&
infilename
);
SPATIAL_DOMAINS_EXPORT
void
ReadGeometry
(
const
std
::
string
&
infilename
);
SPATIAL_DOMAINS_EXPORT
void
ReadGeometry
(
TiXmlDocument
&
doc
);
SPATIAL_DOMAINS_EXPORT
SegGeomSharedPtr
GetSegGeom
(
int
eID
);
...
...
library/SpatialDomains/MeshGraph3D.cpp
View file @
82ba5c00
...
...
@@ -79,7 +79,6 @@ namespace Nektar
MeshGraph
::
ReadGeometry
(
doc
);
TiXmlHandle
docHandle
(
&
doc
);
TiXmlNode
*
node
=
NULL
;
TiXmlElement
*
mesh
=
NULL
;
/// Look for all geometry related data in GEOMETRY block.
...
...
@@ -119,7 +118,6 @@ namespace Nektar
/// with missing element numbers due to the text block format.
std
::
string
edgeStr
;
int
i
,
indx
;
int
err
=
0
;
int
nextEdgeNumber
=
-
1
;
// Curved Edges
...
...
library/SpatialDomains/QuadGeom.cpp
View file @
82ba5c00
...
...
@@ -703,8 +703,6 @@ namespace Nektar
int
elmtid
=
m_fid
;
int
offset
=
0
;
//determine y
int
cnt
=
0
;
while
(
abs
(
F2
)
>
0.00001
||
abs
(
F1
)
>
0.00001
)
...
...
library/SpatialDomains/QuadGeom.h
View file @
82ba5c00
...
...
@@ -48,8 +48,8 @@ namespace Nektar
{
namespace
SpatialDomains
{
class
QuadGeom
;
class
Curve
;
class
QuadGeom
;
struct
Curve
;
typedef
boost
::
shared_ptr
<
Curve
>
CurveSharedPtr
;
typedef
boost
::
shared_ptr
<
QuadGeom
>
QuadGeomSharedPtr
;
typedef
std
::
vector
<
QuadGeomSharedPtr
>
QuadGeomVector
;
...
...
Prev
1
2
Next
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment