Assert.h
Go to the documentation of this file.
/*****************************************************************************
*
* Copyright (c) 2003-2020 by The University of Queensland
* http://www.uq.edu.au
*
* Primary Business: Queensland, Australia
* Licensed under the Apache License, version 2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
* Development until 2012 by Earth Systems Science Computational Center (ESSCC)
* Development 2012-2013 by School of Earth Sciences
* Development from 2014-2017 by Centre for Geoscience Computing (GeoComp)
* Development from 2019 by School of Earth and Environmental Sciences
**
*****************************************************************************/
#ifndef __ESCRIPT_ASSERT_H__
#define __ESCRIPT_ASSERT_H__
#if DOASSERT
//
// DOASSERT is defined, evaluate assertions and abort on failure.
//
#include <escript/EsysException.h>
#include <iostream>
#include <sstream>
#if ESYS_MPI
#include <mpi.h>
#define ESYS_ASSERT(assert_test, assert_msg)\
do {\
const bool result = (assert_test);\
if (!result) {\
std::ostringstream message;\
message << assert_msg << "\n\n"\
<< __FILE__ << ":" << __LINE__ << ": " << #assert_test << "\n";\
std::cerr << message.str();\
MPI_Abort(MPI_COMM_WORLD, 455347);\
}\
} while (0)
#else
#define ESYS_ASSERT(assert_test, assert_msg)\
do {\
const bool result = (assert_test);\
if (!result) {\
std::ostringstream message;\
message << assert_msg << "\n\n"\
<< __FILE__ << ":" << __LINE__ << ": " << #assert_test << "\n";\
throw escript::AssertException(message.str());\
}\
} while (0)
#endif // ESYS_MPI
#else // !DOASSERT
//
// DOASSERT is not defined, replace ESYS_ASSERT macro with no-op
//
#define ESYS_ASSERT(a,b)
#endif
#endif // __ESCRIPT_ASSERT_H__
dudley::ElementFile_Jacobians::numShapes
int numShapes
number of shape functions
Definition: dudley/src/ElementFile.h:68
FINLEY_POINTS
#define FINLEY_POINTS
Definition: Finley.h:69
escript::Data::isComplex
bool isComplex() const
True if components of this data are stored as complex.
Definition: Data.cpp:1160
dudley::QuadWeight
static const double QuadWeight[4][2]
Definition: ShapeTable.h:86
finley::Assemble_jacobians_3D_M2D_E2D
void Assemble_jacobians_3D_M2D_E2D(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:680
dudley::util::smallMatSetMult1
void smallMatSetMult1(int len, int A1, int A2, Scalar *A, int B2, const Scalar *B, const double *C)
Definition: dudley/src/Util.cpp:116
finley::Assemble_NodeCoordinates
void Assemble_NodeCoordinates(const NodeFile *nodes, escript::Data &x)
copies node coordinates into expanded Data object x
Definition: finley/src/Assemble_NodeCoordinates.cpp:52
finley::AssembleParameters::NN
int NN
leading dimension of element node table
Definition: finley/src/Assemble.h:93
escript::DataTypes::real_t
double real_t
type of all real-valued scalars in escript
Definition: DataTypes.h:79
dudley::Assemble_jacobians_3D_M2D_E2D
void Assemble_jacobians_3D_M2D_E2D(const double *coordinates, int numQuad, dim_t numElements, int numNodes, const index_t *nodes, double *dTdX, double *absD, double *quadWeight, const index_t *elementId)
Definition: dudley/src/Assemble_jacobians.cpp:255
finley::AssembleParameters::numDim
int numDim
number of spatial dimensions
Definition: finley/src/Assemble.h:91
finley::util::addScatter
void addScatter(int len, const index_t *index, int numData, const Scalar *in, Scalar *out, index_t upperBound)
Definition: finley/src/Util.cpp:83
dudley::Assemble_LumpedSystem
void Assemble_LumpedSystem(const NodeFile *nodes, const ElementFile *elements, escript::Data &lumpedMat, const escript::Data &D, bool useHRZ)
Definition: dudley/src/Assemble_LumpedSystem.cpp:40
finley::Assemble_PDE_Points
void Assemble_PDE_Points(const AssembleParameters &p, const escript::Data &d_dirac, const escript::Data &y_dirac)
Definition: finley/src/Assemble_PDE_Points.cpp:74
dudley::DudleyException
Definition: DudleyException.h:39
dudley::AssembleParameters::DOF_UpperBound
dim_t DOF_UpperBound
number of local degrees of freedom
Definition: dudley/src/Assemble.h:93
FINLEY_REDUCED_FACE_ELEMENTS
#define FINLEY_REDUCED_FACE_ELEMENTS
Definition: Finley.h:75
escript::Data::requireWrite
void requireWrite()
Ensures data is ready for write access. This means that the data will be resolved if lazy and will be...
Definition: Data.cpp:1239
dudley::Assemble_getNormal
void Assemble_getNormal(const NodeFile *nodes, const ElementFile *elements, escript::Data &normals)
calculates the normal vector at quadrature points on face elements
Definition: dudley/src/Assemble_getNormal.cpp:40
INDEX4
#define INDEX4(_X1_, _X2_, _X3_, _X4_, _N1_, _N2_, _N3_)
Definition: index.h:27
paso::SystemMatrix
this class holds a (distributed) stiffness matrix
Definition: SystemMatrix.h:62
DUDLEY_DEGREES_OF_FREEDOM
#define DUDLEY_DEGREES_OF_FREEDOM
Definition: Dudley.h:55
finley::Assemble_integrate
void Assemble_integrate(const NodeFile *nodes, const ElementFile *elements, const escript::Data &data, Scalar *integrals)
integrates data on quadrature points
Definition: finley/src/Assemble_integrate.cpp:52
dudley::NodeFile
Definition: dudley/src/NodeFile.h:39
dudley::Nodes
@ Nodes
Definition: Dudley.h:67
paso::SystemMatrix::col_distribution
escript::Distribution_ptr col_distribution
Definition: SystemMatrix.h:335
MATRIX_FORMAT_CSC
#define MATRIX_FORMAT_CSC
Definition: Paso.h:63
FINLEY_REDUCED_ELEMENTS
#define FINLEY_REDUCED_ELEMENTS
Definition: Finley.h:74
dudley::Assemble_CopyElementData
void Assemble_CopyElementData(const ElementFile *elements, escript::Data &out, const escript::Data &in)
copies data between different types of elements
Definition: dudley/src/Assemble_CopyElementData.cpp:41
FINLEY_REDUCED_CONTACT_ELEMENTS_1
#define FINLEY_REDUCED_CONTACT_ELEMENTS_1
Definition: Finley.h:76
INDEX2
#define INDEX2(_X1_, _X2_, _N1_)
Definition: index.h:23
finley::ElementFile_Jacobians::numShapesTotal
int numShapesTotal
total number of shape functions = BasisFunctions->numShapes * numSides
Definition: finley/src/ElementFile.h:77
dudley::Assemble_addToSystemMatrix< cplx_t >
void Assemble_addToSystemMatrix< cplx_t >(escript::AbstractSystemMatrix *S, const std::vector< index_t > &Nodes, int numEq, const std::vector< cplx_t > &array)
Definition: dudley/src/Assemble_addToSystemMatrix.cpp:91
dudley::NodeFile::borrowTargetDegreesOfFreedom
const index_t * borrowTargetDegreesOfFreedom() const
returns the mapping from local degrees of freedom to a target
Definition: dudley/src/NodeFile.h:234
finley::setNumSamplesError
void setNumSamplesError(const char *c, int n0, int n1)
Definition: finley/src/Assemble_PDE.cpp:100
escript::Data::getSampleDataRO
const DataTypes::real_t * getSampleDataRO(DataTypes::RealVectorType::size_type sampleNo, DataTypes::real_t dummy=0) const
Return the sample data for the given sample no. Please do not use this unless you NEED to access samp...
Definition: Data.h:1989
dudley::AssembleParameters::numShapes
int numShapes
Definition: dudley/src/Assemble.h:96
finley::Assemble_AverageElementData
void Assemble_AverageElementData(const ElementFile *elements, escript::Data &out, const escript::Data &in)
averages data
Definition: finley/src/Assemble_AverageElementData.cpp:51
dudley::Assemble_interpolate
void Assemble_interpolate(const NodeFile *nodes, const ElementFile *elements, const escript::Data &data, escript::Data &output)
interpolates nodal data in a data array onto elements (=integration points)
Definition: dudley/src/Assemble_interpolate.cpp:41
paso::Coupler
Definition: Coupler.h:56
escript::Data::getDataPointShape
const DataTypes::ShapeType & getDataPointShape() const
Return a reference to the data point shape.
Definition: Data.h:705
escript::NotImplementedError
An exception class for features which are not (yet) implemented.
Definition: EsysException.h:93
finley::FinleyException
Definition: FinleyException.h:40
dudley::DTDV_3D
static const double DTDV_3D[4][3]
Definition: ShapeTable.h:57
FINLEY_NODES
#define FINLEY_NODES
Definition: Finley.h:66
finley::util::smallMatMult
void smallMatMult(int A1, int A2, double *A, int B2, const std::vector< double > &B, const std::vector< double > &C)
multiplies two matrices: A(1:A1,1:A2) := B(1:A1,1:B2)*C(1:B2,1:A2)
Definition: finley/src/Util.cpp:102
escript::Data::getNumberOfTaggedValues
size_t getNumberOfTaggedValues() const
For tagged Data returns the number of tags with values. For non-tagged data will return 0 (even Data ...
Definition: Data.cpp:5859
finley::ElementFile_Jacobians::node_selection
const int * node_selection
Definition: finley/src/ElementFile.h:80
finley::AssembleParameters::col_numShapes
int col_numShapes
Definition: finley/src/Assemble.h:110
finley::AssembleParameters::numElements
dim_t numElements
number of elements
Definition: finley/src/Assemble.h:95
dudley::Assemble_AverageElementData
void Assemble_AverageElementData(const ElementFile *elements, escript::Data &out, const escript::Data &in)
averages data
Definition: dudley/src/Assemble_AverageElementData.cpp:43
finley::Assemble_jacobians_2D_M1D_E1D
void Assemble_jacobians_2D_M1D_E1D(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:154
dudley::ElementFile_Jacobians::numQuad
int numQuad
number of quadrature nodes used to calculate jacobians
Definition: dudley/src/ElementFile.h:66
finley::AssembleParameters::col_jac
ElementFile_Jacobians * col_jac
Definition: finley/src/Assemble.h:107
finley::Assemble_jacobians_1D
void Assemble_jacobians_1D(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:64
finley::setShapeError
void setShapeError(const char *c, int num, const int *dims)
Definition: finley/src/Assemble_PDE.cpp:109
finley::const_ReferenceElement_ptr
boost::shared_ptr< const ReferenceElement > const_ReferenceElement_ptr
Definition: ReferenceElements.h:214
DUDLEY_NODES
#define DUDLEY_NODES
Definition: Dudley.h:56
dudley::Assemble_PDE_Single_3D
void Assemble_PDE_Single_3D(const AssembleParameters &p, const escript::Data &A, const escript::Data &B, const escript::Data &C, const escript::Data &D, const escript::Data &X, const escript::Data &Y)
Definition: dudley/src/Assemble_PDE_Single_3D.cpp:78
finley::AssembleParameters::row_DOF_UpperBound
index_t row_DOF_UpperBound
Definition: finley/src/Assemble.h:99
finley::AssembleParameters::row_numShapes
int row_numShapes
Definition: finley/src/Assemble.h:103
finley::Assemble_PDE_System_2D
void Assemble_PDE_System_2D(const AssembleParameters &p, const escript::Data &A, const escript::Data &B, const escript::Data &C, const escript::Data &D, const escript::Data &X, const escript::Data &Y)
Definition: finley/src/Assemble_PDE_System_2D.cpp:84
INDEX5
#define INDEX5(_X1_, _X2_, _X3_, _X4_, _X5_, _N1_, _N2_, _N3_, _N4_)
Definition: index.h:29
dudley::Assemble_NodeCoordinates
void Assemble_NodeCoordinates(const NodeFile *nodes, escript::Data &x)
copies node coordinates into expanded Data object x
Definition: dudley/src/Assemble_NodeCoordinates.cpp:41
escript::Data::getDataPointSize
int getDataPointSize() const
Return the size of the data point. It is the product of the data point shape dimensions.
Definition: Data.cpp:1360
Util.h
finley::Assemble_addToSystemMatrix< real_t >
void Assemble_addToSystemMatrix< real_t >(escript::ASM_ptr S, int NN_Equa, const index_t *Nodes_Equa, int num_Equa, int NN_Sol, const index_t *Nodes_Sol, int num_Sol, const real_t *array)
Definition: finley/src/Assemble_addToSystemMatrix.cpp:62
finley::Assemble_jacobians_3D_M2D_E2D_C
void Assemble_jacobians_3D_M2D_E2D_C(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:747
dudley::Assemble_addToSystemMatrix
void Assemble_addToSystemMatrix(escript::AbstractSystemMatrix *S, const std::vector< index_t > &Nodes, int numEq, const std::vector< Scalar > &array)
finley::Assemble_interpolate
void Assemble_interpolate(const NodeFile *nodes, const ElementFile *elements, const escript::Data &data, escript::Data &output)
interpolates nodal data in a data array onto elements (=integration points)
Definition: finley/src/Assemble_interpolate.cpp:53
finley::Points
@ Points
Definition: Finley.h:88
dudley::QuadNums
static const int QuadNums[4][2]
Definition: ShapeTable.h:89
escript::DataTypes::DataVectorAlt::data
ElementType * data()
Definition: DataVectorAlt.h:228
escript::Data::getFunctionSpace
const FunctionSpace & getFunctionSpace() const
Return the function space.
Definition: Data.h:463
FINLEY_REDUCED_DEGREES_OF_FREEDOM
#define FINLEY_REDUCED_DEGREES_OF_FREEDOM
Definition: Finley.h:72
finley::NodeFile::getNumReducedDegreesOfFreedom
dim_t getNumReducedDegreesOfFreedom() const
returns the number of reduced order degrees of freedom (on this rank)
Definition: finley/src/NodeFile.h:271
MATRIX_FORMAT_OFFSET1
#define MATRIX_FORMAT_OFFSET1
Definition: Paso.h:65
dudley::DTDV_2D
static const double DTDV_2D[3 *3][2]
Definition: ShapeTable.h:51
finley::Assemble_PDE_Single_2D
void Assemble_PDE_Single_2D(const AssembleParameters &p, const escript::Data &A, const escript::Data &B, const escript::Data &C, const escript::Data &D, const escript::Data &X, const escript::Data &Y)
Definition: finley/src/Assemble_PDE_Single_2D.cpp:78
dudley::AssembleParameters::elements
const ElementFile * elements
element file these parameters apply to
Definition: dudley/src/Assemble.h:77
finley::AssembleParameters::row_numShapesTotal
int row_numShapesTotal
Definition: finley/src/Assemble.h:102
finley::AssembleParameters::col_DOF
const index_t * col_DOF
Definition: finley/src/Assemble.h:105
finley::Assemble_jacobians_3D_M2D_E3D_C
void Assemble_jacobians_3D_M2D_E3D_C(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:547
paso::util::copy
void copy(dim_t N, double *out, const double *in)
out = in
Definition: PasoUtil.h:116
finley::AssembleParameters::col_DOF_UpperBound
index_t col_DOF_UpperBound
Definition: finley/src/Assemble.h:106
dudley::Assemble_PDE_System_3D
void Assemble_PDE_System_3D(const AssembleParameters &p, const escript::Data &A, const escript::Data &B, const escript::Data &C, const escript::Data &D, const escript::Data &X, const escript::Data &Y)
Definition: dudley/src/Assemble_PDE_System_3D.cpp:84
finley::ElementFile::numElements
dim_t numElements
number of elements
Definition: finley/src/ElementFile.h:136
dudley
A suite of factory methods for creating 2D and 3D dudley domains.
Definition: dudley/src/Assemble.h:32
finley::Assemble_jacobians_3D
void Assemble_jacobians_3D(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:390
dudley::getQuadShape
bool getQuadShape(dim_t dim, bool reduced, const double **shapearr)
Definition: ShapeTable.cpp:42
finley::ElementFile_Jacobians::numElements
dim_t numElements
number of elements
Definition: finley/src/ElementFile.h:82
dudley::Assemble_getSize
void Assemble_getSize(const NodeFile *nodes, const ElementFile *elements, escript::Data &size)
Definition: dudley/src/Assemble_getSize.cpp:39
escript::Data
Data represents a collection of datapoints.
Definition: Data.h:64
dudley::DTDV_1D
static const double DTDV_1D[2][2]
Definition: ShapeTable.h:48
dudley::Assemble_jacobians_2D
void Assemble_jacobians_2D(const double *coordinates, int numQuad, dim_t numElements, int numNodes, const index_t *nodes, double *dTdX, double *absD, double *quadWeight, const index_t *elementId)
Definition: dudley/src/Assemble_jacobians.cpp:56
finley::AssembleParameters::numSides
int numSides
number of sides
Definition: finley/src/Assemble.h:87
finley::Assemble_CopyElementData
void Assemble_CopyElementData(const ElementFile *elements, escript::Data &out, const escript::Data &in)
copies data between different types of elements
Definition: finley/src/Assemble_CopyElementData.cpp:49
INDEX3
#define INDEX3(_X1_, _X2_, _X3_, _N1_, _N2_)
Definition: index.h:25
escript::DataTypes::dim_t
index_t dim_t
Definition: DataTypes.h:93
finley::util::normalVector
void normalVector(int len, int dim, int dim1, const double *A, double *Normal)
Definition: finley/src/Util.cpp:215
escript::DataTypes::ShapeType
std::vector< int > ShapeType
The shape of a single datapoint.
Definition: DataTypes.h:71
dudley::ElementFile::numElements
dim_t numElements
number of elements
Definition: dudley/src/ElementFile.h:127
dudley::Assemble_jacobians_3D
void Assemble_jacobians_3D(const double *coordinates, int numQuad, dim_t numElements, int numNodes, const index_t *nodes, double *dTdX, double *abs_D, double *quadWeight, const index_t *elementId)
Definition: dudley/src/Assemble_jacobians.cpp:180
paso::SystemMatrix::type
SystemMatrixType type
Definition: SystemMatrix.h:324
FINLEY_FACE_ELEMENTS
#define FINLEY_FACE_ELEMENTS
Definition: Finley.h:68
finley::AssembleParameters::col_node
const int * col_node
Definition: finley/src/Assemble.h:108
escript::AbstractSystemMatrix
Base class for escript system matrices.
Definition: AbstractSystemMatrix.h:57
dudley::ElementFile
Definition: dudley/src/ElementFile.h:66
dudley::hasReducedIntegrationOrder
bool hasReducedIntegrationOrder(const escript::Data &in)
Definition: Dudley.h:75
escript::Data::getSampleDataRW
DataTypes::real_t * getSampleDataRW(DataTypes::RealVectorType::size_type sampleNo, DataTypes::real_t dummy=0)
Return the sample data for the given sample no. Please do not use this unless you NEED to access samp...
Definition: Data.h:1954
finley::AssembleParameters::numComp
int numComp
Definition: finley/src/Assemble.h:104
paso::SystemMatrix::mainBlock
SparseMatrix_ptr mainBlock
main block
Definition: SystemMatrix.h:342
paso::Coupler_ptr
boost::shared_ptr< Coupler< T > > Coupler_ptr
Definition: Coupler.h:57
dudley::AssembleParameters::NN
int NN
leading dimension of element node table
Definition: dudley/src/Assemble.h:87
finley::ElementFile_Jacobians::numQuadTotal
int numQuadTotal
Definition: finley/src/ElementFile.h:69
finley::Assemble_jacobians_3D_M2D_E3D
void Assemble_jacobians_3D_M2D_E3D(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:466
FINLEY_DEGREES_OF_FREEDOM
#define FINLEY_DEGREES_OF_FREEDOM
Definition: Finley.h:65
finley::util::hasReducedIntegrationOrder
bool hasReducedIntegrationOrder(const escript::Data &in)
returns true if the data object is defined on reduced element types
Definition: finley/src/Util.h:65
dudley::Assemble_PDE_System_2D
void Assemble_PDE_System_2D(const AssembleParameters &p, const escript::Data &A, const escript::Data &B, const escript::Data &C, const escript::Data &D, const escript::Data &X, const escript::Data &Y)
Definition: dudley/src/Assemble_PDE_System_2D.cpp:84
dudley::AssembleParameters::DOF
const index_t * DOF
row and column degrees of freedom
Definition: dudley/src/Assemble.h:91
finley::Assemble_addToSystemMatrix
void Assemble_addToSystemMatrix(escript::ASM_ptr S, int NN_Equa, const index_t *Nodes_Equa, int num_Equa, int NN_Sol, const index_t *Nodes_Sol, int num_Sol, const Scalar *array)
FINLEY_ELEMENTS
#define FINLEY_ELEMENTS
Definition: Finley.h:67
paso::SystemMatrix::row_coupleBlock
SparseMatrix_ptr row_coupleBlock
coupling to neighbouring processors (col - row)
Definition: SystemMatrix.h:346
escript::Data::isDataPointShapeEqual
bool isDataPointShapeEqual(int rank, const int *dimensions) const
Returns true if the shape matches the vector (dimensions[0],..., dimensions[rank-1])....
Definition: Data.h:567
finley::util::gather
void gather(int len, const index_t *index, int numData, const double *in, double *out)
Definition: finley/src/Util.cpp:72
DUDLEY_REDUCED_ELEMENTS
#define DUDLEY_REDUCED_ELEMENTS
Definition: Dudley.h:60
Assemble.h
dudley::ElementFile::numDim
int numDim
number of spatial dimensions of the domain
Definition: dudley/src/ElementFile.h:161
escript::Data::isEmpty
bool isEmpty() const
Definition: Data.cpp:1132
escript::Data::getNumDataPoints
int getNumDataPoints() const
Return the number of data points.
Definition: Data.h:523
dudley::Assemble_CopyNodalData
void Assemble_CopyNodalData(const NodeFile *nodes, escript::Data &out, const escript::Data &in)
copies data between different types of nodal representations
Definition: dudley/src/Assemble_CopyNodalData.cpp:41
finley::Assemble_addToSystemMatrix< cplx_t >
void Assemble_addToSystemMatrix< cplx_t >(escript::ASM_ptr S, int NN_Equa, const index_t *Nodes_Equa, int num_Equa, int NN_Sol, const index_t *Nodes_Sol, int num_Sol, const cplx_t *array)
Definition: finley/src/Assemble_addToSystemMatrix.cpp:98
paso::SystemMatrix::col_block_size
dim_t col_block_size
Definition: SystemMatrix.h:331
finley::AssembleParameters::numQuadTotal
int numQuadTotal
total number of quadrature nodes = numQuadSub * numQuadSub
Definition: finley/src/Assemble.h:83
escript::Data::numSamplesEqual
bool numSamplesEqual(int numDataPointsPerSample, int numSamples) const
Returns true if the number of data points per sample and the number of samples match the respective a...
Definition: Data.h:555
ShapeTable.h
DUDLEY_ELEMENTS
#define DUDLEY_ELEMENTS
Definition: Dudley.h:57
dudley::ElementFile_Jacobians::numDim
int numDim
number of spatial dimensions
Definition: dudley/src/ElementFile.h:64
finley::Assemble_jacobians_2D
void Assemble_jacobians_2D(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:101
dudley::Assemble_integrate< cplx_t >
template void Assemble_integrate< cplx_t >(const NodeFile *nodes, const ElementFile *elements, const escript::Data &data, std::vector< cplx_t > &out)
dudley::Assemble_jacobians_2D_M1D_E1D
void Assemble_jacobians_2D_M1D_E1D(const double *coordinates, int numQuad, dim_t numElements, int numNodes, const index_t *nodes, double *dTdX, double *absD, double *quadWeight, const index_t *elementId)
Definition: dudley/src/Assemble_jacobians.cpp:134
finley::Assemble_getSize
void Assemble_getSize(const NodeFile *nodes, const ElementFile *elements, escript::Data &size)
Definition: finley/src/Assemble_getSize.cpp:52
finley::Assemble_PDE_System_C
void Assemble_PDE_System_C(const AssembleParameters &p, const escript::Data &D, const escript::Data &Y)
Definition: Assemble_PDE_System_C.cpp:72
dudley::Assemble_integrate
void Assemble_integrate(const NodeFile *nodes, const ElementFile *elements, const escript::Data &data, std::vector< Scalar > &integrals)
integrates data on quadrature points
Definition: dudley/src/Assemble_integrate.cpp:43
finley::AssembleParameters::numSub
int numSub
number of sub-elements
Definition: finley/src/Assemble.h:89
dudley::Assemble_addToSystemMatrix< real_t >
void Assemble_addToSystemMatrix< real_t >(escript::AbstractSystemMatrix *S, const std::vector< index_t > &Nodes, int numEq, const std::vector< real_t > &array)
Definition: dudley/src/Assemble_addToSystemMatrix.cpp:62
paso::SystemMatrix::row_block_size
dim_t row_block_size
Definition: SystemMatrix.h:330
DUDLEY_REDUCED_FACE_ELEMENTS
#define DUDLEY_REDUCED_FACE_ELEMENTS
Definition: Dudley.h:61
dudley::AssembleParameters::AssembleParameters
AssembleParameters(const NodeFile *nodes, const ElementFile *ef, escript::ASM_ptr sm, escript::Data &rhs, bool reducedOrder)
Definition: dudley/src/Assemble_getAssembleParameters.cpp:35
paso::SystemMatrix::pattern
SystemMatrixPattern_ptr pattern
Definition: SystemMatrix.h:325
dudley::util::normalVector
void normalVector(int len, int dim, int dim1, const double *A, double *Normal)
Definition: dudley/src/Util.cpp:138
dudley::Assemble_PDE_Points
void Assemble_PDE_Points(const AssembleParameters &p, const escript::Data &d_dirac, const escript::Data &y_dirac)
Definition: dudley/src/Assemble_PDE_Points.cpp:77
finley::Assemble_gradient
void Assemble_gradient(const NodeFile *nodes, const ElementFile *elements, escript::Data &gradient, const escript::Data &data)
Definition: finley/src/Assemble_gradient.cpp:53
finley::AssembleParameters::elements
const ElementFile * elements
element file these parameters apply to
Definition: finley/src/Assemble.h:77
dudley::AssembleParameters::numDim
int numDim
number of spatial dimensions
Definition: dudley/src/Assemble.h:85
finley::AssembleParameters::row_jac
ElementFile_Jacobians * row_jac
Definition: finley/src/Assemble.h:100
finley::Assemble_LumpedSystem
void Assemble_LumpedSystem(const NodeFile *nodes, const ElementFile *elements, escript::Data &lumpedMat, const escript::Data &D, bool useHRZ)
Definition: finley/src/Assemble_LumpedSystem.cpp:58
escript::DataTypes::index_t
int index_t
type for array/matrix indices used both globally and on each rank
Definition: DataTypes.h:88
paso::SystemMatrix::logical_row_block_size
dim_t logical_row_block_size
Definition: SystemMatrix.h:327
dudley::AssembleParameters::numQuad
int numQuad
number of quadrature nodes
Definition: dudley/src/Assemble.h:83
finley::NodeFile
Definition: finley/src/NodeFile.h:41
dudley::util::smallMatMult
void smallMatMult(int A1, int A2, double *A, int B2, const double *B, const double *C)
multiplies two matrices: A(1:A1,1:A2) := B(1:A1,1:B2)*C(1:B2,1:A2)
Definition: dudley/src/Util.cpp:102
finley::ElementFile::borrowJacobians
ElementFile_Jacobians * borrowJacobians(const NodeFile *, bool, bool) const
Definition: finley/src/ElementFile_jacobians.cpp:55
finley::Assemble_PDE_System_3D
void Assemble_PDE_System_3D(const AssembleParameters &p, const escript::Data &A, const escript::Data &B, const escript::Data &C, const escript::Data &D, const escript::Data &X, const escript::Data &Y)
Definition: finley/src/Assemble_PDE_System_3D.cpp:84
COMPDXDV1
#define COMPDXDV1(P)
finley::Assemble_jacobians_2D_M1D_E2D
void Assemble_jacobians_2D_M1D_E2D(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:260
Util.h
finley::Assemble_PDE
void Assemble_PDE(const NodeFile *nodes, const ElementFile *elements, escript::ASM_ptr S, escript::Data &F, const escript::Data &A, const escript::Data &B, const escript::Data &C, const escript::Data &D, const escript::Data &X, const escript::Data &Y)
Definition: finley/src/Assemble_PDE.cpp:128
finley::ElementFile_Jacobians::numSides
int numSides
number of sides (=1 normal, =2 contact)
Definition: finley/src/ElementFile.h:71
FINLEY_REDUCED_CONTACT_ELEMENTS_2
#define FINLEY_REDUCED_CONTACT_ELEMENTS_2
Definition: Finley.h:77
finley::AssembleParameters::row_node
const int * row_node
Definition: finley/src/Assemble.h:101
dudley::ElementFile_Jacobians::numElements
dim_t numElements
number of elements
Definition: dudley/src/ElementFile.h:70
finley::AssembleParameters::AssembleParameters
AssembleParameters(const NodeFile *nodes, const ElementFile *ef, escript::ASM_ptr sm, escript::Data &rhs, bool reducedOrder)
Definition: finley/src/Assemble_getAssembleParameters.cpp:34
escript::FunctionSpace::getTypeCode
int getTypeCode() const
Returns the function space type code.
Definition: FunctionSpace.cpp:95
COMPDXDV0
#define COMPDXDV0(P)
escript::Data::isLazy
bool isLazy() const
Return true if this Data is lazy.
Definition: Data.cpp:1146
dudley::AssembleParameters::jac
const ElementFile_Jacobians * jac
reference to jacobians
Definition: dudley/src/Assemble.h:95
DIM
#define DIM
dudley::Assemble_integrate< real_t >
template void Assemble_integrate< real_t >(const NodeFile *nodes, const ElementFile *elements, const escript::Data &data, std::vector< real_t > &out)
finley::ElementFile
Definition: finley/src/ElementFile.h:76
finley::Assemble_jacobians_2D_M1D_E1D_C
void Assemble_jacobians_2D_M1D_E1D_C(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:200
finley::ElementFile_Jacobians::numDim
int numDim
number of spatial dimensions
Definition: finley/src/ElementFile.h:64
finley::AssembleParameters::row_DOF
const index_t * row_DOF
Definition: finley/src/Assemble.h:98
dudley::Assemble_gradient
void Assemble_gradient(const NodeFile *nodes, const ElementFile *elements, escript::Data &gradient, const escript::Data &data)
Definition: dudley/src/Assemble_gradient.cpp:43
FINLEY_REDUCED_NODES
#define FINLEY_REDUCED_NODES
Definition: Finley.h:73
finley::Assemble_getNormal
void Assemble_getNormal(const NodeFile *nodes, const ElementFile *elements, escript::Data &normals)
calculates the normal vector at quadrature points on face elements
Definition: finley/src/Assemble_getNormal.cpp:52
finley::NodeFile::borrowTargetDegreesOfFreedom
const index_t * borrowTargetDegreesOfFreedom() const
Definition: finley/src/NodeFile.h:316
finley::NodeFile::getNumDegreesOfFreedom
dim_t getNumDegreesOfFreedom() const
returns the number of degrees of freedom (on this rank)
Definition: finley/src/NodeFile.h:266
finley::const_ShapeFunction_ptr
boost::shared_ptr< const ShapeFunction > const_ShapeFunction_ptr
Definition: ShapeFunctions.h:100
escript::Data::actsExpanded
bool actsExpanded() const
Return true if this Data is expanded or resolves to expanded. That is, if it has a separate value for...
Definition: Data.cpp:1118
finley::ElementFile_Jacobians::BasisFunctions
const_ShapeFunction_ptr BasisFunctions
basis function used
Definition: finley/src/ElementFile.h:66
finley::Assemble_PDE_Single_C
void Assemble_PDE_Single_C(const AssembleParameters &p, const escript::Data &D, const escript::Data &Y)
Definition: Assemble_PDE_Single_C.cpp:70
dudley::Assemble_PDE
void Assemble_PDE(const NodeFile *nodes, const ElementFile *elements, escript::ASM_ptr S, escript::Data &F, const escript::Data &A, const escript::Data &B, const escript::Data &C, const escript::Data &D, const escript::Data &X, const escript::Data &Y)
Definition: dudley/src/Assemble_PDE.cpp:126
escript::getMPIRankWorld
int getMPIRankWorld()
returns the MPI processor number within MPI_COMM_WORLD
Definition: Utils.cpp:103
finley::NodeFile::borrowTargetReducedDegreesOfFreedom
const index_t * borrowTargetReducedDegreesOfFreedom() const
Definition: finley/src/NodeFile.h:321
dudley::util::gather
void gather(int len, const index_t *index, int numData, const double *in, double *out)
Definition: dudley/src/Util.cpp:72
DUDLEY_POINTS
#define DUDLEY_POINTS
Definition: Dudley.h:59
S
#define S(_J_, _I_)
Definition: ShapeFunctions.cpp:140
finley::Assemble_jacobians_2D_M1D_E2D_C
void Assemble_jacobians_2D_M1D_E2D_C(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:314
escript::Data::getExpandedVectorReference
DataTypes::RealVectorType & getExpandedVectorReference(DataTypes::real_t dummy=0)
Ensures that the Data is expanded and returns its underlying vector Does not check for exclusive writ...
Definition: Data.cpp:5841
escript::ASM_ptr
boost::shared_ptr< AbstractSystemMatrix > ASM_ptr
Definition: AbstractSystemMatrix.h:47
paso::SystemMatrix::block_size
dim_t block_size
Definition: SystemMatrix.h:332
finley::AssembleParameters::numQuadSub
int numQuadSub
number of quadrature nodes per subelements
Definition: finley/src/Assemble.h:85
escript::DataTypes::cplx_t
std::complex< real_t > cplx_t
complex data type
Definition: DataTypes.h:82
finley::Assemble_CopyNodalData
void Assemble_CopyNodalData(const NodeFile *nodes, escript::Data &out, const escript::Data &in)
copies data between different types of nodal representations
Definition: finley/src/Assemble_CopyNodalData.cpp:41
dudley::AssembleParameters::shapeFns
const double * shapeFns
Definition: dudley/src/Assemble.h:97
escript::Scalar
Data Scalar(double value, const FunctionSpace &what, bool expanded)
A collection of factory functions for creating Data objects which contain data points of various shap...
Definition: DataFactory.cpp:63
finley::ElementFile_Jacobians::numSub
int numSub
number of subelements
Definition: finley/src/ElementFile.h:75
finley::AssembleParameters::numEqu
int numEqu
Definition: finley/src/Assemble.h:97
finley
A suite of factory methods for creating various finley domains.
Definition: finley/src/Assemble.h:32
dudley::NodeFile::getNumDegreesOfFreedom
dim_t getNumDegreesOfFreedom() const
returns the number of degrees of freedom (on this rank)
Definition: dudley/src/NodeFile.h:209
dudley::setNumSamplesError
void setNumSamplesError(const char *c, int n0, int n1)
Definition: dudley/src/Assemble_PDE.cpp:98
escript::ValueError
An exception class that signals an invalid argument value.
Definition: EsysException.h:103
DUDLEY_FACE_ELEMENTS
#define DUDLEY_FACE_ELEMENTS
Definition: Dudley.h:58
finley::Assemble_PDE_System_1D
void Assemble_PDE_System_1D(const AssembleParameters &p, const escript::Data &A, const escript::Data &B, const escript::Data &C, const escript::Data &D, const escript::Data &X, const escript::Data &Y)
Definition: Assemble_PDE_System_1D.cpp:84
dudley::Assemble_PDE_Single_2D
void Assemble_PDE_Single_2D(const AssembleParameters &p, const escript::Data &A, const escript::Data &B, const escript::Data &C, const escript::Data &D, const escript::Data &X, const escript::Data &Y)
Definition: dudley/src/Assemble_PDE_Single_2D.cpp:78
FINLEY_CONTACT_ELEMENTS_2
#define FINLEY_CONTACT_ELEMENTS_2
Definition: Finley.h:71
Assemble.h
dudley::util::addScatter
void addScatter(int len, const index_t *index, int numData, const Scalar *in, Scalar *out, index_t upperBound)
Definition: dudley/src/Util.cpp:83
dudley::ElementFile::numNodes
int numNodes
number of nodes per element
Definition: dudley/src/ElementFile.h:144
finley::AssembleParameters::col_numShapesTotal
int col_numShapesTotal
Definition: finley/src/Assemble.h:109
finley::Assemble_PDE_Single_3D
void Assemble_PDE_Single_3D(const AssembleParameters &p, const escript::Data &A, const escript::Data &B, const escript::Data &C, const escript::Data &D, const escript::Data &X, const escript::Data &Y)
Definition: finley/src/Assemble_PDE_Single_3D.cpp:78
FINLEY_CONTACT_ELEMENTS_1
#define FINLEY_CONTACT_ELEMENTS_1
Definition: Finley.h:70
paso::SystemMatrix::row_distribution
escript::Distribution_ptr row_distribution
Definition: SystemMatrix.h:334
escript::DataTypes::IndexVector
std::vector< index_t > IndexVector
Definition: DataTypes.h:91
dudley::setShapeError
void setShapeError(const char *c, int num, const int *dims)
Definition: dudley/src/Assemble_PDE.cpp:107
dudley::ElementFile::borrowJacobians
ElementFile_Jacobians * borrowJacobians(const NodeFile *nodes, bool reducedOrder) const
Definition: dudley/src/ElementFile_jacobians.cpp:55
INDEX6
#define INDEX6(_X1_, _X2_, _X3_, _X4_, _X5_, _X6_, _N1_, _N2_, _N3_, _N4_, _N5_)
Definition: index.h:31
dudley::AssembleParameters::numEqu
int numEqu
number of equations (= matrix row/column block size)
Definition: dudley/src/Assemble.h:89
finley::ElementFile::numNodes
int numNodes
number of nodes per element
Definition: finley/src/ElementFile.h:152
finley::Assemble_PDE_Single_1D
void Assemble_PDE_Single_1D(const AssembleParameters &p, const escript::Data &A, const escript::Data &B, const escript::Data &C, const escript::Data &D, const escript::Data &X, const escript::Data &Y)
Definition: Assemble_PDE_Single_1D.cpp:78
paso::SystemMatrix::col_coupleBlock
SparseMatrix_ptr col_coupleBlock
coupling to neighbouring processors (row - col)
Definition: SystemMatrix.h:344