42 namespace MultiRegions
49 ExpList0D::ExpList0D():
59 ExpList(In,DeclareCoeffPhysArrays)
76 (*m_exp).push_back(Point);
104 const bool DeclareCoeffPhysArrays)
109 int i, j, id, elmtid=0;
110 map<int,int> EdgeDone;
111 map<int,int> NormalSet;
118 for(i = 0; i < bndCond.num_elements(); ++i)
122 for(j = 0; j < bndConstraint[i]->GetExpSize(); ++j)
124 PointGeom = bndConstraint[i]->GetExp(0)->GetGeom()->GetVertex(0);
127 EdgeDone[PointGeom->GetVid()] = elmtid;
129 Point->SetElmtId(elmtid++);
130 (*m_exp).push_back(Point);
136 for(i = 0; i < locexp.size(); ++i)
138 for(j = 0; j < 2; ++j)
141 PointGeom = (exp->GetGeom1D())->GetVertex(j);
142 id = PointGeom->GetVid();
144 if(EdgeDone.count(
id)==0)
147 EdgeDone[id] = elmtid;
154 Point->SetElmtId(elmtid++);
155 (*m_exp).push_back(Point);
194 if(DeclareCoeffPhysArrays)
217 int i,j,k,e_npoints,offset;
221 int coordim = (*m_exp)[0]->GetGeom()->GetCoordim();
223 ASSERTL1(normals.num_elements() >= coordim,
224 "Output vector does not have sufficient dimensions to "
228 for(i = 0; i <
m_exp->size(); ++i)
236 locnormals = loc_elmt->GetVertexNormal(loc_exp->GetLeftAdjacentElementVertex());
242 for(j = 0; j < e_npoints; ++j)
246 for(k = 0; k < coordim; ++k)
248 normals[k][offset] = locnormals[k][0];
269 for(
int j = 0; j < Fwd.num_elements(); ++j)
virtual void v_Upwind(const Array< OneD, const NekDouble > &Vn, const Array< OneD, const NekDouble > &Fwd, const Array< OneD, const NekDouble > &Bwd, Array< OneD, NekDouble > &Upwind)
virtual void v_GetNormals(Array< OneD, Array< OneD, NekDouble > > &normals)
static boost::shared_ptr< DataType > AllocateSharedPtr()
Allocate a shared pointer from the memory pool.
NekOptimize::GlobalOptParamSharedPtr m_globalOptParam
Expansion1DSharedPtr GetLeftAdjacentElementExp() const
Array< OneD, NekDouble > m_phys
The global expansion evaluated at the quadrature points.
Array< OneD, NekDouble > m_coeffs
Concatenation of all local expansion coefficients.
int GetExpSize(void)
This function returns the number of elements in the expansion.
boost::shared_ptr< Expansion0D > Expansion0DSharedPtr
std::vector< ExpansionSharedPtr > ExpansionVector
Base class for all multi-elemental spectral/hp expansions.
boost::shared_ptr< LocalRegions::ExpansionVector > m_exp
The list of local expansions.
Array< OneD, int > m_phys_offset
Offset of elemental data into the array m_phys.
int m_ncoeffs
The total number of local degrees of freedom. m_ncoeffs .
void SetCoeffPhysOffsets()
Definition of the total number of degrees of freedom and quadrature points and offsets to access data...
boost::shared_ptr< PointExp > PointExpSharedPtr
std::map< int, std::vector< PeriodicEntity > > PeriodicMap
ExpList0D()
The defualt constructor.
This class is the abstraction of a collection of zero-dimensional expansions which is merely a collec...
virtual ~ExpList0D()
Destructor.
void SetExpType(ExpansionType Type)
Returns the type of the expansion.
#define ASSERTL1(condition, msg)
Assert Level 1 – Debugging which is used whether in FULLDEBUG or DEBUG compilation mode...
boost::shared_ptr< MeshGraph > MeshGraphSharedPtr
boost::shared_ptr< Expansion1D > Expansion1DSharedPtr
boost::shared_ptr< PointGeom > PointGeomSharedPtr