Skip to content

Commit d86ea08

Browse files
committed
assert spherical
1 parent 9b7bcd2 commit d86ea08

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/pmpo_MPMesh.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ namespace polyMPO{
88
void printVTP_mesh(MPMesh& mpMesh, int printVTPIndex=-1);
99

1010
void MPMesh::calcBasis() {
11+
assert(p_mesh->getGeomType() == geom_spherical_surf);
1112
auto MPsPosition = p_MPs->getPositions();
1213
auto mp_basis_field = p_MPs->getData<MPF_Basis_Vals>(); // we can implement MPs->getBasisVals() like MPs->getPositions()
1314
auto elm2VtxConn = p_mesh->getElm2VtxConn();

src/pmpo_createTestMPMesh.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ MaterialPoints* initTestMPs(Mesh* mesh, int testMPOption){
149149
default:
150150
fprintf(stderr,"TestMPOption not avaiable! return an empty one!");
151151
}
152-
auto vtxCoords = mesh->getMeshField<polyMPO::MeshF_VtxCoords>();
152+
auto vtxCoords = mesh->getMeshField<MeshF_VtxCoords>();
153153
auto elm2VtxConn = mesh->getElm2VtxConn();
154154
auto geomType = mesh->getGeomType();
155155

@@ -245,8 +245,8 @@ Mesh* replicateMesh(Mesh* mesh, int replicateFactor){
245245
const int nCells = nCells_size*replicateFactor;
246246
const int nVertices = nVertices_size*replicateFactor;
247247

248-
auto v_array = mesh->getMeshField<polyMPO::MeshF_VtxCoords>();
249-
MeshFView<polyMPO::MeshF_VtxCoords> vtxCoords("verticesCoordinates", nVertices);
248+
auto v_array = mesh->getMeshField<MeshF_VtxCoords>();
249+
MeshFView<MeshF_VtxCoords> vtxCoords("verticesCoordinates", nVertices);
250250
Kokkos::parallel_for("set vtxCoords", nVertices_size, KOKKOS_LAMBDA(const int i){
251251
for(int f=0; f<replicateFactor; f++){
252252
vtxCoords(i+f*nVertices_size,0) = v_array(i,0);

0 commit comments

Comments
 (0)