/[escript]/branches/diaplayground/finley/src/CPPAdapter/MeshAdapter.cpp
ViewVC logotype

Diff of /branches/diaplayground/finley/src/CPPAdapter/MeshAdapter.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2644 by jfenwick, Wed Sep 2 04:14:03 2009 UTC revision 2748 by gross, Tue Nov 17 07:32:59 2009 UTC
# Line 240  void MeshAdapter::dump(const std::string Line 240  void MeshAdapter::dump(const std::string
240        throw DataException("Error - MeshAdapter::dump: appending num_FaceElements_numNodes to NetCDF file failed: " + *newFileName);        throw DataException("Error - MeshAdapter::dump: appending num_FaceElements_numNodes to NetCDF file failed: " + *newFileName);
241     if (!dataFile.add_att("num_ContactElements_numNodes",num_ContactElements_numNodes) )     if (!dataFile.add_att("num_ContactElements_numNodes",num_ContactElements_numNodes) )
242        throw DataException("Error - MeshAdapter::dump: appending num_ContactElements_numNodes to NetCDF file failed: " + *newFileName);        throw DataException("Error - MeshAdapter::dump: appending num_ContactElements_numNodes to NetCDF file failed: " + *newFileName);
243     if (!dataFile.add_att("Elements_TypeId", mesh->Elements->ReferenceElement->Type->TypeId) )     if (!dataFile.add_att("Elements_TypeId", mesh->Elements->referenceElementSet->referenceElement->Type->TypeId) )
244        throw DataException("Error - MeshAdapter::dump: appending Elements_TypeId to NetCDF file failed: " + *newFileName);        throw DataException("Error - MeshAdapter::dump: appending Elements_TypeId to NetCDF file failed: " + *newFileName);
245     if (!dataFile.add_att("FaceElements_TypeId", mesh->FaceElements->ReferenceElement->Type->TypeId) )     if (!dataFile.add_att("FaceElements_TypeId", mesh->FaceElements->referenceElementSet->referenceElement->Type->TypeId) )
246        throw DataException("Error - MeshAdapter::dump: appending FaceElements_TypeId to NetCDF file failed: " + *newFileName);        throw DataException("Error - MeshAdapter::dump: appending FaceElements_TypeId to NetCDF file failed: " + *newFileName);
247     if (!dataFile.add_att("ContactElements_TypeId", mesh->ContactElements->ReferenceElement->Type->TypeId) )     if (!dataFile.add_att("ContactElements_TypeId", mesh->ContactElements->referenceElementSet->referenceElement->Type->TypeId) )
248        throw DataException("Error - MeshAdapter::dump: appending ContactElements_TypeId to NetCDF file failed: " + *newFileName);        throw DataException("Error - MeshAdapter::dump: appending ContactElements_TypeId to NetCDF file failed: " + *newFileName);
249     if (!dataFile.add_att("Points_TypeId", mesh->Points->ReferenceElement->Type->TypeId) )     if (!dataFile.add_att("Points_TypeId", mesh->Points->referenceElementSet->referenceElement->Type->TypeId) )
250        throw DataException("Error - MeshAdapter::dump: appending Points_TypeId to NetCDF file failed: " + *newFileName);        throw DataException("Error - MeshAdapter::dump: appending Points_TypeId to NetCDF file failed: " + *newFileName);
251     if (!dataFile.add_att("num_Tags", num_Tags) )     if (!dataFile.add_att("num_Tags", num_Tags) )
252        throw DataException("Error - MeshAdapter::dump: appending num_Tags to NetCDF file failed: " + *newFileName);        throw DataException("Error - MeshAdapter::dump: appending num_Tags to NetCDF file failed: " + *newFileName);
# Line 693  pair<int,int> MeshAdapter::getDataShape( Line 693  pair<int,int> MeshAdapter::getDataShape(
693     case(Elements):     case(Elements):
694     if (mesh->Elements!=NULL) {     if (mesh->Elements!=NULL) {
695        numSamples=mesh->Elements->numElements;        numSamples=mesh->Elements->numElements;
696        numDataPointsPerSample=mesh->Elements->ReferenceElement->numQuadNodes;        numDataPointsPerSample=mesh->Elements->referenceElementSet->referenceElement->Parametrization->numQuadNodes;
697     }     }
698     break;     break;
699     case(ReducedElements):     case(ReducedElements):
700     if (mesh->Elements!=NULL) {     if (mesh->Elements!=NULL) {
701        numSamples=mesh->Elements->numElements;        numSamples=mesh->Elements->numElements;
702        numDataPointsPerSample=mesh->Elements->ReferenceElementReducedOrder->numQuadNodes;        numDataPointsPerSample=mesh->Elements->referenceElementSet->referenceElementReducedQuadrature->Parametrization->numQuadNodes;
703     }     }
704     break;     break;
705     case(FaceElements):     case(FaceElements):
706     if (mesh->FaceElements!=NULL) {     if (mesh->FaceElements!=NULL) {
707        numDataPointsPerSample=mesh->FaceElements->ReferenceElement->numQuadNodes;        numDataPointsPerSample=mesh->FaceElements->referenceElementSet->referenceElement->Parametrization->numQuadNodes;
708        numSamples=mesh->FaceElements->numElements;        numSamples=mesh->FaceElements->numElements;
709     }     }
710     break;     break;
711     case(ReducedFaceElements):     case(ReducedFaceElements):
712     if (mesh->FaceElements!=NULL) {     if (mesh->FaceElements!=NULL) {
713        numDataPointsPerSample=mesh->FaceElements->ReferenceElementReducedOrder->numQuadNodes;        numDataPointsPerSample=mesh->FaceElements->referenceElementSet->referenceElementReducedQuadrature->Parametrization->numQuadNodes;
714        numSamples=mesh->FaceElements->numElements;        numSamples=mesh->FaceElements->numElements;
715     }     }
716     break;     break;
# Line 722  pair<int,int> MeshAdapter::getDataShape( Line 722  pair<int,int> MeshAdapter::getDataShape(
722     break;     break;
723     case(ContactElementsZero):     case(ContactElementsZero):
724     if (mesh->ContactElements!=NULL) {     if (mesh->ContactElements!=NULL) {
725        numDataPointsPerSample=mesh->ContactElements->ReferenceElement->numQuadNodes;        numDataPointsPerSample=mesh->ContactElements->referenceElementSet->referenceElement->Parametrization->numQuadNodes;
726        numSamples=mesh->ContactElements->numElements;        numSamples=mesh->ContactElements->numElements;
727     }     }
728     break;     break;
729     case(ReducedContactElementsZero):     case(ReducedContactElementsZero):
730     if (mesh->ContactElements!=NULL) {     if (mesh->ContactElements!=NULL) {
731        numDataPointsPerSample=mesh->ContactElements->ReferenceElementReducedOrder->numQuadNodes;        numDataPointsPerSample=mesh->ContactElements->referenceElementSet->referenceElementReducedQuadrature->Parametrization->numQuadNodes;
732        numSamples=mesh->ContactElements->numElements;        numSamples=mesh->ContactElements->numElements;
733     }     }
734     break;     break;
735     case(ContactElementsOne):     case(ContactElementsOne):
736     if (mesh->ContactElements!=NULL) {     if (mesh->ContactElements!=NULL) {
737        numDataPointsPerSample=mesh->ContactElements->ReferenceElement->numQuadNodes;        numDataPointsPerSample=mesh->ContactElements->referenceElementSet->referenceElement->Parametrization->numQuadNodes;
738        numSamples=mesh->ContactElements->numElements;        numSamples=mesh->ContactElements->numElements;
739     }     }
740     break;     break;
741     case(ReducedContactElementsOne):     case(ReducedContactElementsOne):
742     if (mesh->ContactElements!=NULL) {     if (mesh->ContactElements!=NULL) {
743        numDataPointsPerSample=mesh->ContactElements->ReferenceElementReducedOrder->numQuadNodes;        numDataPointsPerSample=mesh->ContactElements->referenceElementSet->referenceElementReducedQuadrature->Parametrization->numQuadNodes;
744        numSamples=mesh->ContactElements->numElements;        numSamples=mesh->ContactElements->numElements;
745     }     }
746     break;     break;

Legend:
Removed from v.2644  
changed lines
  Added in v.2748

  ViewVC Help
Powered by ViewVC 1.1.26