diff --git a/apf/apfShape.cc b/apf/apfShape.cc index 5806b07fe..b41f308d0 100644 --- a/apf/apfShape.cc +++ b/apf/apfShape.cc @@ -522,12 +522,34 @@ class QuadraticBase : public FieldShape } int countNodes() const {return 10;} }; + class Prism : public EntityShape + { + public: + void getValues(Mesh*, MeshEntity*, + Vector3 const& , NewArray& ) const + { + fail("getValue not implemented for quadratic prisms type!"); + } + void getLocalGradients(Mesh*, MeshEntity*, + Vector3 const& , + NewArray& ) const + { + fail("getLocalGradients not implemented for quadratic prisms type!"); + } + void getVectorValues(Mesh*, MeshEntity*, + Vector3 const&, NewArray&) const + { + fail("getVectorValues not defined for nodal shapes"); + } + int countNodes() const {return 18;} + }; EntityShape* getEntityShape(int type) { static Linear::Vertex vertex; static Edge edge; static Triangle triangle; static Tetrahedron tet; + static Prism prism; static EntityShape* shapes[Mesh::TYPES] = {&vertex, //vertex &edge, //edge @@ -535,7 +557,7 @@ class QuadraticBase : public FieldShape NULL, //quad &tet, //tet NULL, //hex - NULL, //prism + &prism, //prism NULL}; //pyramid return shapes[type]; } diff --git a/apf/apfVtk.cc b/apf/apfVtk.cc index e71744a38..c1568db5e 100644 --- a/apf/apfVtk.cc +++ b/apf/apfVtk.cc @@ -557,7 +557,7 @@ static void writeTypes(std::ostream& file, ,{ 9,23}//quad ,{10,24}//tet ,{12,25}//hex - ,{13,-1}//prism + ,{13,32}//prism ,{14,-1}//pyramid }; if (isWritingBinary)