Commit 1502ab78 authored by David Moxey's avatar David Moxey

Fixed MultiRegions demos

parent 26551aac
ADD_NEKTAR_EXECUTABLE(PartitionAnalyse
COMPONENT demos DEPENDS LibUtilities SOURCES PartitionAnalyse.cpp)
#ADD_NEKTAR_EXECUTABLE(PartitionAnalyse
# COMPONENT demos DEPENDS LibUtilities SOURCES PartitionAnalyse.cpp)
ADD_NEKTAR_EXECUTABLE(FoundationDemo
COMPONENT demos DEPENDS LibUtilities SOURCES FoundationDemo.cpp)
ADD_NEKTAR_EXECUTABLE(NodalDemo
......
......@@ -5,8 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/ContField3DHomogeneous1D.h>
#include <SpatialDomains/MeshGraph1D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -30,7 +29,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph2D = MemoryManager<SpatialDomains::MeshGraph2D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph2D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/ContField3DHomogeneous1D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -29,7 +29,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph2D = MemoryManager<SpatialDomains::MeshGraph2D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph2D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -5,8 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/ContField3DHomogeneous2D.h>
#include <SpatialDomains/MeshGraph1D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -30,7 +29,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph1D = MemoryManager<SpatialDomains::MeshGraph1D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph1D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
#include <MultiRegions/ExpList1D.h>
#include <LibUtilities/Kernel/kernel.h>
#include <SpatialDomains/MeshGraph1D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -18,7 +18,7 @@ int main(int argc, char *argv[])
}
/************************* Mesh File ***********************/
// Read the mesh
SpatialDomains::MeshGraphSharedPtr graph1D = MemoryManager<SpatialDomains::MeshGraph1D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph1D = SpatialDomains::MeshGraph::Read(vSession);
/***********************************************************/
......
......@@ -4,7 +4,7 @@
#include <LibUtilities/Memory/NekMemoryManager.hpp>
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <MultiRegions/ContField1D.h>
#include <SpatialDomains/MeshGraph1D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -35,7 +35,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// read the problem parameters from input file
SpatialDomains::MeshGraphSharedPtr graph1D = MemoryManager<SpatialDomains::MeshGraph1D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph1D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -4,7 +4,7 @@
#include <LibUtilities/Memory/NekMemoryManager.hpp>
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <MultiRegions/ContField2D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -30,7 +30,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph2D = MemoryManager<SpatialDomains::MeshGraph2D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph2D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <MultiRegions/MultiRegions.hpp>
#include <MultiRegions/ContField3D.h>
#include <SpatialDomains/MeshGraph3D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -31,7 +31,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph3D = MemoryManager<SpatialDomains::MeshGraph3D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph3D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -6,7 +6,7 @@
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/MultiRegions.hpp>
#include <MultiRegions/ContField3D.h>
#include <SpatialDomains/MeshGraph3D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -32,7 +32,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph3D = MemoryManager<SpatialDomains::MeshGraph3D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph3D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -2,7 +2,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/ExpList1D.h>
#include <SpatialDomains/MeshGraph1D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -25,7 +25,7 @@ int main(int argc, char *argv[])
Array<OneD, NekDouble> xc0,xc1,xc2;
// read in mesh
SpatialDomains::MeshGraphSharedPtr graph1D = MemoryManager<SpatialDomains::MeshGraph1D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph1D = SpatialDomains::MeshGraph::Read(vSession);
// Define Expansion
const SpatialDomains::ExpansionMap &expansions = graph1D->GetExpansions();
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/ExpList2D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -31,7 +31,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph2D = MemoryManager<SpatialDomains::MeshGraph2D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph2D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/ExpList3D.h>
#include <SpatialDomains/MeshGraph3D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -31,7 +31,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph3D = MemoryManager<SpatialDomains::MeshGraph3D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph3D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -4,7 +4,7 @@
#include <LibUtilities/Memory/NekMemoryManager.hpp>
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <MultiRegions/ContField2D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -41,7 +41,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph2D = MemoryManager<SpatialDomains::MeshGraph2D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph2D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/DisContField1D.h>
#include <SpatialDomains/MeshGraph1D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -33,7 +33,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph1D = MemoryManager<SpatialDomains::MeshGraph1D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph1D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/DisContField2D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <SpatialDomains/MeshGraph.h>
//#define TIMING
#ifdef TIMING
......@@ -45,7 +45,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph2D = MemoryManager<SpatialDomains::MeshGraph2D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph2D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/DisContField3D.h>
#include <SpatialDomains/MeshGraph3D.h>
#include <SpatialDomains/MeshGraph.h>
//#define TIMING
#ifdef TIMING
......@@ -45,7 +45,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph3D =
MemoryManager<SpatialDomains::MeshGraph3D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -6,7 +6,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/DisContField3DHomogeneous1D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <SpatialDomains/MeshGraph.h>
//#define TIMING
#ifdef TIMING
......@@ -48,7 +48,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph2D = MemoryManager<SpatialDomains::MeshGraph2D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph2D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/ContField1D.h>
#include <SpatialDomains/MeshGraph1D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/ContField2D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......
......@@ -40,7 +40,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/ContField3D.h>
#include <SpatialDomains/MeshGraph3D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/ContField3DHomogeneous1D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -38,7 +38,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph2D = MemoryManager<SpatialDomains::MeshGraph2D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph2D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/ContField3DHomogeneous2D.h>
#include <SpatialDomains/MeshGraph1D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -34,7 +34,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph1D = MemoryManager<SpatialDomains::MeshGraph1D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph1D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/DisContField2D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <SpatialDomains/MeshGraph.h>
//#define TIMING
#ifdef TIMING
......@@ -43,7 +43,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph2D = MemoryManager<SpatialDomains::MeshGraph2D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph2D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -5,7 +5,7 @@
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <LibUtilities/Communication/Comm.h>
#include <MultiRegions/DisContField3D.h>
#include <SpatialDomains/MeshGraph3D.h>
#include <SpatialDomains/MeshGraph.h>
//#define TIMING
#ifdef TIMING
......@@ -42,7 +42,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph3D = MemoryManager<SpatialDomains::MeshGraph3D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph3D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -4,7 +4,7 @@
#include <LibUtilities/Memory/NekMemoryManager.hpp>
#include <LibUtilities/BasicUtils/SessionReader.h>
#include <MultiRegions/ContField2D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
using namespace Nektar;
......@@ -41,7 +41,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph2D = MemoryManager<SpatialDomains::MeshGraph2D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph2D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -43,7 +43,7 @@ int main(int argc, char *argv[])
//----------------------------------------------
// Read in mesh from input file
SpatialDomains::MeshGraphSharedPtr graph2D = MemoryManager<SpatialDomains::MeshGraph2D>::AllocateSharedPtr(vSession);
SpatialDomains::MeshGraphSharedPtr graph2D = SpatialDomains::MeshGraph::Read(vSession);
//----------------------------------------------
//----------------------------------------------
......
......@@ -291,7 +291,7 @@ namespace Nektar
delete m_xmlDoc;
}
m_xmlDoc = MergeDoc(filenames);
m_xmlDoc = MergeDoc(m_filenames);
// Parse the XML data in #m_xmlDoc
ParseDocument();
......
......@@ -611,7 +611,7 @@ namespace Nektar
LocalRegions::SegExpSharedPtr locSegExp =
m_elmtToTrace[eid][j]->as<LocalRegions::SegExp>();
id = locSegExp->GetGeom1D()->GetEid();
id = locSegExp->GetGeom()->GetGlobalID();
order_e = locExpansion->GetEdgeNcoeffs(j);
map<int,int> orientMap;
......@@ -656,7 +656,7 @@ namespace Nektar
m_elmtToTrace[eid][j]
->as<LocalRegions::Expansion2D>();
id = locFaceExp->GetGeom2D()->GetFid();
id = locFaceExp->GetGeom()->GetGlobalID();
order_e = locExpansion->GetFaceNcoeffs(j);
map<int,int> orientMap;
......
......@@ -323,7 +323,7 @@ void LocTraceToTraceMap::Setup2D(
nedgepts = exp2d->GetEdgeNumPoints(e);
nedgepts1 = edge->GetTotPoints();
StdRegions::Orientation orient = exp2d->GetCartesianEorient(e);
StdRegions::Orientation orient = exp2d->GetEorient(e);
// Account for eBackwards orientation
exp2d->ReOrientEdgePhysMap(elmtToTrace[n][e]->GetNverts(),
......
......@@ -37,7 +37,7 @@
#include <MultiRegions/DisContField1D.h>
#include <StdRegions/StdSegExp.h>
#include <LibUtilities/Foundations/ManagerAccess.h>
#include <SpatialDomains/MeshGraph1D.h>
#include <SpatialDomains/MeshGraph.h>
using namespace std;
......@@ -132,10 +132,6 @@ namespace Nektar
{
return;
}
SpatialDomains::MeshGraph1DSharedPtr graph1D =
std::dynamic_pointer_cast<SpatialDomains::MeshGraph1D>(
m_graph);
m_globalBndMat = MemoryManager<GlobalLinSysMap>::AllocateSharedPtr();
......@@ -143,13 +139,13 @@ namespace Nektar
AllocateSharedPtr(
m_bndCondExpansions,
m_bndConditions,
*m_exp,graph1D,
*m_exp,m_graph,
m_periodicVerts);
m_trace = std::dynamic_pointer_cast<ExpList>(trace);
m_traceMap = MemoryManager<AssemblyMapDG>::
AllocateSharedPtr(m_session, graph1D, trace, *this,
AllocateSharedPtr(m_session, m_graph, trace, *this,
m_bndCondExpansions, m_bndConditions,
m_periodicVerts, variable);
......@@ -381,7 +377,7 @@ namespace Nektar
{
// can assume that all regions only contain one point in 1D
// Really do not need loop above
int id = (*(bregionIt.second))[0]->GetGlobalID();
int id = bregionIt.second->m_geomVec[0]->GetGlobalID();
GeometryToRegionsMap[id] = it.first;
}
}
......@@ -391,15 +387,15 @@ namespace Nektar
// Now find out which points in domain have only one vertex
for(auto &domIt : domain)
{
SpatialDomains::Composite geomvector = domIt.second;
for(int i = 0; i < geomvector->size(); ++i)
SpatialDomains::CompositeSharedPtr geomvector = domIt.second;
for(int i = 0; i < geomvector->m_geomVec.size(); ++i)
{
for(int j = 0; j < 2; ++j)
{
int vid = (*geomvector)[i]->GetVid(j);
int vid = geomvector->m_geomVec[i]->GetVid(j);
if(EndOfDomain.count(vid) == 0)
{
EndOfDomain[vid] = (*geomvector)[i]->GetVertex(j);
EndOfDomain[vid] = geomvector->m_geomVec[i]->GetVertex(j);
}
else
{
......@@ -442,8 +438,10 @@ namespace Nektar
SpatialDomains::BoundaryRegionShPtr breg(MemoryManager<SpatialDomains::BoundaryRegion>::AllocateSharedPtr());
// Set up Composite (GemetryVector) to contain vertex and put into bRegion
SpatialDomains::Composite gvec(MemoryManager<SpatialDomains::GeometryVector>::AllocateSharedPtr());
gvec->push_back(regIt.second);
SpatialDomains::CompositeSharedPtr gvec =
MemoryManager<SpatialDomains::Composite>
::AllocateSharedPtr();
gvec->m_geomVec.push_back(regIt.second);
(*breg)[regIt.first] = gvec;
returnval->AddBoundaryRegions(bregions.size()+numNewBc,breg);
......@@ -486,7 +484,7 @@ namespace Nektar
{
SpatialDomains::BoundaryConditionsSharedPtr DomBCs = GetDomainBCs(domain,Allbcs,variable);
GenerateBoundaryConditionExpansion(graph1D,*DomBCs,variable);
GenerateBoundaryConditionExpansion(m_graph,*DomBCs,variable);
EvaluateBoundaryConditions(0.0, variable);
ApplyGeomInfo();
FindPeriodicVertices(*DomBCs,variable);
......@@ -563,7 +561,7 @@ namespace Nektar
{
for (auto &bregionIt : *it.second)
{
cnt += bregionIt.second->size();
cnt += bregionIt.second->m_geomVec.size();
}
}
}
......@@ -597,9 +595,6 @@ namespace Nektar
const SpatialDomains::BoundaryConditionCollection &bconditions
= bcs.GetBoundaryConditions();
SpatialDomains::MeshGraph1DSharedPtr graph1D
= std::dynamic_pointer_cast<
SpatialDomains::MeshGraph1D>(m_graph);
LibUtilities::CommSharedPtr vComm =
m_session->GetComm()->GetRowComm();
......@@ -620,8 +615,7 @@ namespace Nektar
{
continue;
}
int id = (*(it.second->begin()->second))[0]->GetGlobalID();
int id = it.second->begin()->second->m_geomVec[0]->GetGlobalID();
BregionToVertMap[it.first] = id;
}
......@@ -738,11 +732,11 @@ namespace Nektar
{
for (auto &bregionIt : *it.second)
{
for (k = 0; k < bregionIt.second->size(); k++)
for (k = 0; k < bregionIt.second->m_geomVec.size(); k++)
{
if((vert = std::dynamic_pointer_cast
<SpatialDomains::PointGeom>(
(*bregionIt.second)[k])))
bregionIt.second->m_geomVec[k])))
{
locPointExp
= MemoryManager<MultiRegions::ExpList0D>
......
This diff is collapsed.
This diff is collapsed.
......@@ -39,7 +39,6 @@
#include <LocalRegions/SegExp.h>
#include <LocalRegions/QuadExp.h>
#include <LocalRegions/Expansion2D.h>
#include <SpatialDomains/MeshGraph2D.h>
#include <LibUtilities/Foundations/ManagerAccess.h> // for PointsManager, etc
#include <LibUtilities/Foundations/Interp.h>
......@@ -303,14 +302,12 @@ namespace Nektar
// Process each composite region in domain
for(auto &compIt : domain)
{
comp = compIt.second;
// Process each expansion in the graph
for(j = 0; j < compIt.second->size(); ++j)
for(j = 0; j < compIt.second->m_geomVec.size(); ++j)
{
if((SegmentGeom = std::dynamic_pointer_cast<
SpatialDomains::SegGeom>(
(*compIt.second)[j])))
compIt.second->m_geomVec[j])))
{
// Retrieve basis key from expansion and define expansion
auto expIt = expansions.find(SegmentGeom->GetGlobalID());
......@@ -403,19 +400,16 @@ namespace Nektar
// Process each composite region.
for(auto &compIt : domain)
{
comp = compIt.second;
// Process each expansion in the region.
for(j = 0; j < compIt.second->size(); ++j)
for(j = 0; j < compIt.second->m_geomVec.size(); ++j)
{
if((SegmentGeom = std::dynamic_pointer_cast<
SpatialDomains::SegGeom>(
(*compIt.second)[j])))
compIt.second->m_geomVec[j])))
{
// Retrieve the basis key from the expansion.
LibUtilities::BasisKey bkey = std::dynamic_pointer_cast<
SpatialDomains::MeshGraph2D>(graph2D)
->GetEdgeBasisKey(SegmentGeom, variable);
LibUtilities::BasisKey bkey = graph2D->GetEdgeBasisKey(
SegmentGeom, variable);
seg = MemoryManager<LocalRegions::SegExp>
::AllocateSharedPtr(bkey, SegmentGeom);
......@@ -512,7 +506,7 @@ namespace Nektar
seg = MemoryManager<LocalRegions::SegExp>
::AllocateSharedPtr(bkey, segGeom);
edgesDone.insert(segGeom->GetEid());
edgesDone.insert(segGeom->GetGlobalID());
seg->SetElmtId(elmtid++);
(*m_exp).push_back(seg);
......@@ -530,7 +524,7 @@ namespace Nektar
for(j = 0; j < locexp[i]->GetNedges(); ++j)
{
segGeom = exp2D->GetGeom2D()->GetEdge(j);
id = segGeom->GetEid();
id = segGeom->GetGlobalID();
// Ignore Dirichlet edges
if (edgesDone.count(id) != 0)
{
......
......@@ -41,7 +41,6 @@
#include <MultiRegions/ExpList2D.h>
#include <LibUtilities/Foundations/Interp.h>
#include <LibUtilities/Foundations/PhysGalerkinProject.h>
#include <SpatialDomains/MeshGraph3D.h>
using namespace std;
......@@ -535,7 +534,7 @@ namespace Nektar
{
FaceQuadExp = MemoryManager<LocalRegions::QuadExp>
::AllocateSharedPtr(bkey0, bkey1, FaceQuadGeom);
facesDone.insert(FaceQuadGeom->GetFid());
facesDone.insert(FaceQuadGeom->GetGlobalID());
FaceQuadExp->SetElmtId(elmtid++);
(*m_exp).push_back(FaceQuadExp);
}
......@@ -545,7 +544,7 @@ namespace Nektar
{
FaceTriExp = MemoryManager<LocalRegions::TriExp>
::AllocateSharedPtr(bkey0, bkey1, FaceTriGeom);
facesDone.insert(FaceTriGeom->GetFid());
facesDone.insert(FaceTriGeom->GetGlobalID());
FaceTriExp->SetElmtId(elmtid++);
(*m_exp).push_back(FaceTriExp);
}
......@@ -567,7 +566,7 @@ namespace Nektar
for (j = 0; j < exp3D->GetNfaces(); ++j)
{
FaceGeom = exp3D->GetGeom3D()->GetFace(j);
id = FaceGeom->GetFid();