From 601d479900f1e23c820ea54c6da3ccb373482587 Mon Sep 17 00:00:00 2001 From: admin Date: Tue, 6 Oct 2009 07:45:00 +0000 Subject: [PATCH] This commit was generated by cvs2git to create tag 'V1_ParaMEDSPLITTER'. Sprout from BR_ParaMEDSPLITTER 2009-08-13 13:45:18 UTC eap 'Parallel MED splitter' Cherrypick from BR_ParaMEDSPLITTER 2009-10-06 07:44:59 UTC eap 'missing config files': adm_local/unix/config_files/check_parmetis.m4 Delete: adm_local/unix/config_files/check_GUI.m4 adm_local/unix/config_files/check_opengl.m4 adm_local/unix/config_files/check_qt.m4 adm_local/unix/config_files/check_vtk.m4 adm_local_without_kernel/cmake_files/FindMPI.cmake adm_local_without_kernel/cmake_files/FindPLATFORM.cmake adm_local_without_kernel/cmake_files/am2cmake.py adm_local_without_kernel/unix/config_files/check_htmlgen.m4 idl/MEDCouplingCorbaServant.idl idl/MEDCouplingCorbaServantTest.idl idl/ParaMEDMEMComponent.idl resources/Mesh3D_10_2d1.med resources/Mesh3D_10_2d2.med resources/Mesh3D_11.med src/INTERP_KERNEL/InterpolationOptions.cxx src/INTERP_KERNEL/PlanarIntersectorP1P1.hxx src/INTERP_KERNEL/PlanarIntersectorP1P1.txx src/MEDCoupling/MEDCoupling.hxx src/MEDCoupling/MEDCouplingCMesh.cxx src/MEDCoupling/MEDCouplingCMesh.hxx src/MEDCoupling/MEDCouplingFieldDiscretization.cxx src/MEDCoupling/MEDCouplingFieldDiscretization.hxx src/MEDCoupling/MEDCouplingMemArray.cxx src/MEDCoupling/MEDCouplingMemArray.hxx src/MEDCoupling/MEDCouplingMemArray.txx src/MEDCoupling/MEDCouplingNatureOfField.hxx src/MEDCoupling/MEDCouplingPointSet.cxx src/MEDCoupling/MEDCouplingPointSet.hxx src/MEDCoupling/MEDCouplingRefCountObject.cxx src/MEDCoupling/MEDCouplingRefCountObject.hxx src/MEDCoupling/MEDCouplingTimeDiscretization.cxx src/MEDCoupling/MEDCouplingTimeDiscretization.hxx src/MEDCoupling/MEDCouplingTimeLabel.cxx src/MEDCoupling/MEDCouplingTimeLabel.hxx src/MEDCoupling/MEDCouplingUMeshDesc.cxx src/MEDCoupling/MEDCouplingUMeshDesc.hxx src/MEDCouplingCorba/Client/MEDCouplingClient.hxx src/MEDCouplingCorba/Client/MEDCouplingFieldDoubleClient.cxx src/MEDCouplingCorba/Client/MEDCouplingFieldDoubleClient.hxx src/MEDCouplingCorba/Client/MEDCouplingMeshClient.cxx src/MEDCouplingCorba/Client/MEDCouplingMeshClient.hxx src/MEDCouplingCorba/Client/MEDCouplingUMeshClient.cxx src/MEDCouplingCorba/Client/MEDCouplingUMeshClient.hxx src/MEDCouplingCorba/Client/Makefile.am src/MEDCouplingCorba/MEDCouplingCorba.hxx src/MEDCouplingCorba/MEDCouplingFieldDoubleServant.cxx src/MEDCouplingCorba/MEDCouplingFieldDoubleServant.hxx src/MEDCouplingCorba/MEDCouplingFieldServant.cxx src/MEDCouplingCorba/MEDCouplingFieldServant.hxx src/MEDCouplingCorba/MEDCouplingMeshServant.cxx src/MEDCouplingCorba/MEDCouplingMeshServant.hxx src/MEDCouplingCorba/MEDCouplingPointSetServant.cxx src/MEDCouplingCorba/MEDCouplingPointSetServant.hxx src/MEDCouplingCorba/MEDCouplingRefCountServant.cxx src/MEDCouplingCorba/MEDCouplingRefCountServant.hxx src/MEDCouplingCorba/MEDCouplingUMeshServant.cxx src/MEDCouplingCorba/MEDCouplingUMeshServant.hxx src/MEDCouplingCorba/Makefile.am src/MEDCouplingCorba/Test/MEDCouplingMeshFieldFactoryComponent.cxx src/MEDCouplingCorba/Test/MEDCouplingMeshFieldFactoryComponent.hxx src/MEDCouplingCorba/Test/MEDCouplingMeshFieldFactoryComponentClt.cxx src/MEDCouplingCorba/Test/MEDCouplingMeshFieldFactoryComponentClt.hxx src/MEDCouplingCorba/Test/MEDCouplingMeshFieldFactoryComponentServ.cxx src/MEDCouplingCorba/Test/MEDCouplingMeshFieldFactoryComponentServ.hxx src/MEDCouplingCorba/Test/Makefile.am src/MEDCouplingCorba/Test/TestMEDCouplingCorbaClt.cxx src/MEDCouplingCorba/Test/TestMEDCouplingCorbaServ.cxx src/MEDCoupling_Swig/MEDCouplingBasicsTest.py src/MEDCoupling_Swig/MEDCouplingTypemaps.i src/MEDCoupling_Swig/Makefile.am src/MEDCoupling_Swig/libMEDCoupling_Swig.i src/MEDMEM/MEDMEM_MeshFuse.cxx src/MEDMEM/MEDMEM_MeshFuse.hxx src/MEDMEMCppTest/MEDMEMTest_MeshFuse.cxx src/MEDMEMCppTest/MEDMEMTest_Utils.cxx src/MEDMEMCppTest/MEDMEMTest_Utils.hxx src/MEDSPLITTER/MEDSPLITTER_JointExchangeData.cxx src/MEDSPLITTER/MEDSPLITTER_JointExchangeData.hxx src/MEDSPLITTER/MEDSPLITTER_MeshSendReceive.cxx src/MEDSPLITTER/MEDSPLITTER_MeshSendReceive.hxx src/MEDSPLITTER/MEDSPLITTER_ParaDomainSelector.cxx src/MEDSPLITTER/MEDSPLITTER_ParaDomainSelector.hxx src/MEDSPLITTER/Test/MEDSPLITTERTest_Utils.cxx src/MEDSPLITTER/Test/MEDSPLITTERTest_Utils.hxx src/MEDSPLITTER/Test/ParaMEDSPLITTERTest.hxx src/MEDSPLITTER/Test/ParaMEDSPLITTERTest_MeshSendReceive.cxx src/MEDSPLITTER/Test/ParaMEDSPLITTERTest_ParaDomainSelector.cxx src/MEDSPLITTER/Test/ParaMEDSPLITTERTest_medsplitter_para.cxx src/MEDSPLITTER/Test/TestParaMEDSPLITTER.cxx src/MEDSPLITTER/Test/testParaMEDSPLITTER.py src/MEDSPLITTER/medsplitter_para.cxx src/MedClient/src/MEDClient.hxx src/ParaMEDMEM/GlobalizerMesh.cxx src/ParaMEDMEM/GlobalizerMesh.hxx src/ParaMEDMEM/Test/ParaMEDMEMTest_ICocoTrio.cxx src/ParaMEDMEM/Test/ParaMEDMEMTest_MEDLoader.cxx src/ParaMEDMEM/Test/test_perf.cxx src/ParaMEDMEMComponent/Makefile.am src/ParaMEDMEMComponent/ParaMEDMEMComponent_i.cxx src/ParaMEDMEMComponent/ParaMEDMEMComponent_i.hxx --- resources/Mesh3D_11.med | Bin 153532 -> 0 bytes src/INTERP_KERNEL/InterpolationOptions.cxx | 25 - src/INTERP_KERNEL/PlanarIntersectorP1P1.hxx | 47 -- src/INTERP_KERNEL/PlanarIntersectorP1P1.txx | 100 ---- src/MEDCoupling/MEDCoupling.hxx | 35 -- src/MEDCoupling/MEDCouplingCMesh.cxx | 182 ------- src/MEDCoupling/MEDCouplingCMesh.hxx | 59 --- .../MEDCouplingFieldDiscretization.cxx | 182 ------- .../MEDCouplingFieldDiscretization.hxx | 85 ---- src/MEDCoupling/MEDCouplingMemArray.cxx | 161 ------- src/MEDCoupling/MEDCouplingMemArray.hxx | 155 ------ src/MEDCoupling/MEDCouplingMemArray.txx | 159 ------- src/MEDCoupling/MEDCouplingNatureOfField.hxx | 33 -- src/MEDCoupling/MEDCouplingPointSet.cxx | 323 ------------- src/MEDCoupling/MEDCouplingPointSet.hxx | 72 --- src/MEDCoupling/MEDCouplingRefCountObject.cxx | 46 -- src/MEDCoupling/MEDCouplingRefCountObject.hxx | 60 --- .../MEDCouplingTimeDiscretization.cxx | 403 ---------------- .../MEDCouplingTimeDiscretization.hxx | 167 ------- src/MEDCoupling/MEDCouplingTimeLabel.cxx | 48 -- src/MEDCoupling/MEDCouplingTimeLabel.hxx | 48 -- src/MEDCoupling/MEDCouplingUMeshDesc.cxx | 263 ---------- src/MEDCoupling/MEDCouplingUMeshDesc.hxx | 71 --- src/MEDCoupling_Swig/MEDCouplingBasicsTest.py | 62 --- src/MEDCoupling_Swig/MEDCouplingTypemaps.i | 128 ----- src/MEDCoupling_Swig/Makefile.am | 52 -- src/MEDCoupling_Swig/libMEDCoupling_Swig.i | 185 -------- src/ParaMEDMEM/GlobalizerMesh.cxx | 143 ------ src/ParaMEDMEM/GlobalizerMesh.hxx | 72 --- .../Test/ParaMEDMEMTest_ICocoTrio.cxx | 252 ---------- .../Test/ParaMEDMEMTest_MEDLoader.cxx | 448 ------------------ src/ParaMEDMEM/Test/test_perf.cxx | 317 ------------- 32 files changed, 4383 deletions(-) delete mode 100644 resources/Mesh3D_11.med delete mode 100644 src/INTERP_KERNEL/InterpolationOptions.cxx delete mode 100644 src/INTERP_KERNEL/PlanarIntersectorP1P1.hxx delete mode 100644 src/INTERP_KERNEL/PlanarIntersectorP1P1.txx delete mode 100644 src/MEDCoupling/MEDCoupling.hxx delete mode 100644 src/MEDCoupling/MEDCouplingCMesh.cxx delete mode 100644 src/MEDCoupling/MEDCouplingCMesh.hxx delete mode 100644 src/MEDCoupling/MEDCouplingFieldDiscretization.cxx delete mode 100644 src/MEDCoupling/MEDCouplingFieldDiscretization.hxx delete mode 100644 src/MEDCoupling/MEDCouplingMemArray.cxx delete mode 100644 src/MEDCoupling/MEDCouplingMemArray.hxx delete mode 100644 src/MEDCoupling/MEDCouplingMemArray.txx delete mode 100644 src/MEDCoupling/MEDCouplingNatureOfField.hxx delete mode 100644 src/MEDCoupling/MEDCouplingPointSet.cxx delete mode 100644 src/MEDCoupling/MEDCouplingPointSet.hxx delete mode 100644 src/MEDCoupling/MEDCouplingRefCountObject.cxx delete mode 100644 src/MEDCoupling/MEDCouplingRefCountObject.hxx delete mode 100644 src/MEDCoupling/MEDCouplingTimeDiscretization.cxx delete mode 100644 src/MEDCoupling/MEDCouplingTimeDiscretization.hxx delete mode 100644 src/MEDCoupling/MEDCouplingTimeLabel.cxx delete mode 100644 src/MEDCoupling/MEDCouplingTimeLabel.hxx delete mode 100644 src/MEDCoupling/MEDCouplingUMeshDesc.cxx delete mode 100644 src/MEDCoupling/MEDCouplingUMeshDesc.hxx delete mode 100644 src/MEDCoupling_Swig/MEDCouplingBasicsTest.py delete mode 100644 src/MEDCoupling_Swig/MEDCouplingTypemaps.i delete mode 100644 src/MEDCoupling_Swig/Makefile.am delete mode 100644 src/MEDCoupling_Swig/libMEDCoupling_Swig.i delete mode 100644 src/ParaMEDMEM/GlobalizerMesh.cxx delete mode 100644 src/ParaMEDMEM/GlobalizerMesh.hxx delete mode 100644 src/ParaMEDMEM/Test/ParaMEDMEMTest_ICocoTrio.cxx delete mode 100644 src/ParaMEDMEM/Test/ParaMEDMEMTest_MEDLoader.cxx delete mode 100644 src/ParaMEDMEM/Test/test_perf.cxx diff --git a/resources/Mesh3D_11.med b/resources/Mesh3D_11.med deleted file mode 100644 index 5088b55b3596aefb0e6ed19aae9b2f15598cd4e9..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 153532 zcmeF)1%MUh+5q6C5m4zgKtVw|Bn1IU>Fy3e=@J_y1Op2dlU8h0RK!9>#qRFz?&N>o zUFM2=3B9cU)$7@NAK&-;zIW!FotZPSGt16v)1uYR`AX+Yi?6&n({iR2Ov{np$oS93 zO<%Y6%AVelw4+gQQ(?A@(zGd?lKz|8ZCW<#oSy10E19yXKM8F+w(8VvQ0tZ*TXt>M zzGb(xmL0nd>d>rNTFmCPr09PzcJJD2P`yZ)THlbg zLpD_n*Pf(yjJnDChNo3ctC?0St$tdyv#H)@?o9DmrJ~}TMdBgtlY-!okzlXB& z_$p+{#`lzY+fE&In_>*--1M1FYDR6^Mw({YR?;W@ANtSc zpN;g-(57XQe2X1MOdd6;Zt~gK^8TU-10gfTr8tD{kWDo2L2b0fqAyLKde$<)4I$!75vwV&DbAiOJA==H+^1{ zeckj;`^V0k;=d;P2PVn6MCSc}fwUUwOCy`J?*f)$hh_(-w+mWkIn%SUo5s_FBTvTH zzfIS+WBS0>rb`YtnWyX8vi&xv+jRK)*SS#Ub((p8E!uY2=KOwrAD^Yy#rK`p|5~^P zh_52tPqGa~-~ZBA=H=DBPv`V+Z)@u<`Q8hpO;1mg<<+BO&-8XIuP!9ZYx0O;qee_B z+hP2;vK@v@DqFTe*_t&Q)~egEcI~pYYSd^@wtk&jb?V2-Zt5$w1X4>NwFFX2;QwU_ zY<_MW*N)3eZTV%l_4A>lV?tkXI+eN}`s-W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&cR9G7nfFN4Q%%PYOIrLsZyDcoxsl<;uYeD$iQau5Uv|7VENZ3Ui{JUY&bJ1i z!yB{q!{R%|O~nKGvx~puFO5G3t6O>K@%w?pw0H4MyfK>%6n7N26PLy_!CLATsrf|y zMtC{=g!d=F2`} zw3%vF@XeGP9bUW&e3Ul@et<70-WL|P(($cR^CoQ_K94u%?MKC}#n*`k@#hr(z+V<0 z53jQF(PM5tO51^N;q5FQB(5igC(r=eCyS`MO%;0=Z%^B zG4WmE>&1ilbBRy#m%}H(npS>#%+AMX@8er}yNCyiyNK@*m&4D6b=56Z^SS&jup<1N z_gDHJ`fz+IK3x9E@Z&|`?do3TPX#-`#`Fu}H?-MmR`Jc28yjA{8ho5L6@HNKBD_B= zX=UJhTYiJO4fulaievU}BfdfWH2+0%Kk{FSPlQ)n1?V5kf57_z{!)0wUBz9+_lhqS zp9kxydr{37^0&fD@Hg5QynE@>@Dcb3`Cj1{Ujpw?_Zoj{_z-MD&j!Dxt>%f}>%AcN zY$)5@I%@)upm56 z`;hJ0A9&Ize zn76&SleoS3CUIW;XWsJaCc|CwwP9hni}zFdHohMCGk6dA2gK#^^I=1EEBH^yw}4gP z3EmX=0s3fsChutZzTwAKZ&mj`Z7aT%_a1Q<@jc>O#QE`Gc`K@$3irs@g+<^V-p}c; z@;!+U$Dfq%Ag+jC2pg+g#s7``?XVjBhBp;{kUkcl%{x}UfB5l|u#LL6c{0Gq;YHSu z@(cJk@GRh;7(V<4{A#=_ZwB$%|2z8=IQtVg`x7|(6FB=5IQtVg`x7|(6FB=5IQtVg j`x7|(6FB=5IQtVg`x7|(6FB=5IQtVg`xE%z@Duny9y7of diff --git a/src/INTERP_KERNEL/InterpolationOptions.cxx b/src/INTERP_KERNEL/InterpolationOptions.cxx deleted file mode 100644 index a23422564..000000000 --- a/src/INTERP_KERNEL/InterpolationOptions.cxx +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#include "InterpolationOptions.hxx" - -const double INTERP_KERNEL::InterpolationOptions::DFT_MEDIAN_PLANE=0.5; - -const double INTERP_KERNEL::InterpolationOptions::DFT_SURF3D_ADJ_EPS=1.e-4; - -const double INTERP_KERNEL::InterpolationOptions::DFT_MAX_DIST_3DSURF_INTERSECT=-1.; diff --git a/src/INTERP_KERNEL/PlanarIntersectorP1P1.hxx b/src/INTERP_KERNEL/PlanarIntersectorP1P1.hxx deleted file mode 100644 index 44854c8ef..000000000 --- a/src/INTERP_KERNEL/PlanarIntersectorP1P1.hxx +++ /dev/null @@ -1,47 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#ifndef __PLANARINTERSECTORP1P1_HXX__ -#define __PLANARINTERSECTORP1P1_HXX__ - -#include "PlanarIntersector.hxx" - -namespace INTERP_KERNEL -{ - template - class PlanarIntersectorP1P1 : public PlanarIntersector - { - public: - static const int SPACEDIM=MyMeshType::MY_SPACEDIM; - static const int MESHDIM=MyMeshType::MY_MESHDIM; - typedef typename MyMeshType::MyConnType ConnType; - static const NumberingPolicy numPol=MyMeshType::My_numPol; - protected: - PlanarIntersectorP1P1(const MyMeshType& meshT, const MyMeshType& meshS, double dimCaracteristic, double precision, double md3DSurf, double medianPlane, bool doRotate, int orientation, int printLevel); - public: - void intersectCells(ConnType icellT, const std::vector& icellsS, MyMatrix& res); - int getNumberOfRowsOfResMatrix() const; - int getNumberOfColsOfResMatrix() const; - - double intersectGeometryGeneral(const std::vector& targetCoords, const std::vector& sourceCoords) { return asLeaf().intersectGeometryGeneral(targetCoords,sourceCoords); } - protected: - ConcreteP1P1Intersector& asLeaf() { return static_cast(*this); } - }; -} - -#endif diff --git a/src/INTERP_KERNEL/PlanarIntersectorP1P1.txx b/src/INTERP_KERNEL/PlanarIntersectorP1P1.txx deleted file mode 100644 index 66ab5e59d..000000000 --- a/src/INTERP_KERNEL/PlanarIntersectorP1P1.txx +++ /dev/null @@ -1,100 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email :webmaster.salome@opencascade.com -#ifndef __PLANARINTERSECTORP1P1_TXX__ -#define __PLANARINTERSECTORP1P1_TXX__ - -#include "PlanarIntersectorP1P1.hxx" -#include "InterpolationUtils.hxx" -#include "CellModel.hxx" - -namespace INTERP_KERNEL -{ - template - PlanarIntersectorP1P1::PlanarIntersectorP1P1(const MyMeshType& meshT, const MyMeshType& meshS, - double dimCaracteristic, double precision, double md3DSurf, double medianPlane, - bool doRotate, int orientation, int printLevel): - PlanarIntersector(meshT,meshS,dimCaracteristic,precision,md3DSurf,medianPlane,doRotate,orientation,printLevel) - { - } - - template - int PlanarIntersectorP1P1::getNumberOfRowsOfResMatrix() const - { - return PlanarIntersector::_meshT.getNumberOfNodes(); - } - - template - int PlanarIntersectorP1P1::getNumberOfColsOfResMatrix() const - { - return PlanarIntersector::_meshS.getNumberOfNodes(); - } - - /*! - * This methods split on the fly, into triangles in order to compute dual mesh of target cell (with icellT id in target mesh in C mode). - */ - template - void PlanarIntersectorP1P1::intersectCells(ConnType icellT, const std::vector& icellsS, MyMatrix& res) - { - int nbNodesT=PlanarIntersector::_connIndexT[icellT+1]-PlanarIntersector::_connIndexT[icellT]; - int orientation=1; - const ConnType *startOfCellNodeConn=PlanarIntersector::_connectT+OTT::conn2C(PlanarIntersector::_connIndexT[icellT]); - std::vector polygT; - PlanarIntersector::getRealTargetCoordinates(OTT::indFC(icellT),polygT); - for(int nodeIdT=0;nodeIdT::coo2C(startOfCellNodeConn[nodeIdT]); - PlanarIntersector::getRealTargetCoordinatesPermute(OTT::indFC(icellT),nodeIdT,polygT); - std::vector polygDualT(SPACEDIM*2*(nbNodesT-1)); - fillDualCellOfPolyg(&polygT[0],polygT.size()/SPACEDIM,&polygDualT[0]); - typename MyMatrix::value_type& resRow=res[curNodeTInCmode]; - for(typename std::vector::const_iterator iter=icellsS.begin();iter!=icellsS.end();iter++) - { - int iS=*iter; - int nbNodesS=PlanarIntersector::_connIndexS[iS+1]-PlanarIntersector::_connIndexS[iS]; - const ConnType *startOfCellNodeConnS=PlanarIntersector::_connectS+OTT::conn2C(PlanarIntersector::_connIndexS[iS]); - for(int nodeIdS=0;nodeIdS::coo2C(startOfCellNodeConnS[nodeIdS]); - std::vector polygS; - PlanarIntersector::getRealSourceCoordinatesPermute(OTT::indFC(iS),nodeIdS,polygS); - std::vector polygDualS(SPACEDIM*2*(nbNodesS-1)); - fillDualCellOfPolyg(&polygS[0],polygS.size()/SPACEDIM,&polygDualS[0]); - std::vector polygDualTTmp(polygDualT); - if(SPACEDIM==3) - orientation=PlanarIntersector::projectionThis(&polygDualS[0],&polygDualTTmp[0],polygDualS.size()/SPACEDIM,polygDualT.size()/SPACEDIM); - double surf=orientation*intersectGeometryGeneral(polygDualTTmp,polygDualS); - surf=PlanarIntersector::getValueRegardingOption(surf); - if(surf!=0.) - { - typename MyMatrix::value_type::const_iterator iterRes=resRow.find(OTT::indFC(curNodeSInCmode)); - if(iterRes==resRow.end()) - resRow.insert(std::make_pair(OTT::indFC(curNodeSInCmode),surf)); - else - { - double val=(*iterRes).second+surf; - resRow.erase(OTT::indFC(curNodeSInCmode)); - resRow.insert(std::make_pair(OTT::indFC(curNodeSInCmode),val)); - } - } - } - } - } - } -} - -#endif diff --git a/src/MEDCoupling/MEDCoupling.hxx b/src/MEDCoupling/MEDCoupling.hxx deleted file mode 100644 index 5779d27f7..000000000 --- a/src/MEDCoupling/MEDCoupling.hxx +++ /dev/null @@ -1,35 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D, OPEN CASCADE -// -// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#ifndef _MEDCOUPLING_HXX_ -#define _MEDCOUPLING_HXX_ - -#ifdef WNT -# if defined medcoupling_EXPORTS -# define MEDCOUPLING_EXPORT __declspec( dllexport ) -# else -# define MEDCOUPLING_EXPORT __declspec( dllimport ) -# endif -#else -# define MEDCOUPLING_EXPORT -#endif - -#endif diff --git a/src/MEDCoupling/MEDCouplingCMesh.cxx b/src/MEDCoupling/MEDCouplingCMesh.cxx deleted file mode 100644 index 33f7214c0..000000000 --- a/src/MEDCoupling/MEDCouplingCMesh.cxx +++ /dev/null @@ -1,182 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#include "MEDCouplingCMesh.hxx" -#include "MEDCouplingMemArray.hxx" - -using namespace ParaMEDMEM; - -MEDCouplingCMesh::MEDCouplingCMesh():_x_array(0),_y_array(0),_z_array(0) -{ -} - -MEDCouplingCMesh::~MEDCouplingCMesh() -{ - if(_x_array) - _x_array->decrRef(); - if(_y_array) - _y_array->decrRef(); - if(_z_array) - _z_array->decrRef(); -} - -MEDCouplingCMesh *MEDCouplingCMesh::New() -{ - return new MEDCouplingCMesh; -} - -void MEDCouplingCMesh::updateTime() -{ - if(_x_array) - updateTimeWith(*_x_array); - if(_y_array) - updateTimeWith(*_y_array); - if(_z_array) - updateTimeWith(*_z_array); -} - -bool MEDCouplingCMesh::isEqual(const MEDCouplingMesh *other, double prec) const -{ - const MEDCouplingCMesh *otherC=dynamic_cast(other); - if(!otherC) - return false; - return true; -} - -void MEDCouplingCMesh::checkCoherency() const throw(INTERP_KERNEL::Exception) -{ - const char msg0[]="Invalid "; - const char msg1[]=" array ! Must contain more than 1 element."; - if(_x_array) - if(_x_array->getNbOfElems()<2) - { - std::ostringstream os; os << msg0 << 'X' << msg1; - throw INTERP_KERNEL::Exception(os.str().c_str()); - } - if(_y_array) - if(_y_array->getNbOfElems()<2) - { - std::ostringstream os; os << msg0 << 'Y' << msg1; - throw INTERP_KERNEL::Exception(os.str().c_str()); - } - if(_z_array) - if(_z_array->getNbOfElems()<2) - { - std::ostringstream os; os << msg0 << 'Z' << msg1; - throw INTERP_KERNEL::Exception(os.str().c_str()); - } -} - -bool MEDCouplingCMesh::isStructured() const -{ - return true; -} - -int MEDCouplingCMesh::getNumberOfCells() const -{ - int ret=1; - if(_x_array) - ret*=_x_array->getNbOfElems()-1; - if(_y_array) - ret*=_y_array->getNbOfElems()-1; - if(_z_array) - ret*=_z_array->getNbOfElems()-1; - return ret; -} - -int MEDCouplingCMesh::getNumberOfNodes() const -{ - int ret=1; - if(_x_array) - ret*=_x_array->getNbOfElems(); - if(_y_array) - ret*=_y_array->getNbOfElems(); - if(_z_array) - ret*=_z_array->getNbOfElems(); - return ret; -} - -int MEDCouplingCMesh::getSpaceDimension() const -{ - int ret=0; - if(_x_array) - ret++; - if(_y_array) - ret++; - if(_z_array) - ret++; - return ret; -} - -int MEDCouplingCMesh::getMeshDimension() const -{ - int ret=0; - if(_x_array) - ret++; - if(_y_array) - ret++; - if(_z_array) - ret++; - return ret; -} - -DataArrayDouble *MEDCouplingCMesh::getCoordsAt(int i) const throw(INTERP_KERNEL::Exception) -{ - switch(i) - { - case 0: - return _x_array; - case 1: - return _y_array; - case 2: - return _z_array; - default: - throw INTERP_KERNEL::Exception("Invalid rank specified must be 0 or 1 or 2."); - } -} - -void MEDCouplingCMesh::setCoords(DataArrayDouble *coordsX, DataArrayDouble *coordsY, DataArrayDouble *coordsZ) -{ - if(_x_array) - _x_array->decrRef(); - _x_array=coordsX; - if(_x_array) - _x_array->incrRef(); - if(_y_array) - _y_array->decrRef(); - _y_array=coordsY; - if(_y_array) - _y_array->incrRef(); - if(_z_array) - _z_array->decrRef(); - _z_array=coordsZ; - if(_z_array) - _z_array->incrRef(); - declareAsNew(); -} - -void MEDCouplingCMesh::getBoundingBox(double *bbox) const -{ - //not implemented yet ! -} - -MEDCouplingFieldDouble *MEDCouplingCMesh::getMeasureField() const -{ - //not implemented yet ! - return 0; -} diff --git a/src/MEDCoupling/MEDCouplingCMesh.hxx b/src/MEDCoupling/MEDCouplingCMesh.hxx deleted file mode 100644 index 212535c44..000000000 --- a/src/MEDCoupling/MEDCouplingCMesh.hxx +++ /dev/null @@ -1,59 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#ifndef __PARAMEDMEM_MEDCOUPLINGCMESH_HXX__ -#define __PARAMEDMEM_MEDCOUPLINGCMESH_HXX__ - -#include "MEDCoupling.hxx" -#include "MEDCouplingMesh.hxx" - -namespace ParaMEDMEM -{ - class DataArrayDouble; - - class MEDCouplingCMesh : public MEDCouplingMesh - { - public: - static MEDCouplingCMesh *New(); - void updateTime(); - MEDCouplingMeshType getType() const { return CARTESIAN; } - bool isEqual(const MEDCouplingMesh *other, double prec) const; - void checkCoherency() const throw(INTERP_KERNEL::Exception); - bool isStructured() const; - int getNumberOfCells() const; - int getNumberOfNodes() const; - int getSpaceDimension() const; - int getMeshDimension() const; - DataArrayDouble *getCoordsAt(int i) const throw(INTERP_KERNEL::Exception); - void setCoords(DataArrayDouble *coordsX, - DataArrayDouble *coordsY=0, - DataArrayDouble *coordsZ=0); - // tools - void getBoundingBox(double *bbox) const; - MEDCouplingFieldDouble *getMeasureField() const; - private: - MEDCouplingCMesh(); - ~MEDCouplingCMesh(); - private: - DataArrayDouble *_x_array; - DataArrayDouble *_y_array; - DataArrayDouble *_z_array; - }; -} - -#endif diff --git a/src/MEDCoupling/MEDCouplingFieldDiscretization.cxx b/src/MEDCoupling/MEDCouplingFieldDiscretization.cxx deleted file mode 100644 index 6987c1bff..000000000 --- a/src/MEDCoupling/MEDCouplingFieldDiscretization.cxx +++ /dev/null @@ -1,182 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#include "MEDCouplingFieldDiscretization.hxx" -#include "MEDCouplingMesh.hxx" -#include "MEDCouplingFieldDouble.hxx" - -#include "MEDCouplingPointSet.hxx" - -using namespace ParaMEDMEM; - -const char MEDCouplingFieldDiscretizationP0::REPR[]="P0"; - -const TypeOfField MEDCouplingFieldDiscretizationP0::TYPE=ON_CELLS; - -const char MEDCouplingFieldDiscretizationP1::REPR[]="P1"; - -const TypeOfField MEDCouplingFieldDiscretizationP1::TYPE=ON_NODES; - -MEDCouplingFieldDiscretization *MEDCouplingFieldDiscretization::New(TypeOfField type) -{ - switch(type) - { - case MEDCouplingFieldDiscretizationP0::TYPE: - return new MEDCouplingFieldDiscretizationP0; - case MEDCouplingFieldDiscretizationP1::TYPE: - return new MEDCouplingFieldDiscretizationP1; - default: - throw INTERP_KERNEL::Exception("Choosen discretization is not implemented yet."); - } -} - -TypeOfField MEDCouplingFieldDiscretizationP0::getEnum() const -{ - return TYPE; -} - -MEDCouplingFieldDiscretization *MEDCouplingFieldDiscretizationP0::clone() const -{ - return new MEDCouplingFieldDiscretizationP0; -} - -const char *MEDCouplingFieldDiscretizationP0::getStringRepr() const -{ - return REPR; -} - -bool MEDCouplingFieldDiscretizationP0::isEqual(const MEDCouplingFieldDiscretization *other) const -{ - const MEDCouplingFieldDiscretizationP0 *otherC=dynamic_cast(other); - return otherC!=0; -} - -int MEDCouplingFieldDiscretizationP0::getNumberOfTuples(const MEDCouplingMesh *mesh) const -{ - return mesh->getNumberOfCells(); -} - -void MEDCouplingFieldDiscretizationP0::checkCompatibilityWithNature(NatureOfField nat) const throw(INTERP_KERNEL::Exception) -{ -} - -void MEDCouplingFieldDiscretizationP0::checkCoherencyBetween(const MEDCouplingMesh *mesh, const DataArrayDouble *da) const throw(INTERP_KERNEL::Exception) -{ - if(mesh->getNumberOfCells()!=da->getNumberOfTuples()) - { - std::ostringstream message; - message << "Field on cells invalid because there are " << mesh->getNumberOfCells(); - message << " cells in mesh and " << da->getNumberOfTuples() << " tuples in field !"; - throw INTERP_KERNEL::Exception(message.str().c_str()); - } -} - -MEDCouplingFieldDouble *MEDCouplingFieldDiscretizationP0::getWeightingField(const MEDCouplingMesh *mesh) const -{ - return mesh->getMeasureField(); -} - -/*! - * This method returns a submesh of 'mesh' instance constituting cell ids contained in array defined as an interval [start;end). - * @ param di is an array returned that specifies entity ids (here cells ids) in mesh 'mesh' of entity in returned submesh. - * Example : The first cell id of returned mesh has the (*di)[0] id in 'mesh' - */ -MEDCouplingMesh *MEDCouplingFieldDiscretizationP0::buildSubMeshData(const int *start, const int *end, const MEDCouplingMesh *mesh, DataArrayInt *&di) const -{ - MEDCouplingPointSet* ret=((const MEDCouplingPointSet *) mesh)->buildPartOfMySelf(start,end,false); - di=DataArrayInt::New(); - di->alloc(end-start,1); - int *pt=di->getPointer(); - std::copy(start,end,pt); - return ret; -} - -TypeOfField MEDCouplingFieldDiscretizationP1::getEnum() const -{ - return TYPE; -} - -MEDCouplingFieldDiscretization *MEDCouplingFieldDiscretizationP1::clone() const -{ - return new MEDCouplingFieldDiscretizationP1; -} - -const char *MEDCouplingFieldDiscretizationP1::getStringRepr() const -{ - return REPR; -} - -bool MEDCouplingFieldDiscretizationP1::isEqual(const MEDCouplingFieldDiscretization *other) const -{ - const MEDCouplingFieldDiscretizationP1 *otherC=dynamic_cast(other); - return otherC!=0; -} - -int MEDCouplingFieldDiscretizationP1::getNumberOfTuples(const MEDCouplingMesh *mesh) const -{ - return mesh->getNumberOfNodes(); -} - -void MEDCouplingFieldDiscretizationP1::checkCompatibilityWithNature(NatureOfField nat) const throw(INTERP_KERNEL::Exception) -{ - if(nat!=ConservativeVolumic) - throw INTERP_KERNEL::Exception("Invalid nature for P1 field !"); -} - -void MEDCouplingFieldDiscretizationP1::checkCoherencyBetween(const MEDCouplingMesh *mesh, const DataArrayDouble *da) const throw(INTERP_KERNEL::Exception) -{ - if(mesh->getNumberOfNodes()!=da->getNumberOfTuples()) - { - std::ostringstream message; - message << "Field on nodes invalid because there are " << mesh->getNumberOfNodes(); - message << " cells in mesh and " << da->getNumberOfTuples() << " tuples in field !"; - throw INTERP_KERNEL::Exception(message.str().c_str()); - } -} - -MEDCouplingFieldDouble *MEDCouplingFieldDiscretizationP1::getWeightingField(const MEDCouplingMesh *mesh) const -{ - //not implemented yet. - //Dual mesh to build - return 0; -} - -/*! - * This method invert array 'di' that is a conversion map from Old to New node numbering to New to Old node numbering. - */ -DataArrayInt *MEDCouplingFieldDiscretizationP1::invertArrayO2N2N2O(const MEDCouplingMesh *mesh, const DataArrayInt *di) -{ - DataArrayInt *ret=DataArrayInt::New(); - ret->alloc(mesh->getNumberOfNodes(),1); - int nbOfOldNodes=di->getNumberOfTuples(); - const int *old2New=di->getConstPointer(); - int *pt=ret->getPointer(); - for(int i=0;i!=nbOfOldNodes;i++) - if(old2New[i]!=-1) - pt[old2New[i]]=i; - return ret; -} - -MEDCouplingMesh *MEDCouplingFieldDiscretizationP1::buildSubMeshData(const int *start, const int *end, const MEDCouplingMesh *mesh, DataArrayInt *&di) const -{ - MEDCouplingPointSet* ret=((const MEDCouplingPointSet *) mesh)->buildPartOfMySelf(start,end,true); - DataArrayInt *diInv=ret->zipCoordsTraducer(); - di=invertArrayO2N2N2O(ret,diInv); - diInv->decrRef(); - return ret; -} diff --git a/src/MEDCoupling/MEDCouplingFieldDiscretization.hxx b/src/MEDCoupling/MEDCouplingFieldDiscretization.hxx deleted file mode 100644 index 6061bf20f..000000000 --- a/src/MEDCoupling/MEDCouplingFieldDiscretization.hxx +++ /dev/null @@ -1,85 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#ifndef __MEDCOUPLINGFIELDDISCRETIZATION_HXX__ -#define __MEDCOUPLINGFIELDDISCRETIZATION_HXX__ - -#include "MEDCoupling.hxx" -#include "MEDCouplingRefCountObject.hxx" -#include "InterpKernelException.hxx" -#include "MEDCouplingNatureOfField.hxx" - -namespace ParaMEDMEM -{ - class DataArrayInt; - class MEDCouplingMesh; - class DataArrayDouble; - class MEDCouplingFieldDouble; - - class MEDCOUPLING_EXPORT MEDCouplingFieldDiscretization - { - public: - static MEDCouplingFieldDiscretization *New(TypeOfField type); - virtual TypeOfField getEnum() const = 0; - virtual bool isEqual(const MEDCouplingFieldDiscretization *other) const = 0; - virtual MEDCouplingFieldDiscretization *clone() const = 0; - virtual const char *getStringRepr() const = 0; - virtual int getNumberOfTuples(const MEDCouplingMesh *mesh) const = 0; - virtual void checkCompatibilityWithNature(NatureOfField nat) const throw(INTERP_KERNEL::Exception) = 0; - virtual void checkCoherencyBetween(const MEDCouplingMesh *mesh, const DataArrayDouble *da) const throw(INTERP_KERNEL::Exception) = 0; - virtual MEDCouplingFieldDouble *getWeightingField(const MEDCouplingMesh *mesh) const = 0; - virtual MEDCouplingMesh *buildSubMeshData(const int *start, const int *end, const MEDCouplingMesh *mesh, DataArrayInt *&di) const = 0; - }; - - class MEDCOUPLING_EXPORT MEDCouplingFieldDiscretizationP0 : public MEDCouplingFieldDiscretization - { - public: - TypeOfField getEnum() const; - MEDCouplingFieldDiscretization *clone() const; - const char *getStringRepr() const; - bool isEqual(const MEDCouplingFieldDiscretization *other) const; - int getNumberOfTuples(const MEDCouplingMesh *mesh) const; - void checkCompatibilityWithNature(NatureOfField nat) const throw(INTERP_KERNEL::Exception); - void checkCoherencyBetween(const MEDCouplingMesh *mesh, const DataArrayDouble *da) const throw(INTERP_KERNEL::Exception); - MEDCouplingFieldDouble *getWeightingField(const MEDCouplingMesh *mesh) const; - MEDCouplingMesh *buildSubMeshData(const int *start, const int *end, const MEDCouplingMesh *mesh, DataArrayInt *&di) const; - public: - static const char REPR[]; - static const TypeOfField TYPE; - }; - - class MEDCOUPLING_EXPORT MEDCouplingFieldDiscretizationP1 : public MEDCouplingFieldDiscretization - { - public: - TypeOfField getEnum() const; - MEDCouplingFieldDiscretization *clone() const; - const char *getStringRepr() const; - bool isEqual(const MEDCouplingFieldDiscretization *other) const; - int getNumberOfTuples(const MEDCouplingMesh *mesh) const; - void checkCompatibilityWithNature(NatureOfField nat) const throw(INTERP_KERNEL::Exception); - void checkCoherencyBetween(const MEDCouplingMesh *mesh, const DataArrayDouble *da) const throw(INTERP_KERNEL::Exception); - MEDCouplingFieldDouble *getWeightingField(const MEDCouplingMesh *mesh) const; - MEDCouplingMesh *buildSubMeshData(const int *start, const int *end, const MEDCouplingMesh *mesh, DataArrayInt *&di) const; - static DataArrayInt *invertArrayO2N2N2O(const MEDCouplingMesh *mesh, const DataArrayInt *di); - public: - static const char REPR[]; - static const TypeOfField TYPE; - }; -} - -#endif diff --git a/src/MEDCoupling/MEDCouplingMemArray.cxx b/src/MEDCoupling/MEDCouplingMemArray.cxx deleted file mode 100644 index b907df1f8..000000000 --- a/src/MEDCoupling/MEDCouplingMemArray.cxx +++ /dev/null @@ -1,161 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#include "MEDCouplingMemArray.txx" - -using namespace ParaMEDMEM; - -void DataArray::setName(const char *name) -{ - _name=name; -} - -bool DataArray::areInfoEquals(const DataArray& other) const -{ - if(_nb_of_tuples!=other._nb_of_tuples) - return false; - if(_name!=other._name) - return false; - return _info_on_compo==other._info_on_compo; -} - -DataArrayDouble *DataArrayDouble::New() -{ - return new DataArrayDouble; -} - -DataArrayDouble *DataArrayDouble::deepCopy() const -{ - return new DataArrayDouble(*this); -} - -DataArrayDouble *DataArrayDouble::performCpy(bool deepCpy) const -{ - if(deepCpy) - return deepCopy(); - else - { - incrRef(); - return const_cast(this); - } -} - -void DataArrayDouble::alloc(int nbOfTuple, int nbOfCompo) -{ - _nb_of_tuples=nbOfTuple; - _info_on_compo.resize(nbOfCompo); - _mem.alloc(nbOfCompo*_nb_of_tuples); - declareAsNew(); -} - -bool DataArrayDouble::isEqual(const DataArrayDouble& other, double prec) const -{ - if(!areInfoEquals(other)) - return false; - return _mem.isEqual(other._mem,prec); -} - -void DataArrayDouble::reAlloc(int nbOfTuples) -{ - _mem.reAlloc(_info_on_compo.size()*nbOfTuples); - _nb_of_tuples=nbOfTuples; - declareAsNew(); -} - -void DataArrayDouble::setArrayIn(DataArrayDouble *newArray, DataArrayDouble* &arrayToSet) -{ - if(newArray!=arrayToSet) - { - if(arrayToSet) - arrayToSet->decrRef(); - arrayToSet=newArray; - if(arrayToSet) - arrayToSet->incrRef(); - } -} - -void DataArrayDouble::useArray(const double *array, bool ownership, DeallocType type, int nbOfTuple, int nbOfCompo) -{ - _nb_of_tuples=nbOfTuple; - _info_on_compo.resize(nbOfCompo); - _mem.useArray(array,ownership,type,nbOfTuple*nbOfCompo); - declareAsNew(); -} - -DataArrayInt *DataArrayInt::New() -{ - return new DataArrayInt; -} - -DataArrayInt *DataArrayInt::deepCopy() const -{ - return new DataArrayInt(*this); -} - -DataArrayInt *DataArrayInt::performCpy(bool deepCpy) const -{ - if(deepCpy) - return deepCopy(); - else - { - incrRef(); - return const_cast(this); - } -} - -void DataArrayInt::alloc(int nbOfTuple, int nbOfCompo) -{ - _nb_of_tuples=nbOfTuple; - _info_on_compo.resize(nbOfCompo); - _mem.alloc(nbOfCompo*_nb_of_tuples); - declareAsNew(); -} - -bool DataArrayInt::isEqual(const DataArrayInt& other) const -{ - if(!areInfoEquals(other)) - return false; - return _mem.isEqual(other._mem,0); -} - -void DataArrayInt::useArray(const int *array, bool ownership, DeallocType type, int nbOfTuple, int nbOfCompo) -{ - _nb_of_tuples=nbOfTuple; - _info_on_compo.resize(nbOfCompo); - _mem.useArray(array,ownership,type,nbOfTuple*nbOfCompo); - declareAsNew(); -} - -void DataArrayInt::reAlloc(int nbOfTuples) -{ - _mem.reAlloc(_info_on_compo.size()*nbOfTuples); - _nb_of_tuples=nbOfTuples; - declareAsNew(); -} - -void DataArrayInt::setArrayIn(DataArrayInt *newArray, DataArrayInt* &arrayToSet) -{ - if(newArray!=arrayToSet) - { - if(arrayToSet) - arrayToSet->decrRef(); - arrayToSet=newArray; - if(arrayToSet) - arrayToSet->incrRef(); - } -} diff --git a/src/MEDCoupling/MEDCouplingMemArray.hxx b/src/MEDCoupling/MEDCouplingMemArray.hxx deleted file mode 100644 index 1865161d6..000000000 --- a/src/MEDCoupling/MEDCouplingMemArray.hxx +++ /dev/null @@ -1,155 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#ifndef __PARAMEDMEM_MEDCOUPLINGMEMARRAY_HXX__ -#define __PARAMEDMEM_MEDCOUPLINGMEMARRAY_HXX__ - -#include "MEDCoupling.hxx" -#include "MEDCouplingTimeLabel.hxx" -#include "MEDCouplingRefCountObject.hxx" -#include "InterpKernelException.hxx" - -#include -#include - -namespace ParaMEDMEM -{ - template - class MEDCouplingPointer - { - public: - MEDCouplingPointer():_internal(0),_external(0) { } - void null() { _internal=0; _external=0; } - bool isNull() const { return _internal==0 && _external==0; } - void setInternal(T *pointer); - void setExternal(const T *pointer); - const T *getConstPointer() const { if(_internal) return _internal; else return _external; } - const T *getConstPointerLoc(int offset) const { if(_internal) return _internal+offset; else return _external+offset; } - T *getPointer() const { if(_internal) return _internal; if(_external) throw INTERP_KERNEL::Exception("Trying to write on an external pointer."); else return 0; } - private: - T *_internal; - const T *_external; - }; - - template - class MemArray - { - public: - MemArray():_nb_of_elem(-1),_ownership(false),_dealloc(CPP_DEALLOC) { } - MemArray(const MemArray& other); - const T *getConstPointerLoc(int offset) const { return _pointer.getConstPointerLoc(offset); } - const T *getConstPointer() const { return _pointer.getConstPointer(); } - T *getPointer() const { return _pointer.getPointer(); } - MemArray &operator=(const MemArray& other); - T operator[](int id) const { return _pointer.getConstPointer()[id]; } - T& operator[](int id) { return _pointer.getPointer()[id]; } - bool isEqual(const MemArray& other, T prec) const; - void alloc(int nbOfElements); - void reAlloc(int newNbOfElements); - void useArray(const T *array, bool ownership, DeallocType type, int nbOfElem); - void writeOnPlace(int id, T element0, const T *others, int sizeOfOthers); - ~MemArray() { destroy(); } - private: - void destroy(); - static void destroyPointer(T *pt, DeallocType type); - private: - int _nb_of_elem; - bool _ownership; - MEDCouplingPointer _pointer; - //T *_pointer; - DeallocType _dealloc; - }; - - class MEDCOUPLING_EXPORT DataArray : public RefCountObject, public TimeLabel - { - public: - void setName(const char *name); - bool areInfoEquals(const DataArray& other) const; - std::string getName() const { return _name; } - std::string getInfoOnComponent(int i) const { return _info_on_compo[i]; } - void setInfoOnComponent(int i, const char *info) { _info_on_compo[i]=info; } - int getNumberOfComponents() const { return _info_on_compo.size(); } - int getNumberOfTuples() const { return _nb_of_tuples; } - int getNbOfElems() const { return _info_on_compo.size()*_nb_of_tuples; } - protected: - DataArray():_nb_of_tuples(-1) { } - protected: - int _nb_of_tuples; - std::string _name; - std::vector _info_on_compo; - }; -} - -#include "MEDCouplingMemArray.txx" - -namespace ParaMEDMEM -{ - class MEDCOUPLING_EXPORT DataArrayDouble : public DataArray - { - public: - static DataArrayDouble *New(); - DataArrayDouble *deepCopy() const; - DataArrayDouble *performCpy(bool deepCpy) const; - void alloc(int nbOfTuple, int nbOfCompo); - bool isEqual(const DataArrayDouble& other, double prec) const; - //!alloc or useArray should have been called before. - void reAlloc(int nbOfTuples); - void getTuple(int tupleId, double *res) const { std::copy(_mem.getConstPointerLoc(tupleId*_info_on_compo.size()),_mem.getConstPointerLoc((tupleId+1)*_info_on_compo.size()),res); } - double getIJ(int tupleId, int compoId) const { return _mem[tupleId*_info_on_compo.size()+compoId]; } - void setIJ(int tupleId, int compoId, double newVal) { _mem[tupleId*_info_on_compo.size()+compoId]=newVal; } - double *getPointer() const { return _mem.getPointer(); } - static void setArrayIn(DataArrayDouble *newArray, DataArrayDouble* &arrayToSet); - const double *getConstPointer() const { return _mem.getConstPointer(); } - void useArray(const double *array, bool ownership, DeallocType type, int nbOfTuple, int nbOfCompo); - void writeOnPlace(int id, double element0, const double *others, int sizeOfOthers) { _mem.writeOnPlace(id,element0,others,sizeOfOthers); } - //! nothing to do here because this class does not aggregate any TimeLabel instance. - void updateTime() { } - private: - DataArrayDouble() { } - private: - MemArray _mem; - }; - - class MEDCOUPLING_EXPORT DataArrayInt : public DataArray - { - public: - static DataArrayInt *New(); - DataArrayInt *deepCopy() const; - DataArrayInt *performCpy(bool deepCpy) const; - void alloc(int nbOfTuple, int nbOfCompo); - bool isEqual(const DataArrayInt& other) const; - //!alloc or useArray should have been called before. - void reAlloc(int nbOfTuples); - void getTuple(int tupleId, int *res) const { std::copy(_mem.getConstPointerLoc(tupleId*_info_on_compo.size()),_mem.getConstPointerLoc((tupleId+1)*_info_on_compo.size()),res); } - int getIJ(int tupleId, int compoId) const { return _mem[tupleId*_info_on_compo.size()+compoId]; } - void setIJ(int tupleId, int compoId, int newVal) { _mem[tupleId*_info_on_compo.size()+compoId]=newVal; } - int *getPointer() const { return _mem.getPointer(); } - static void setArrayIn(DataArrayInt *newArray, DataArrayInt* &arrayToSet); - const int *getConstPointer() const { return _mem.getConstPointer(); } - void useArray(const int *array, bool ownership, DeallocType type, int nbOfTuple, int nbOfCompo); - void writeOnPlace(int id, int element0, const int *others, int sizeOfOthers) { _mem.writeOnPlace(id,element0,others,sizeOfOthers); } - //! nothing to do here because this class does not aggregate any TimeLabel instance. - void updateTime() { } - private: - DataArrayInt() { } - private: - MemArray _mem; - }; -} - -#endif diff --git a/src/MEDCoupling/MEDCouplingMemArray.txx b/src/MEDCoupling/MEDCouplingMemArray.txx deleted file mode 100644 index 8d6a8191f..000000000 --- a/src/MEDCoupling/MEDCouplingMemArray.txx +++ /dev/null @@ -1,159 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#ifndef __PARAMEDMEM_MEDCOUPLINGMEMARRAY_TXX__ -#define __PARAMEDMEM_MEDCOUPLINGMEMARRAY_TXX__ - -#include "MEDCouplingMemArray.hxx" -#include "NormalizedUnstructuredMesh.hxx" -#include "InterpKernelException.hxx" - -#include -#include - -namespace ParaMEDMEM -{ - template - void MEDCouplingPointer::setInternal(T *pointer) - { - _internal=pointer; - _external=0; - } - - template - void MEDCouplingPointer::setExternal(const T *pointer) - { - _external=pointer; - _internal=0; - } - - template - MemArray::MemArray(const MemArray& other):_nb_of_elem(-1),_ownership(false),_dealloc(CPP_DEALLOC) - { - if(!other._pointer.isNull()) - { - T *pointer=new T[other._nb_of_elem]; - std::copy(other._pointer.getConstPointer(),other._pointer.getConstPointer()+other._nb_of_elem,pointer); - useArray(pointer,true,CPP_DEALLOC,other._nb_of_elem); - } - } - - template - void MemArray::useArray(const T *array, bool ownership, DeallocType type, int nbOfElem) - { - _nb_of_elem=nbOfElem; - destroy(); - if(ownership) - _pointer.setInternal((T *)array); - else - _pointer.setExternal(array); - _ownership=ownership; - _dealloc=type; - } - - template - void MemArray::writeOnPlace(int id, T element0, const T *others, int sizeOfOthers) - { - if(id+sizeOfOthers>=_nb_of_elem) - reAlloc(2*_nb_of_elem+sizeOfOthers+1); - T *pointer=_pointer.getPointer(); - pointer[id]=element0; - std::copy(others,others+sizeOfOthers,pointer+id+1); - } - - template - bool MemArray::isEqual(const MemArray& other, T prec) const - { - if(_nb_of_elem!=other._nb_of_elem) - return false; - const T *pt1=_pointer.getConstPointer(); - const T *pt2=other._pointer.getConstPointer(); - if(pt1==0 && pt2==0) - return true; - if(pt1==0 || pt2==0) - return false; - for(int i=0;i<_nb_of_elem;i++) - if(pt1[i]-pt2[i]<-prec || (pt1[i]-pt2[i])>prec) - return false; - return true; - } - - template - void MemArray::alloc(int nbOfElements) - { - destroy(); - _nb_of_elem=nbOfElements; - _pointer.setInternal(new T[_nb_of_elem]); - _ownership=true; - _dealloc=CPP_DEALLOC; - } - - template - void MemArray::reAlloc(int newNbOfElements) - { - T *pointer=new T[newNbOfElements]; - std::copy(_pointer.getConstPointer(),_pointer.getConstPointer()+std::min(_nb_of_elem,newNbOfElements),pointer); - if(_ownership) - destroyPointer((T *)_pointer.getConstPointer(),_dealloc); - _pointer.setInternal(pointer); - _nb_of_elem=newNbOfElements; - _ownership=true; - _dealloc=CPP_DEALLOC; - } - - template - void MemArray::destroyPointer(T *pt, DeallocType type) - { - switch(type) - { - case CPP_DEALLOC: - { - delete [] pt; - return ; - } - case C_DEALLOC: - { - free(pt); - return ; - } - default: - std::stringstream stream; - stream << "Invalid deallocation requested for pointer " << pt; - throw INTERP_KERNEL::Exception(stream.str().c_str()); - } - } - - template - void MemArray::destroy() - { - if(_ownership) - destroyPointer((T *)_pointer.getConstPointer(),_dealloc); - _pointer.null(); - _ownership=false; - } - - template - MemArray &MemArray::operator=(const MemArray& other) - { - alloc(other._nb_of_elem); - std::copy(other._pointer.getConstPointer(),other._pointer.getConstPointer()+_nb_of_elem,_pointer.getPointer()); - return *this; - } -} - -#endif diff --git a/src/MEDCoupling/MEDCouplingNatureOfField.hxx b/src/MEDCoupling/MEDCouplingNatureOfField.hxx deleted file mode 100644 index baffb734d..000000000 --- a/src/MEDCoupling/MEDCouplingNatureOfField.hxx +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#ifndef __MEDCOUPLINGNATUREOFFIELD_HXX__ -#define __MEDCOUPLINGNATUREOFFIELD_HXX__ - -namespace ParaMEDMEM -{ - typedef enum - { - NoNature = 17, - ConservativeVolumic = 26, - Integral = 32, - IntegralGlobConstraint = 35 - } NatureOfField; -} - -#endif diff --git a/src/MEDCoupling/MEDCouplingPointSet.cxx b/src/MEDCoupling/MEDCouplingPointSet.cxx deleted file mode 100644 index 3a2876ae7..000000000 --- a/src/MEDCoupling/MEDCouplingPointSet.cxx +++ /dev/null @@ -1,323 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#include "MEDCouplingPointSet.hxx" -#include "MEDCouplingUMesh.hxx" -#include "MEDCouplingUMeshDesc.hxx" -#include "MEDCouplingMemArray.hxx" - -#include -#include -#include - -using namespace ParaMEDMEM; - -MEDCouplingPointSet::MEDCouplingPointSet():_coords(0) -{ -} - -MEDCouplingPointSet::MEDCouplingPointSet(const MEDCouplingPointSet& other, bool deepCpy):MEDCouplingMesh(other),_coords(0) -{ - if(other._coords) - _coords=other._coords->performCpy(deepCpy); -} - -MEDCouplingPointSet::~MEDCouplingPointSet() -{ - if(_coords) - _coords->decrRef(); -} - -int MEDCouplingPointSet::getNumberOfNodes() const -{ - if(_coords) - return _coords->getNumberOfTuples(); - else - throw INTERP_KERNEL::Exception("Unable to get number of nodes because no coordinates specified !"); -} - -int MEDCouplingPointSet::getSpaceDimension() const -{ - if(_coords) - return _coords->getNumberOfComponents(); - else - throw INTERP_KERNEL::Exception("Unable to get space dimension because no coordinates specified !"); -} - -void MEDCouplingPointSet::updateTime() -{ - if(_coords) - { - updateTimeWith(*_coords); - } -} - -bool MEDCouplingPointSet::isStructured() const -{ - return false; -} - -void MEDCouplingPointSet::setCoords(DataArrayDouble *coords) -{ - if( coords != _coords ) - { - if (_coords) - _coords->decrRef(); - _coords=coords; - if(_coords) - _coords->incrRef(); - declareAsNew(); - } -} - -bool MEDCouplingPointSet::areCoordsEqual(const MEDCouplingPointSet& other, double prec) const -{ - if(_coords==0 && other._coords==0) - return true; - if(_coords==0 || other._coords==0) - return false; - if(_coords==other._coords) - return true; - return _coords->isEqual(*other._coords,prec); -} - -void MEDCouplingPointSet::getBoundingBox(double *bbox) const -{ - int dim=getSpaceDimension(); - for (int idim=0; idim::max(); - bbox[idim*2+1]=-std::numeric_limits::max(); - } - const double *coords=_coords->getConstPointer(); - int nbnodes=getNumberOfNodes(); - for (int i=0; i coords[i*dim+idim] ) - { - bbox[idim*2] = coords[i*dim+idim] ; - } - if ( bbox[idim*2+1] < coords[i*dim+idim] ) - { - bbox[idim*2+1] = coords[i*dim+idim] ; - } - } - } -} - -void MEDCouplingPointSet::zipCoords() -{ - checkFullyDefined(); - DataArrayInt *traducer=zipCoordsTraducer(); - traducer->decrRef(); -} - -void MEDCouplingPointSet::rotate(const double *center, const double *vector, double angle) -{ - int spaceDim=getSpaceDimension(); - if(spaceDim==3) - rotate3D(center,vector,angle); - else if(spaceDim==2) - rotate2D(center,angle); - else - throw INTERP_KERNEL::Exception("MEDCouplingPointSet::rotate : invalid space dim for rotation must be 2 or 3"); - _coords->declareAsNew(); - updateTime(); -} - -void MEDCouplingPointSet::translate(const double *vector) -{ - double *coords=_coords->getPointer(); - int nbNodes=getNumberOfNodes(); - int dim=getSpaceDimension(); - for(int i=0; ideclareAsNew(); - updateTime(); -} - -MEDCouplingPointSet *MEDCouplingPointSet::buildInstanceFromMeshType(MEDCouplingMeshType type) -{ - switch(type) - { - case UNSTRUCTURED: - return MEDCouplingUMesh::New(); - case UNSTRUCTURED_DESC: - return MEDCouplingUMeshDesc::New(); - default: - throw INTERP_KERNEL::Exception("Invalid type of mesh specified"); - } -} - -void MEDCouplingPointSet::getTinySerializationInformation(std::vector& tinyInfo, std::vector& littleStrings) const -{ - if(_coords) - { - int spaceDim=getSpaceDimension(); - littleStrings.resize(spaceDim+1); - littleStrings[0]=getName(); - for(int i=0;igetInfoOnComponent(i); - tinyInfo.clear(); - tinyInfo.push_back(getType()); - tinyInfo.push_back(spaceDim); - tinyInfo.push_back(getNumberOfNodes()); - } - else - { - littleStrings.resize(1); - littleStrings[0]=getName(); - tinyInfo.clear(); - tinyInfo.push_back(getType()); - tinyInfo.push_back(-1); - tinyInfo.push_back(-1); - } -} - -void MEDCouplingPointSet::serialize(DataArrayInt *&a1, DataArrayDouble *&a2) const -{ - if(_coords) - { - a2=getCoords(); - a2->incrRef(); - } - else - a2=0; -} - -void MEDCouplingPointSet::resizeForUnserialization(const std::vector& tinyInfo, DataArrayInt *a1, DataArrayDouble *a2, std::vector& littleStrings) -{ - if(tinyInfo[2]>=0 && tinyInfo[1]>=1) - { - a2->alloc(tinyInfo[2],tinyInfo[1]); - littleStrings.resize(tinyInfo[1]+1); - } - else - { - littleStrings.resize(1); - } -} - -void MEDCouplingPointSet::unserialization(const std::vector& tinyInfo, DataArrayInt *a1, DataArrayDouble *a2, const std::vector& littleStrings) -{ - if(tinyInfo[2]>=0 && tinyInfo[1]>=1) - { - setCoords(a2); - setName(littleStrings[0].c_str()); - for(int i=0;isetInfoOnComponent(i,littleStrings[i+1].c_str()); - } - else - setName(littleStrings[0].c_str()); -} - -// ============================================= -// Intersect Bounding Box given 2 Bounding Boxes -// ============================================= -bool MEDCouplingPointSet::intersectsBoundingBox(const double* bb1, const double* bb2, int dim, double eps) -{ - double* bbtemp = new double[2*dim]; - double deltamax=0.0; - - for (int i=0; i< dim; i++) - { - double delta = bb1[2*i+1]-bb1[2*i]; - if ( delta > deltamax ) - { - deltamax = delta ; - } - } - for (int i=0; i(),1/norm)); - //rotation matrix computation - matrix[0]=cosa; matrix[1]=0.; matrix[2]=0.; matrix[3]=0.; matrix[4]=cosa; matrix[5]=0.; matrix[6]=0.; matrix[7]=0.; matrix[8]=cosa; - matrixTmp[0]=vectorNorm[0]*vectorNorm[0]; matrixTmp[1]=vectorNorm[0]*vectorNorm[1]; matrixTmp[2]=vectorNorm[0]*vectorNorm[2]; - matrixTmp[3]=vectorNorm[1]*vectorNorm[0]; matrixTmp[4]=vectorNorm[1]*vectorNorm[1]; matrixTmp[5]=vectorNorm[1]*vectorNorm[2]; - matrixTmp[6]=vectorNorm[2]*vectorNorm[0]; matrixTmp[7]=vectorNorm[2]*vectorNorm[1]; matrixTmp[8]=vectorNorm[2]*vectorNorm[2]; - std::transform(matrixTmp,matrixTmp+9,matrixTmp,std::bind2nd(std::multiplies(),1-cosa)); - std::transform(matrix,matrix+9,matrixTmp,matrix,std::plus()); - matrixTmp[0]=0.; matrixTmp[1]=-vectorNorm[2]; matrixTmp[2]=vectorNorm[1]; - matrixTmp[3]=vectorNorm[2]; matrixTmp[4]=0.; matrixTmp[5]=-vectorNorm[0]; - matrixTmp[6]=-vectorNorm[1]; matrixTmp[7]=vectorNorm[0]; matrixTmp[8]=0.; - std::transform(matrixTmp,matrixTmp+9,matrixTmp,std::bind2nd(std::multiplies(),sina)); - std::transform(matrix,matrix+9,matrixTmp,matrix,std::plus()); - //rotation matrix computed. - double *coords=_coords->getPointer(); - int nbNodes=getNumberOfNodes(); - double tmp[3]; - for(int i=0; i()); - coords[i*3]=matrix[0]*tmp[0]+matrix[1]*tmp[1]+matrix[2]*tmp[2]+center[0]; - coords[i*3+1]=matrix[3]*tmp[0]+matrix[4]*tmp[1]+matrix[5]*tmp[2]+center[1]; - coords[i*3+2]=matrix[6]*tmp[0]+matrix[7]*tmp[1]+matrix[8]*tmp[2]+center[2]; - } -} - -/*! - * 'This' is expected to be of spaceDim==2. Idem for 'center' and 'vect' - */ -void MEDCouplingPointSet::rotate2D(const double *center, double angle) -{ - double cosa=cos(angle); - double sina=sin(angle); - double matrix[4]; - matrix[0]=cosa; matrix[1]=-sina; matrix[2]=sina; matrix[3]=cosa; - double *coords=_coords->getPointer(); - int nbNodes=getNumberOfNodes(); - double tmp[2]; - for(int i=0; i()); - coords[i*2]=matrix[0]*tmp[0]+matrix[1]*tmp[1]+center[0]; - coords[i*2+1]=matrix[2]*tmp[0]+matrix[3]*tmp[1]+center[1]; - } -} diff --git a/src/MEDCoupling/MEDCouplingPointSet.hxx b/src/MEDCoupling/MEDCouplingPointSet.hxx deleted file mode 100644 index e79f7b20b..000000000 --- a/src/MEDCoupling/MEDCouplingPointSet.hxx +++ /dev/null @@ -1,72 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#ifndef __PARAMEDMEM_MEDCOUPLINGPOINTSET_HXX__ -#define __PARAMEDMEM_MEDCOUPLINGPOINTSET_HXX__ - -#include "MEDCoupling.hxx" -#include "MEDCouplingMesh.hxx" - -#include - -namespace ParaMEDMEM -{ - class DataArrayInt; - class DataArrayDouble; - - class MEDCOUPLING_EXPORT MEDCouplingPointSet : public MEDCouplingMesh - { - protected: - MEDCouplingPointSet(); - MEDCouplingPointSet(const MEDCouplingPointSet& other, bool deepCpy); - ~MEDCouplingPointSet(); - public: - void updateTime(); - bool isStructured() const; - int getNumberOfNodes() const; - int getSpaceDimension() const; - void setCoords(DataArrayDouble *coords); - DataArrayDouble *getCoords() const { return _coords; } - bool areCoordsEqual(const MEDCouplingPointSet& other, double prec) const; - void getBoundingBox(double *bbox) const; - void zipCoords(); - void rotate(const double *center, const double *vector, double angle); - void translate(const double *vector); - static MEDCouplingPointSet *buildInstanceFromMeshType(MEDCouplingMeshType type); - virtual MEDCouplingPointSet *buildPartOfMySelf(const int *start, const int *end, bool keepCoords) const = 0; - virtual MEDCouplingPointSet *buildPartOfMySelfNode(const int *start, const int *end, bool fullyIn) const = 0; - virtual void renumberConnectivity(const int *newNodeNumbers) = 0; - //! size of returned tinyInfo must be always the same. - virtual void getTinySerializationInformation(std::vector& tinyInfo, std::vector& littleStrings) const; - virtual void resizeForUnserialization(const std::vector& tinyInfo, DataArrayInt *a1, DataArrayDouble *a2, std::vector& littleStrings); - virtual void serialize(DataArrayInt *&a1, DataArrayDouble *&a2) const; - virtual void unserialization(const std::vector& tinyInfo, DataArrayInt *a1, DataArrayDouble *a2, - const std::vector& littleStrings); - virtual void giveElemsInBoundingBox(const double *bbox, double eps, std::vector& elems) = 0; - virtual DataArrayInt *zipCoordsTraducer() = 0; - protected: - virtual void checkFullyDefined() const throw(INTERP_KERNEL::Exception) = 0; - static bool intersectsBoundingBox(const double* bb1, const double* bb2, int dim, double eps); - void rotate2D(const double *center, double angle); - void rotate3D(const double *center, const double *vect, double angle); - protected: - DataArrayDouble *_coords; - }; -} - -#endif diff --git a/src/MEDCoupling/MEDCouplingRefCountObject.cxx b/src/MEDCoupling/MEDCouplingRefCountObject.cxx deleted file mode 100644 index c9825ed53..000000000 --- a/src/MEDCoupling/MEDCouplingRefCountObject.cxx +++ /dev/null @@ -1,46 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#include "MEDCouplingRefCountObject.hxx" - -using namespace ParaMEDMEM; - -RefCountObject::RefCountObject():_cnt(1) -{ -} - -RefCountObject::RefCountObject(const RefCountObject& other):_cnt(1) -{ -} - -bool RefCountObject::decrRef() -{ - bool ret=((--_cnt)==0); - if(ret) - delete this; - return ret; -} - -void RefCountObject::incrRef() const -{ - _cnt++; -} - -RefCountObject::~RefCountObject() -{ -} diff --git a/src/MEDCoupling/MEDCouplingRefCountObject.hxx b/src/MEDCoupling/MEDCouplingRefCountObject.hxx deleted file mode 100644 index d6ec6da01..000000000 --- a/src/MEDCoupling/MEDCouplingRefCountObject.hxx +++ /dev/null @@ -1,60 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#ifndef __PARAMEDMEM_MEDCOUPLINGREFCOUNTOBJECT_HXX__ -#define __PARAMEDMEM_MEDCOUPLINGREFCOUNTOBJECT_HXX__ - -#include "MEDCoupling.hxx" - -namespace ParaMEDMEM -{ - typedef enum - { - C_DEALLOC = 2, - CPP_DEALLOC = 3 - } DeallocType; - - typedef enum - { - ON_CELLS = 0, - ON_NODES = 1 - } TypeOfField; - - typedef enum - { - NO_TIME = 4, - ONE_TIME = 5, - LINEAR_TIME = 6 - } TypeOfTimeDiscretization; - - class MEDCOUPLING_EXPORT RefCountObject - { - protected: - RefCountObject(); - RefCountObject(const RefCountObject& other); - public: - bool decrRef(); - void incrRef() const; - protected: - virtual ~RefCountObject(); - private: - mutable int _cnt; - }; -} - -#endif diff --git a/src/MEDCoupling/MEDCouplingTimeDiscretization.cxx b/src/MEDCoupling/MEDCouplingTimeDiscretization.cxx deleted file mode 100644 index 6c75e607c..000000000 --- a/src/MEDCoupling/MEDCouplingTimeDiscretization.cxx +++ /dev/null @@ -1,403 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#include "MEDCouplingTimeDiscretization.hxx" -#include "MEDCouplingMemArray.hxx" - -#include - -using namespace ParaMEDMEM; - -const char MEDCouplingNoTimeLabel::EXCEPTION_MSG[]="MEDCouplingNoTimeLabel::setTime : no time info attached."; - -const char MEDCouplingWithTimeStep::EXCEPTION_MSG[]="No data on this time."; - -const double MEDCouplingTimeDiscretization::TIME_TOLERANCE_DFT=1.e-12; - -MEDCouplingTimeDiscretization *MEDCouplingTimeDiscretization::New(TypeOfTimeDiscretization type) -{ - switch(type) - { - case MEDCouplingNoTimeLabel::DISCRETIZATION: - return new MEDCouplingNoTimeLabel; - case MEDCouplingWithTimeStep::DISCRETIZATION: - return new MEDCouplingWithTimeStep; - default: - throw INTERP_KERNEL::Exception("Time discretization not implemented yet"); - } -} - -bool MEDCouplingTimeDiscretization::isEqual(const MEDCouplingTimeDiscretization *other, double prec) const -{ - if(std::fabs(_time_tolerance-other->_time_tolerance)>1.e-16) - return false; - if(_array==0 && other->_array==0) - return true; - if(_array==0 || other->_array==0) - return false; - if(_array==other->_array) - return true; - return _array->isEqual(*other->_array,prec); -} - -void MEDCouplingTimeDiscretization::getTinySerializationIntInformation(std::vector& tinyInfo) const -{ - if(_array) - { - tinyInfo.push_back(_array->getNumberOfTuples()); - tinyInfo.push_back(_array->getNumberOfComponents()); - } - else - { - tinyInfo.push_back(-1); - tinyInfo.push_back(-1); - } -} - -void MEDCouplingTimeDiscretization::resizeForUnserialization(const std::vector& tinyInfoI, std::vector& arrays) -{ - arrays.resize(1); - if(_array!=0) - _array->decrRef(); - DataArrayDouble *arr=0; - if(tinyInfoI[0]!=-1 && tinyInfoI[1]!=-1) - { - arr=DataArrayDouble::New(); - arr->alloc(tinyInfoI[0],tinyInfoI[1]); - } - _array=arr; - arrays[0]=arr; -} - -void MEDCouplingTimeDiscretization::finishUnserialization(const std::vector& tinyInfoI, const std::vector& tinyInfoD, const std::vector& tinyInfoS) -{ - _time_tolerance=tinyInfoD[0]; - int nbOfCompo=_array->getNumberOfComponents(); - for(int i=0;isetInfoOnComponent(i,tinyInfoS[i].c_str()); -} - -void MEDCouplingTimeDiscretization::getTinySerializationDbleInformation(std::vector& tinyInfo) const -{ - tinyInfo.push_back(_time_tolerance); -} - -void MEDCouplingTimeDiscretization::getTinySerializationStrInformation(std::vector& tinyInfo) const -{ - int nbOfCompo=_array->getNumberOfComponents(); - for(int i=0;igetInfoOnComponent(i)); -} - -MEDCouplingTimeDiscretization::MEDCouplingTimeDiscretization():_time_tolerance(TIME_TOLERANCE_DFT),_array(0) -{ -} - -MEDCouplingTimeDiscretization::MEDCouplingTimeDiscretization(const MEDCouplingTimeDiscretization& other, bool deepCpy):_time_tolerance(other._time_tolerance) -{ - if(other._array) - _array=other._array->performCpy(deepCpy); - else - _array=0; -} - -MEDCouplingTimeDiscretization::~MEDCouplingTimeDiscretization() -{ - if(_array) - _array->decrRef(); -} - -void MEDCouplingTimeDiscretization::setArray(DataArrayDouble *array, TimeLabel *owner) -{ - if(array!=_array) - { - if(_array) - _array->decrRef(); - _array=array; - if(_array) - _array->incrRef(); - owner->declareAsNew(); - } -} - -void MEDCouplingTimeDiscretization::setArrays(const std::vector& arrays, TimeLabel *owner) throw(INTERP_KERNEL::Exception) -{ - if(arrays.size()!=1) - throw INTERP_KERNEL::Exception("MEDCouplingTimeDiscretization::setArrays : number of arrays must be one."); - setArray(arrays.back(),owner); -} - -void MEDCouplingTimeDiscretization::getArrays(std::vector& arrays) const -{ - arrays.resize(1); - arrays[0]=_array; -} - -bool MEDCouplingTimeDiscretization::isBefore(const MEDCouplingTimeDiscretization *other) const throw(INTERP_KERNEL::Exception) -{ - int dt,it; - double time1=getEndTime(dt,it)-_time_tolerance; - double time2=other->getStartTime(dt,it)+other->getTimeTolerance(); - return time1<=time2; -} - -bool MEDCouplingTimeDiscretization::isStrictlyBefore(const MEDCouplingTimeDiscretization *other) const throw(INTERP_KERNEL::Exception) -{ - int dt,it; - double time1=getEndTime(dt,it)+_time_tolerance; - double time2=other->getStartTime(dt,it)-other->getTimeTolerance(); - return time1(other); - if(!otherC) - return false; - return MEDCouplingTimeDiscretization::isEqual(other,prec); -} - -MEDCouplingTimeDiscretization *MEDCouplingNoTimeLabel::performCpy(bool deepCpy) const -{ - return new MEDCouplingNoTimeLabel(*this,deepCpy); -} - -void MEDCouplingNoTimeLabel::checkTimePresence(double time) const throw(INTERP_KERNEL::Exception) -{ - throw INTERP_KERNEL::Exception(EXCEPTION_MSG); -} - -DataArrayDouble *MEDCouplingNoTimeLabel::getArrayOnTime(double time) const throw(INTERP_KERNEL::Exception) -{ - throw INTERP_KERNEL::Exception(EXCEPTION_MSG); -} - -bool MEDCouplingNoTimeLabel::isBefore(const MEDCouplingTimeDiscretization *other) const throw(INTERP_KERNEL::Exception) -{ - throw INTERP_KERNEL::Exception(EXCEPTION_MSG); -} - -bool MEDCouplingNoTimeLabel::isStrictlyBefore(const MEDCouplingTimeDiscretization *other) const throw(INTERP_KERNEL::Exception) -{ - throw INTERP_KERNEL::Exception(EXCEPTION_MSG); -} - -double MEDCouplingNoTimeLabel::getStartTime(int& dt, int& it) const throw(INTERP_KERNEL::Exception) -{ - throw INTERP_KERNEL::Exception(EXCEPTION_MSG); -} - -double MEDCouplingNoTimeLabel::getEndTime(int& dt, int& it) const throw(INTERP_KERNEL::Exception) -{ - throw INTERP_KERNEL::Exception(EXCEPTION_MSG); -} - -void MEDCouplingNoTimeLabel::setStartTime(double time, int dt, int it) throw(INTERP_KERNEL::Exception) -{ - throw INTERP_KERNEL::Exception(EXCEPTION_MSG); -} - -void MEDCouplingNoTimeLabel::setEndTime(double time, int dt, int it) throw(INTERP_KERNEL::Exception) -{ - throw INTERP_KERNEL::Exception(EXCEPTION_MSG); -} - -void MEDCouplingNoTimeLabel::getValueOnTime(int eltId, double time, double *value) const throw(INTERP_KERNEL::Exception) -{ - throw INTERP_KERNEL::Exception(EXCEPTION_MSG); -} - -void MEDCouplingNoTimeLabel::getValueOnDiscTime(int eltId, int dt, int it, double *value) const throw(INTERP_KERNEL::Exception) -{ - throw INTERP_KERNEL::Exception(EXCEPTION_MSG); -} - -MEDCouplingWithTimeStep::MEDCouplingWithTimeStep(const MEDCouplingWithTimeStep& other, bool deepCpy):MEDCouplingTimeDiscretization(other,deepCpy), - _time(other._time),_dt(other._dt),_it(other._it) -{ -} - -MEDCouplingWithTimeStep::MEDCouplingWithTimeStep():_time(0.),_dt(-1),_it(-1) -{ -} - -void MEDCouplingWithTimeStep::getTinySerializationIntInformation(std::vector& tinyInfo) const -{ - MEDCouplingTimeDiscretization::getTinySerializationIntInformation(tinyInfo); - tinyInfo.push_back(_dt); - tinyInfo.push_back(_it); -} - -void MEDCouplingWithTimeStep::getTinySerializationDbleInformation(std::vector& tinyInfo) const -{ - MEDCouplingTimeDiscretization::getTinySerializationDbleInformation(tinyInfo); - tinyInfo.push_back(_time); -} - -void MEDCouplingWithTimeStep::finishUnserialization(const std::vector& tinyInfoI, const std::vector& tinyInfoD, const std::vector& tinyInfoS) -{ - MEDCouplingTimeDiscretization::finishUnserialization(tinyInfoI,tinyInfoD,tinyInfoS); - _time=tinyInfoD[1]; - _dt=tinyInfoI[2]; - _it=tinyInfoI[3]; -} - -bool MEDCouplingWithTimeStep::isEqual(const MEDCouplingTimeDiscretization *other, double prec) const -{ - const MEDCouplingWithTimeStep *otherC=dynamic_cast(other); - if(!otherC) - return false; - if(_dt!=otherC->_dt) - return false; - if(_it!=otherC->_it) - return false; - if(std::fabs(_time-otherC->_time)>_time_tolerance) - return false; - return MEDCouplingTimeDiscretization::isEqual(other,prec); -} - -MEDCouplingTimeDiscretization *MEDCouplingWithTimeStep::performCpy(bool deepCpy) const -{ - return new MEDCouplingWithTimeStep(*this,deepCpy); -} - -void MEDCouplingWithTimeStep::checkNoTimePresence() const throw(INTERP_KERNEL::Exception) -{ - throw INTERP_KERNEL::Exception("No time specified on a field defined on one time"); -} - -void MEDCouplingWithTimeStep::checkTimePresence(double time) const throw(INTERP_KERNEL::Exception) -{ - if(std::fabs(time-_time)>_time_tolerance) - { - std::ostringstream stream; - stream << "The field is defined on time " << _time << " with eps=" << _time_tolerance << " and asking time = " << time << " !"; - throw INTERP_KERNEL::Exception(stream.str().c_str()); - } -} - -DataArrayDouble *MEDCouplingWithTimeStep::getArrayOnTime(double time) const throw(INTERP_KERNEL::Exception) -{ - if(std::fabs(time-_time)<=_time_tolerance) - { - if(_array) - _array->incrRef(); - return _array; - } - else - throw INTERP_KERNEL::Exception(EXCEPTION_MSG); -} - -void MEDCouplingWithTimeStep::getValueOnTime(int eltId, double time, double *value) const throw(INTERP_KERNEL::Exception) -{ - if(std::fabs(time-_time)<=_time_tolerance) - if(_array) - _array->getTuple(eltId,value); - else - throw INTERP_KERNEL::Exception("No array existing."); - else - throw INTERP_KERNEL::Exception(EXCEPTION_MSG); -} - -void MEDCouplingWithTimeStep::getValueOnDiscTime(int eltId, int dt, int it, double *value) const throw(INTERP_KERNEL::Exception) -{ - if(_dt==dt && _it==it) - if(_array) - _array->getTuple(eltId,value); - else - throw INTERP_KERNEL::Exception("No array existing."); - else - throw INTERP_KERNEL::Exception("No data on this discrete time."); -} - -MEDCouplingTwoTimeSteps::MEDCouplingTwoTimeSteps():_start_time(0.),_end_time(0.),_start_dt(-1),_end_dt(-1),_start_it(-1),_end_it(-1),_end_array(0) -{ -} - -MEDCouplingTwoTimeSteps::~MEDCouplingTwoTimeSteps() -{ - if(_end_array) - _end_array->decrRef(); -} - -void MEDCouplingTwoTimeSteps::checkNoTimePresence() const throw(INTERP_KERNEL::Exception) -{ - throw INTERP_KERNEL::Exception("The field presents a time to be specified in every access !"); -} - -void MEDCouplingTwoTimeSteps::checkTimePresence(double time) const throw(INTERP_KERNEL::Exception) -{ - if(time<_start_time-_time_tolerance || time>_end_time+_time_tolerance) - { - std::ostringstream stream; - stream << "The field is defined between times " << _start_time << " and " << _end_time << " with tolerance "; - stream << _time_tolerance << " and trying to access on time = " << time; - throw INTERP_KERNEL::Exception(stream.str().c_str()); - } -} - -void MEDCouplingTwoTimeSteps::getArrays(std::vector& arrays) const -{ - arrays.resize(2); - arrays[0]=_array; - arrays[1]=_end_array; -} - -void MEDCouplingTwoTimeSteps::resizeForUnserialization(const std::vector& tinyInfoI, std::vector& arrays) -{ - arrays.resize(2); - if(_array!=0) - _array->decrRef(); - if(_end_array!=0) - _end_array->decrRef(); - DataArrayDouble *arr=0; - if(tinyInfoI[0]!=-1 && tinyInfoI[1]!=-1) - { - arr=DataArrayDouble::New(); - arr->alloc(tinyInfoI[0],tinyInfoI[1]); - } - _array=arr; - arrays[0]=arr; - arr=0; - if(tinyInfoI[2]!=-1 && tinyInfoI[3]!=-1) - { - arr=DataArrayDouble::New(); - arr->alloc(tinyInfoI[2],tinyInfoI[3]); - } - _end_array=arr; - arrays[1]=arr; -} - -void MEDCouplingTwoTimeSteps::finishUnserialization(const std::vector& tinyInfoI, const std::vector& tinyInfoD, const std::vector& tinyInfoS) -{ - MEDCouplingTimeDiscretization::finishUnserialization(tinyInfoI,tinyInfoD,tinyInfoS); - _start_time=tinyInfoD[1]; - _end_time=tinyInfoD[2]; - _start_dt=tinyInfoI[2]; - _end_dt=tinyInfoI[3]; - _start_it=tinyInfoI[4]; - _end_it=tinyInfoI[5]; -} diff --git a/src/MEDCoupling/MEDCouplingTimeDiscretization.hxx b/src/MEDCoupling/MEDCouplingTimeDiscretization.hxx deleted file mode 100644 index 6764689ff..000000000 --- a/src/MEDCoupling/MEDCouplingTimeDiscretization.hxx +++ /dev/null @@ -1,167 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#ifndef __MEDCOUPLINGTIMEDISCRETIZATION_HXX__ -#define __MEDCOUPLINGTIMEDISCRETIZATION_HXX__ - -#include "MEDCoupling.hxx" -#include "MEDCouplingRefCountObject.hxx" -#include "InterpKernelException.hxx" - -#include - -namespace ParaMEDMEM -{ - class DataArrayDouble; - class TimeLabel; - - class MEDCOUPLING_EXPORT MEDCouplingTimeDiscretization - { - protected: - MEDCouplingTimeDiscretization(); - MEDCouplingTimeDiscretization(const MEDCouplingTimeDiscretization& other, bool deepCpy); - public: - static MEDCouplingTimeDiscretization *New(TypeOfTimeDiscretization type); - virtual bool isEqual(const MEDCouplingTimeDiscretization *other, double prec) const; - virtual TypeOfTimeDiscretization getEnum() const = 0; - virtual void getTinySerializationIntInformation(std::vector& tinyInfo) const; - virtual void getTinySerializationDbleInformation(std::vector& tinyInfo) const; - virtual void getTinySerializationStrInformation(std::vector& tinyInfo) const; - virtual void resizeForUnserialization(const std::vector& tinyInfoI, std::vector& arrays); - virtual void finishUnserialization(const std::vector& tinyInfoI, const std::vector& tinyInfoD, const std::vector& tinyInfoS); - virtual MEDCouplingTimeDiscretization *performCpy(bool deepCpy) const = 0; - void setTimeTolerance(double val); - double getTimeTolerance() const { return _time_tolerance; } - virtual void checkNoTimePresence() const throw(INTERP_KERNEL::Exception) = 0; - virtual void checkTimePresence(double time) const throw(INTERP_KERNEL::Exception) = 0; - virtual void setArray(DataArrayDouble *array, TimeLabel *owner); - virtual void setArrays(const std::vector& arrays, TimeLabel *owner) throw(INTERP_KERNEL::Exception); - DataArrayDouble *getArray() const { return _array; } - virtual DataArrayDouble *getEndArray() const { return _array; } - //! Warning contrary to getArray method this method returns an object to deal with. - virtual DataArrayDouble *getArrayOnTime(double time) const throw(INTERP_KERNEL::Exception) = 0; - virtual void getArrays(std::vector& arrays) const; - virtual bool isBefore(const MEDCouplingTimeDiscretization *other) const throw(INTERP_KERNEL::Exception); - virtual bool isStrictlyBefore(const MEDCouplingTimeDiscretization *other) const throw(INTERP_KERNEL::Exception); - double getTime(int& dt, int& it) const throw(INTERP_KERNEL::Exception) { return getStartTime(dt,it); } - virtual double getStartTime(int& dt, int& it) const throw(INTERP_KERNEL::Exception) = 0; - virtual double getEndTime(int& dt, int& it) const throw(INTERP_KERNEL::Exception) = 0; - void setTime(double time, int dt, int it) throw(INTERP_KERNEL::Exception) { setStartTime(time,dt,it); } - virtual void setStartTime(double time, int dt, int it) throw(INTERP_KERNEL::Exception) = 0; - virtual void setEndTime(double time, int dt, int it) throw(INTERP_KERNEL::Exception) = 0; - virtual void getValueOnTime(int eltId, double time, double *value) const throw(INTERP_KERNEL::Exception) = 0; - virtual void getValueOnDiscTime(int eltId, int dt, int it, double *value) const throw(INTERP_KERNEL::Exception) = 0; - virtual ~MEDCouplingTimeDiscretization(); - protected: - double _time_tolerance; - DataArrayDouble *_array; - protected: - static const double TIME_TOLERANCE_DFT; - }; - - class MEDCOUPLING_EXPORT MEDCouplingNoTimeLabel : public MEDCouplingTimeDiscretization - { - public: - MEDCouplingNoTimeLabel(); - MEDCouplingNoTimeLabel(const MEDCouplingTimeDiscretization& other, bool deepCpy); - TypeOfTimeDiscretization getEnum() const { return DISCRETIZATION; } - bool isEqual(const MEDCouplingTimeDiscretization *other, double prec) const; - MEDCouplingTimeDiscretization *performCpy(bool deepCpy) const; - void checkNoTimePresence() const throw(INTERP_KERNEL::Exception) { } - void checkTimePresence(double time) const throw(INTERP_KERNEL::Exception); - DataArrayDouble *getArrayOnTime(double time) const throw(INTERP_KERNEL::Exception); - bool isBefore(const MEDCouplingTimeDiscretization *other) const throw(INTERP_KERNEL::Exception); - bool isStrictlyBefore(const MEDCouplingTimeDiscretization *other) const throw(INTERP_KERNEL::Exception); - double getStartTime(int& dt, int& it) const throw(INTERP_KERNEL::Exception); - double getEndTime(int& dt, int& it) const throw(INTERP_KERNEL::Exception); - void setStartTime(double time, int dt, int it) throw(INTERP_KERNEL::Exception); - void setEndTime(double time, int dt, int it) throw(INTERP_KERNEL::Exception); - void getValueOnTime(int eltId, double time, double *value) const throw(INTERP_KERNEL::Exception); - void getValueOnDiscTime(int eltId, int dt, int it, double *value) const throw(INTERP_KERNEL::Exception); - public: - static const TypeOfTimeDiscretization DISCRETIZATION=NO_TIME; - private: - static const char EXCEPTION_MSG[]; - }; - - class MEDCOUPLING_EXPORT MEDCouplingWithTimeStep : public MEDCouplingTimeDiscretization - { - protected: - MEDCouplingWithTimeStep(const MEDCouplingWithTimeStep& other, bool deepCpy); - public: - MEDCouplingWithTimeStep(); - TypeOfTimeDiscretization getEnum() const { return DISCRETIZATION; } - bool isEqual(const MEDCouplingTimeDiscretization *other, double prec) const; - void getTinySerializationIntInformation(std::vector& tinyInfo) const; - void getTinySerializationDbleInformation(std::vector& tinyInfo) const; - void finishUnserialization(const std::vector& tinyInfoI, const std::vector& tinyInfoD, const std::vector& tinyInfoS); - MEDCouplingTimeDiscretization *performCpy(bool deepCpy) const; - void checkNoTimePresence() const throw(INTERP_KERNEL::Exception); - void checkTimePresence(double time) const throw(INTERP_KERNEL::Exception); - void setStartTime(double time, int dt, int it) throw(INTERP_KERNEL::Exception) { _time=time; _dt=dt; _it=it; } - void setEndTime(double time, int dt, int it) throw(INTERP_KERNEL::Exception) { _time=time; _dt=dt; _it=it; } - double getStartTime(int& dt, int& it) const throw(INTERP_KERNEL::Exception) { dt=_dt; it=_it; return _time; } - double getEndTime(int& dt, int& it) const throw(INTERP_KERNEL::Exception) { dt=_dt; it=_it; return _time; } - DataArrayDouble *getArrayOnTime(double time) const throw(INTERP_KERNEL::Exception); - void getValueOnTime(int eltId, double time, double *value) const throw(INTERP_KERNEL::Exception); - void getValueOnDiscTime(int eltId, int dt, int it, double *value) const throw(INTERP_KERNEL::Exception); - public: - static const TypeOfTimeDiscretization DISCRETIZATION=ONE_TIME; - private: - static const char EXCEPTION_MSG[]; - protected: - double _time; - int _dt; - int _it; - }; - - class MEDCOUPLING_EXPORT MEDCouplingTwoTimeSteps : public MEDCouplingTimeDiscretization - { - protected: - MEDCouplingTwoTimeSteps(); - ~MEDCouplingTwoTimeSteps(); - public: - void checkNoTimePresence() const throw(INTERP_KERNEL::Exception); - void checkTimePresence(double time) const throw(INTERP_KERNEL::Exception); - void getArrays(std::vector& arrays) const; - DataArrayDouble *getEndArray() const { return _end_array; } - void setStartTime(double time, int dt, int it) throw(INTERP_KERNEL::Exception) { _start_time=time; _start_dt=dt; _start_it=it; } - void setEndTime(double time, int dt, int it) throw(INTERP_KERNEL::Exception) { _end_time=time; _end_dt=dt; _end_it=it; } - double getStartTime(int& dt, int& it) const throw(INTERP_KERNEL::Exception) { dt=_start_dt; it=_start_it; return _start_time; } - double getEndTime(int& dt, int& it) const throw(INTERP_KERNEL::Exception) { dt=_end_dt; it=_end_it; return _end_time; } - void resizeForUnserialization(const std::vector& tinyInfoI, std::vector& arrays); - void finishUnserialization(const std::vector& tinyInfoI, const std::vector& tinyInfoD, const std::vector& tinyInfoS); - protected: - double _start_time; - double _end_time; - int _start_dt; - int _end_dt; - int _start_it; - int _end_it; - DataArrayDouble *_end_array; - }; - - class MEDCOUPLING_EXPORT MEDCouplingLinearTime : public MEDCouplingTwoTimeSteps - { - public: - TypeOfTimeDiscretization getEnum() const { return DISCRETIZATION; } - static const TypeOfTimeDiscretization DISCRETIZATION=LINEAR_TIME; - }; -} - -#endif diff --git a/src/MEDCoupling/MEDCouplingTimeLabel.cxx b/src/MEDCoupling/MEDCouplingTimeLabel.cxx deleted file mode 100644 index 52e33f528..000000000 --- a/src/MEDCoupling/MEDCouplingTimeLabel.cxx +++ /dev/null @@ -1,48 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#include "MEDCouplingTimeLabel.hxx" - -using namespace ParaMEDMEM; - -unsigned int TimeLabel::GLOBAL_TIME=0; - -TimeLabel::TimeLabel():_time(GLOBAL_TIME++) -{ -} - -TimeLabel::~TimeLabel() -{ -} - - TimeLabel& TimeLabel::operator=(const TimeLabel& other) -{ - _time=GLOBAL_TIME++; - return *this; -} - -void TimeLabel::declareAsNew() -{ - _time=GLOBAL_TIME++; -} - -void TimeLabel::updateTimeWith(const TimeLabel& other) -{ - if(_time - -using namespace ParaMEDMEM; - -MEDCouplingUMeshDesc::MEDCouplingUMeshDesc():_mesh_dim(-1),_desc_connec(0),_desc_connec_index(0), - _nodal_connec_face(0),_nodal_connec_face_index(0) -{ -} - -MEDCouplingUMeshDesc::~MEDCouplingUMeshDesc() -{ - if(_desc_connec) - _desc_connec->decrRef(); - if(_desc_connec_index) - _desc_connec_index->decrRef(); - if(_nodal_connec_face) - _nodal_connec_face->decrRef(); - if(_nodal_connec_face_index) - _nodal_connec_face_index->decrRef(); -} - -MEDCouplingUMeshDesc *MEDCouplingUMeshDesc::New() -{ - return new MEDCouplingUMeshDesc; -} - -MEDCouplingUMeshDesc *MEDCouplingUMeshDesc::New(const char *meshName, int meshDim) -{ - MEDCouplingUMeshDesc *ret=new MEDCouplingUMeshDesc; - ret->setName(meshName); - ret->setMeshDimension(meshDim); - return ret; -} - -void MEDCouplingUMeshDesc::checkCoherency() const throw(INTERP_KERNEL::Exception) -{ - for(std::set::const_iterator iter=_types.begin();iter!=_types.end();iter++) - { - if(INTERP_KERNEL::CellModel::getCellModel(*iter).getDimension()!=_mesh_dim) - { - std::ostringstream message; - message << "MeshDesc invalid because dimension is " << _mesh_dim << " and there is presence of cell(s) with type " << (*iter); - throw INTERP_KERNEL::Exception(message.str().c_str()); - } - } -} - -void MEDCouplingUMeshDesc::setMeshDimension(unsigned meshDim) -{ - _mesh_dim=meshDim; - declareAsNew(); -} - -int MEDCouplingUMeshDesc::getNumberOfCells() const -{ - if(_desc_connec_index) - return _desc_connec_index->getNumberOfTuples()-1; - else - throw INTERP_KERNEL::Exception("Unable to get number of cells because no connectivity specified !"); -} - -int MEDCouplingUMeshDesc::getNumberOfFaces() const -{ - if(_nodal_connec_face_index) - return _nodal_connec_face_index->getNumberOfTuples()-1; - else - throw INTERP_KERNEL::Exception("Unable to get number of faces because no connectivity specified !"); -} - -int MEDCouplingUMeshDesc::getCellMeshLength() const -{ - return _desc_connec->getNbOfElems(); -} - -int MEDCouplingUMeshDesc::getFaceMeshLength() const -{ - return _nodal_connec_face->getNbOfElems(); -} - -void MEDCouplingUMeshDesc::setConnectivity(DataArrayInt *descConn, DataArrayInt *descConnIndex, DataArrayInt *nodalFaceConn, DataArrayInt *nodalFaceConnIndx) -{ - DataArrayInt::setArrayIn(descConn,_desc_connec); - DataArrayInt::setArrayIn(descConnIndex,_desc_connec_index); - DataArrayInt::setArrayIn(nodalFaceConn,_nodal_connec_face); - DataArrayInt::setArrayIn(nodalFaceConnIndx,_nodal_connec_face_index); - computeTypes(); -} - -void MEDCouplingUMeshDesc::getTinySerializationInformation(std::vector& tinyInfo, std::vector& littleStrings) const -{ - MEDCouplingPointSet::getTinySerializationInformation(tinyInfo,littleStrings); - tinyInfo.push_back(getMeshDimension()); - tinyInfo.push_back(getNumberOfNodes()); - tinyInfo.push_back(getNumberOfCells()); - tinyInfo.push_back(getCellMeshLength()); - tinyInfo.push_back(getNumberOfFaces()); - tinyInfo.push_back(getFaceMeshLength()); -} - -void MEDCouplingUMeshDesc::resizeForUnserialization(const std::vector& tinyInfo, DataArrayInt *a1, DataArrayDouble *a2, std::vector& littleStrings) -{ - std::vector tinyInfoTmp(tinyInfo.begin()+1,tinyInfo.end()); - MEDCouplingPointSet::resizeForUnserialization(tinyInfoTmp,a1,a2,littleStrings); - a1->alloc(tinyInfo[5]+tinyInfo[4]+1+tinyInfo[7]+tinyInfo[6]+1,1); -} - -void MEDCouplingUMeshDesc::serialize(DataArrayInt *&a1, DataArrayDouble *&a2) const -{ - MEDCouplingPointSet::serialize(a1,a2); - // - a1=DataArrayInt::New(); - a1->alloc(getCellMeshLength()+getNumberOfCells()+1+getFaceMeshLength()+getNumberOfFaces()+1,1); - int *ptA1=a1->getPointer(); - const int *descConn=_desc_connec->getConstPointer(); - const int *descConnIndex=_desc_connec_index->getConstPointer(); - const int *faceConn=_nodal_connec_face->getConstPointer(); - const int *faceConnIndex=_nodal_connec_face_index->getConstPointer(); - ptA1=std::copy(descConn,descConn+getCellMeshLength(),ptA1); - ptA1=std::copy(descConnIndex,descConnIndex+getNumberOfCells()+1,ptA1); - ptA1=std::copy(faceConn,faceConn+getFaceMeshLength(),ptA1); - std::copy(faceConnIndex,faceConnIndex+getNumberOfFaces()+1,ptA1); -} - -void MEDCouplingUMeshDesc::unserialization(const std::vector& tinyInfo, DataArrayInt *a1, DataArrayDouble *a2, const std::vector& littleStrings) -{ - std::vector tinyInfoTmp(tinyInfo.begin()+1,tinyInfo.end()); - MEDCouplingPointSet::unserialization(tinyInfoTmp,a1,a2,littleStrings); - // - const int *recvBuffer=a1->getConstPointer(); - DataArrayInt *descConn=DataArrayInt::New(); - descConn->alloc(tinyInfo[5],1); - std::copy(recvBuffer,recvBuffer+tinyInfo[5],descConn->getPointer()); - DataArrayInt *descConnIndex=DataArrayInt::New(); - descConnIndex->alloc(tinyInfo[4]+1,1); - std::copy(recvBuffer+tinyInfo[5],recvBuffer+tinyInfo[5]+tinyInfo[4]+1,descConnIndex->getPointer()); - DataArrayInt *faceConn=DataArrayInt::New(); - faceConn->alloc(tinyInfo[7],1); - std::copy(recvBuffer+tinyInfo[5]+tinyInfo[4]+1,recvBuffer+tinyInfo[5]+tinyInfo[4]+1+tinyInfo[7],faceConn->getPointer()); - DataArrayInt *faceConnIndex=DataArrayInt::New(); - faceConnIndex->alloc(tinyInfo[6]+1,1); - std::copy(recvBuffer+tinyInfo[5]+tinyInfo[4]+1+tinyInfo[7], - recvBuffer+tinyInfo[5]+tinyInfo[5]+1+tinyInfo[7]+tinyInfo[6]+1,faceConnIndex->getPointer()); - setConnectivity(descConn,descConnIndex,faceConn,faceConnIndex); - descConn->decrRef(); - descConnIndex->decrRef(); - faceConn->decrRef(); - faceConnIndex->decrRef(); - setMeshDimension(tinyInfo[2]); -} - -void MEDCouplingUMeshDesc::giveElemsInBoundingBox(const double *bbox, double eps, std::vector& elems) -{ - int dim=getSpaceDimension(); - double* elem_bb=new double[2*dim]; - const int* conn = _desc_connec->getConstPointer(); - const int* conn_index= _desc_connec_index->getConstPointer(); - const int* face = _nodal_connec_face->getConstPointer(); - const int* face_index= _nodal_connec_face_index->getConstPointer(); - const double* coords = getCoords()->getConstPointer(); - int nbOfCells=getNumberOfCells(); - for ( int ielem=0; ielem::max(); - elem_bb[i*2+1]=-std::numeric_limits::max(); - } - - for (int jface=conn_index[ielem]+1; jface elem_bb[idim*2+1] ) - { - elem_bb[idim*2+1] = coords[node*dim+idim] ; - } - } - } - } - if (intersectsBoundingBox(elem_bb, bbox, dim, eps)) - { - elems.push_back(ielem); - } - } - delete [] elem_bb; -} - -MEDCouplingPointSet *MEDCouplingUMeshDesc::buildPartOfMySelf(const int *start, const int *end, bool keepCoords) const -{ - //not implemented yet. - return 0; -} - -MEDCouplingPointSet *MEDCouplingUMeshDesc::buildPartOfMySelfNode(const int *start, const int *end, bool fullyIn) const -{ - //not implemented yet - return 0; -} - -void MEDCouplingUMeshDesc::renumberConnectivity(const int *newNodeNumbers) -{ -} - -MEDCouplingFieldDouble *MEDCouplingUMeshDesc::getMeasureField() const -{ - //not implemented yet. - return 0; -} - -DataArrayInt *MEDCouplingUMeshDesc::zipCoordsTraducer() -{ - //not implemented yet. - return 0; -} - -void MEDCouplingUMeshDesc::computeTypes() -{ - if(_desc_connec && _desc_connec_index) - { - _types.clear(); - const int *conn=_desc_connec->getConstPointer(); - const int *connIndex=_desc_connec_index->getConstPointer(); - int nbOfElem=_desc_connec_index->getNbOfElems()-1; - for(const int *pt=connIndex;pt!=connIndex+nbOfElem;pt++) - _types.insert((INTERP_KERNEL::NormalizedCellType)conn[*pt]); - } -} - -void MEDCouplingUMeshDesc::checkFullyDefined() const throw(INTERP_KERNEL::Exception) -{ - if(!_desc_connec || !_desc_connec_index || !_nodal_connec_face || !_nodal_connec_face_index || !_coords) - throw INTERP_KERNEL::Exception("full connectivity and coordinates not set in unstructured mesh."); -} diff --git a/src/MEDCoupling/MEDCouplingUMeshDesc.hxx b/src/MEDCoupling/MEDCouplingUMeshDesc.hxx deleted file mode 100644 index ceced5640..000000000 --- a/src/MEDCoupling/MEDCouplingUMeshDesc.hxx +++ /dev/null @@ -1,71 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#ifndef __PARAMEDMEM_MEDCOUPLINGUMESHDESC_HXX__ -#define __PARAMEDMEM_MEDCOUPLINGUMESHDESC_HXX__ - -#include "MEDCouplingPointSet.hxx" -#include "MEDCoupling.hxx" -#include "NormalizedUnstructuredMesh.hxx" - -#include - -namespace ParaMEDMEM -{ - class MEDCOUPLING_EXPORT MEDCouplingUMeshDesc : public MEDCouplingPointSet - { - public: - static MEDCouplingUMeshDesc *New(); - static MEDCouplingUMeshDesc *New(const char *meshName, int meshDim); - void checkCoherency() const throw(INTERP_KERNEL::Exception); - void setMeshDimension(unsigned meshDim); - int getNumberOfCells() const; - int getNumberOfFaces() const; - int getCellMeshLength() const; - int getFaceMeshLength() const; - int getMeshDimension() const { return _mesh_dim; } - MEDCouplingMeshType getType() const { return UNSTRUCTURED_DESC; } - void setConnectivity(DataArrayInt *descConn, DataArrayInt *descConnIndex, DataArrayInt *nodalFaceConn, DataArrayInt *nodalFaceConnIndx); - //tools to overload - void getTinySerializationInformation(std::vector& tinyInfo, std::vector& littleStrings) const; - void resizeForUnserialization(const std::vector& tinyInfo, DataArrayInt *a1, DataArrayDouble *a2, std::vector& littleStrings); - void serialize(DataArrayInt *&a1, DataArrayDouble *&a2) const; - void unserialization(const std::vector& tinyInfo, DataArrayInt *a1, DataArrayDouble *a2, - const std::vector& littleStrings); - void giveElemsInBoundingBox(const double *bbox, double eps, std::vector& elems); - MEDCouplingPointSet *buildPartOfMySelf(const int *start, const int *end, bool keepCoords) const; - MEDCouplingPointSet *buildPartOfMySelfNode(const int *start, const int *end, bool fullyIn) const; - void renumberConnectivity(const int *newNodeNumbers); - MEDCouplingFieldDouble *getMeasureField() const; - DataArrayInt *zipCoordsTraducer(); - private: - MEDCouplingUMeshDesc(); - ~MEDCouplingUMeshDesc(); - void computeTypes(); - void checkFullyDefined() const throw(INTERP_KERNEL::Exception); - private: - unsigned _mesh_dim; - DataArrayInt *_desc_connec; - DataArrayInt *_desc_connec_index; - DataArrayInt *_nodal_connec_face; - DataArrayInt *_nodal_connec_face_index; - std::set _types; - }; -} - -#endif diff --git a/src/MEDCoupling_Swig/MEDCouplingBasicsTest.py b/src/MEDCoupling_Swig/MEDCouplingBasicsTest.py deleted file mode 100644 index 336e0d059..000000000 --- a/src/MEDCoupling_Swig/MEDCouplingBasicsTest.py +++ /dev/null @@ -1,62 +0,0 @@ -from libMEDCoupling_Swig import * -import unittest - -class MEDCouplingBasicsTest(unittest.TestCase): - def testMesh(self): - tab4=[1, 2, 8, 7, 2, 3, 9, 8, 3, - 4, 10, 9, 4, 5, 11, 10, 5, - 0, 6, 11, 0, 1, 7, 6 ] - nbOfNodes=12 - nbOfCells=6 - coords=[ 0.024155, 0.04183768725682622, -0.305, 0.04831000000000001, -1.015761910347357e-17, - -0.305, 0.09662000000000001, -1.832979297858306e-18, -0.305, 0.120775, 0.04183768725682623, - -0.305, 0.09662000000000001, 0.08367537451365245, -0.305, 0.04831000000000001, 0.08367537451365246, - -0.305, 0.024155, 0.04183768725682622, -0.2863, 0.04831000000000001, -1.015761910347357e-17, -0.2863, - 0.09662000000000001, -1.832979297858306e-18, -0.2863, 0.120775, 0.04183768725682623, -0.2863, 0.09662000000000001, - 0.08367537451365245, -0.2863, 0.04831000000000001, 0.08367537451365246, -0.2863 ] - mesh=MEDCouplingUMesh.New() - mesh.setMeshDimension(2) - mesh.allocateCells(8); - mesh.setName("mesh1") - self.failUnless(mesh.getName()=="mesh1") - for i in range(nbOfCells): - mesh.insertNextCell(NORM_QUAD4,4,tab4[4*i:4*(i+1)]); - pass - mesh.finishInsertingCells() - self.failUnless(mesh.getNumberOfCells()==nbOfCells) - self.failUnless(mesh.getNodalConnectivity().getNbOfElems()==30) - self.failUnless(mesh.getNodalConnectivityIndex().getNbOfElems()==nbOfCells+1) - myCoords=DataArrayDouble.New() - myCoords.setValues(coords,nbOfNodes,3); - self.failUnless(myCoords.getIJ(3,2)==-0.305) - mesh.setCoords(myCoords); - mesh.checkCoherency(); - self.failUnless(mesh.getAllTypes()==[4]) - myFalseConn=DataArrayInt.New() - myFalseConn.setValues(tab4,6,4) - self.failUnless(myFalseConn.getIJ(1,1)==3) - # - field=MEDCouplingFieldDouble.New(ON_CELLS) - field.setMesh(mesh) - field.setNature(Integral) - myCoords=DataArrayDouble.New() - sampleTab=[] - for i in range(nbOfCells*9): - sampleTab.append(float(i)) - myCoords.setValues(sampleTab,nbOfCells,9); - field.setArray(myCoords) - self.failUnless(3==mesh.getSpaceDimension()) - field.checkCoherency() - mesh2=mesh.clone(False) - mesh3=mesh.clone(True) - mesh3=0 - mesh2=0 - ## deep full recursively copy of field -> both field and mesh underneath copied - field2=field.clone(True) - field2.setMesh(field.getMesh().clone(True)) - pass - def setUp(self): - pass - pass - -unittest.main() diff --git a/src/MEDCoupling_Swig/MEDCouplingTypemaps.i b/src/MEDCoupling_Swig/MEDCouplingTypemaps.i deleted file mode 100644 index c3a33b1be..000000000 --- a/src/MEDCoupling_Swig/MEDCouplingTypemaps.i +++ /dev/null @@ -1,128 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// - -static PyObject* convertMesh(ParaMEDMEM::MEDCouplingMesh* mesh, int owner) -{ - PyObject *ret; - if(dynamic_cast(mesh)) - ret=SWIG_NewPointerObj((void*)mesh,SWIGTYPE_p_ParaMEDMEM__MEDCouplingUMesh,owner); - return ret; -} - -static PyObject *convertIntArrToPyList(const int *ptr, int size) -{ - PyObject *ret=PyList_New(size); - for(int i=0;idecrRef();" -%feature("unref") MEDCouplingUMesh "$this->decrRef();" -%feature("unref") DataArrayInt "$this->decrRef();" -%feature("unref") MEDCouplingFieldDouble "$this->decrRef();" - -%ignore ParaMEDMEM::TimeLabel::operator=; -%ignore ParaMEDMEM::MemArray::operator=; -%ignore ParaMEDMEM::MemArray::operator[]; - -%nodefaultctor; -%include "MEDCouplingTimeLabel.hxx" -%include "MEDCouplingRefCountObject.hxx" -%include "MEDCouplingMesh.hxx" -%include "MEDCouplingPointSet.hxx" -%include "MEDCouplingMemArray.hxx" -%include "MEDCouplingMesh.hxx" -%include "NormalizedUnstructuredMesh.hxx" -%include "MEDCouplingField.hxx" -%include "MEDCouplingNatureOfField.hxx" - -namespace ParaMEDMEM -{ - class MEDCouplingUMesh : public ParaMEDMEM::MEDCouplingPointSet - { - public: - static MEDCouplingUMesh *New(); - MEDCouplingUMesh *clone(bool recDeepCpy) const; - void updateTime(); - void checkCoherency() const throw(INTERP_KERNEL::Exception); - void setMeshDimension(int meshDim); - void allocateCells(int nbOfCells); - void setCoords(DataArrayDouble *coords); - DataArrayDouble *getCoords() const; - void finishInsertingCells(); - void setConnectivity(DataArrayInt *conn, DataArrayInt *connIndex, bool isComputingTypes=true); - DataArrayInt *getNodalConnectivity() const; - DataArrayInt *getNodalConnectivityIndex() const; - INTERP_KERNEL::NormalizedCellType getTypeOfCell(int cellId) const; - int getNumberOfNodesInCell(int cellId) const; - bool isStructured() const; - int getNumberOfCells() const; - int getNumberOfNodes() const; - int getSpaceDimension() const; - int getMeshDimension() const; - int getMeshLength() const; - //tools - void zipCoords(); - DataArrayInt *zipCoordsTraducer(); - void getReverseNodalConnectivity(DataArrayInt *revNodal, DataArrayInt *revNodalIndx) const; - MEDCouplingUMesh *buildPartOfMySelf(const int *start, const int *end, bool keepCoords) const; - %extend { - void insertNextCell(INTERP_KERNEL::NormalizedCellType type, int size, PyObject *li) - { - int *tmp=convertPyToNewIntArr(li,size); - self->insertNextCell(type,size,tmp); - delete [] tmp; - } - PyObject *getAllTypes() const - { - std::set result=self->getAllTypes(); - std::set::const_iterator iL=result.begin(); - PyObject *res = PyList_New(result.size()); - for (int i=0;iL!=result.end(); i++, iL++) - PyList_SetItem(res,i,PyInt_FromLong(*iL)); - return res; - } - } - }; -} - -%extend ParaMEDMEM::DataArrayDouble - { - void setValues(PyObject *li, int nbOfTuples, int nbOfElsPerTuple) - { - double *tmp=convertPyToNewDblArr2(li); - self->useArray(tmp,true,CPP_DEALLOC,nbOfTuples,nbOfElsPerTuple); - } - - PyObject *getValues() - { - const double *vals=self->getPointer(); - return convertDblArrToPyList(vals,self->getNbOfElems()); - } - }; - -%extend ParaMEDMEM::DataArrayInt - { - void setValues(PyObject *li, int nbOfTuples, int nbOfElsPerTuple) - { - int *tmp=convertPyToNewIntArr2(li); - self->useArray(tmp,true,CPP_DEALLOC,nbOfTuples,nbOfElsPerTuple); - } - - PyObject *getValues() - { - const int *vals=self->getPointer(); - return convertIntArrToPyList(vals,self->getNbOfElems()); - } - }; - -%include "MEDCouplingField.hxx" - -namespace ParaMEDMEM -{ - class MEDCouplingFieldDouble : public ParaMEDMEM::MEDCouplingField - { - public: - static MEDCouplingFieldDouble *New(TypeOfField type); - MEDCouplingFieldDouble *clone(bool recDeepCpy) const; - void checkCoherency() const throw(INTERP_KERNEL::Exception); - double getIJ(int tupleId, int compoId) const; - void setArray(DataArrayDouble *array); - DataArrayDouble *getArray() const { return _array; } - void applyLin(double a, double b, int compoId); - int getNumberOfComponents() const; - int getNumberOfTuples() const throw(INTERP_KERNEL::Exception); - NatureOfField getNature() const { return _nature; } - void setNature(NatureOfField nat) throw(INTERP_KERNEL::Exception); - void updateTime(); - %extend { - void setValues(PyObject *li) - { - if(self->getArray()!=0) - { - double *tmp=convertPyToNewDblArr2(li); - int nbTuples=self->getArray()->getNumberOfTuples(); - int nbOfCompo=self->getArray()->getNumberOfComponents(); - self->getArray()->useArray(tmp,true,CPP_DEALLOC,nbTuples,nbOfCompo); - } - else - PyErr_SetString(PyExc_TypeError,"setValuesCpy : field must contain an array behind"); - } - } - }; -} diff --git a/src/ParaMEDMEM/GlobalizerMesh.cxx b/src/ParaMEDMEM/GlobalizerMesh.cxx deleted file mode 100644 index 909215846..000000000 --- a/src/ParaMEDMEM/GlobalizerMesh.cxx +++ /dev/null @@ -1,143 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#include "GlobalizerMesh.hxx" -#include "MEDCouplingFieldDouble.hxx" -#include "CommInterface.hxx" - -using namespace std; - -namespace ParaMEDMEM -{ - GlobalizerMesh::GlobalizerMesh(const MPI_Comm *comm, MEDCouplingFieldDouble *localField):_comm(comm),_local_field(localField) - { - if(_local_field) - _local_field->incrRef(); - } - - GlobalizerMesh::~GlobalizerMesh() - { - if(_local_field) - _local_field->decrRef(); - } - - NatureOfField GlobalizerMesh::getLocalNature() const - { - return _local_field->getNature(); - } - - GlobalizerMeshWorkingSide::GlobalizerMeshWorkingSide(const MPI_Comm *comm, MEDCouplingFieldDouble *localField, - const std::string& distantMeth, const std::vector& lazyProcs):GlobalizerMesh(comm,localField),_distant_method(distantMeth),_lazy_procs(lazyProcs) - { - } - - GlobalizerMeshWorkingSide::~GlobalizerMeshWorkingSide() - { - } - - const std::vector& GlobalizerMeshWorkingSide::getProcIdsInInteraction() const - { - return _lazy_procs; - } - - /*! - * connected with GlobalizerMeshLazySide::recvFromWorkingSide - */ - void GlobalizerMeshWorkingSide::sendSumToLazySide(const std::vector< std::vector >& distantLocEltIds, const std::vector< std::vector >& partialSumRelToDistantIds) - { - int procId=0; - CommInterface comm; - for(vector::const_iterator iter=_lazy_procs.begin();iter!=_lazy_procs.end();iter++,procId++) - { - const vector& eltIds=distantLocEltIds[procId]; - const vector& valued=partialSumRelToDistantIds[procId]; - int lgth=eltIds.size(); - comm.send(&lgth,1,MPI_INT,*iter,1114,*_comm); - comm.send((void *)&eltIds[0],lgth,MPI_INT,*iter,1115,*_comm); - comm.send((void *)&valued[0],lgth,MPI_DOUBLE,*iter,1116,*_comm); - } - } - - /*! - * connected with GlobalizerMeshLazySide::sendToWorkingSide - */ - void GlobalizerMeshWorkingSide::recvSumFromLazySide(std::vector< std::vector >& globalSumRelToDistantIds) - { - int procId=0; - CommInterface comm; - MPI_Status status; - for(vector::const_iterator iter=_lazy_procs.begin();iter!=_lazy_procs.end();iter++,procId++) - { - std::vector& vec=globalSumRelToDistantIds[procId]; - comm.recv(&vec[0],vec.size(),MPI_DOUBLE,*iter,1117,*_comm,&status); - } - } - - GlobalizerMeshLazySide::GlobalizerMeshLazySide(const MPI_Comm *comm, MEDCouplingFieldDouble *localField, const std::vector& computeProcs):GlobalizerMesh(comm,localField),_compute_procs(computeProcs) - { - } - - GlobalizerMeshLazySide::~GlobalizerMeshLazySide() - { - } - - /*! - * connected with GlobalizerMeshWorkingSide::sendSumToLazySide - */ - void GlobalizerMeshLazySide::recvFromWorkingSide() - { - _values_added.resize(_local_field->getNumberOfTuples()); - int procId=0; - CommInterface comm; - _ids_per_working_proc.resize(_compute_procs.size()); - MPI_Status status; - for(vector::const_iterator iter=_compute_procs.begin();iter!=_compute_procs.end();iter++,procId++) - { - int lgth; - comm.recv(&lgth,1,MPI_INT,*iter,1114,*_comm,&status); - vector& ids=_ids_per_working_proc[procId]; - ids.resize(lgth); - vector values(lgth); - comm.recv(&ids[0],lgth,MPI_INT,*iter,1115,*_comm,&status); - comm.recv(&values[0],lgth,MPI_DOUBLE,*iter,1116,*_comm,&status); - for(int i=0;i::const_iterator iter=_compute_procs.begin();iter!=_compute_procs.end();iter++,procId++) - { - vector& ids=_ids_per_working_proc[procId]; - vector valsToSend(ids.size()); - vector::iterator iter3=valsToSend.begin(); - for(vector::const_iterator iter2=ids.begin();iter2!=ids.end();iter2++,iter3++) - *iter3=_values_added[*iter2]; - comm.send(&valsToSend[0],ids.size(),MPI_DOUBLE,*iter,1117,*_comm); - ids.clear(); - } - _ids_per_working_proc.clear(); - } -} - diff --git a/src/ParaMEDMEM/GlobalizerMesh.hxx b/src/ParaMEDMEM/GlobalizerMesh.hxx deleted file mode 100644 index 3436545a8..000000000 --- a/src/ParaMEDMEM/GlobalizerMesh.hxx +++ /dev/null @@ -1,72 +0,0 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -#ifndef __GLOBALIZERMESH_HXX__ -#define __GLOBALIZERMESH_HXX__ - -#include "MEDCouplingNatureOfField.hxx" - -#include -#include -#include - -namespace ParaMEDMEM -{ - class MEDCouplingFieldDouble; - - class GlobalizerMesh - { - protected: - GlobalizerMesh(const MPI_Comm *comm, MEDCouplingFieldDouble *localField); - public: - NatureOfField getLocalNature() const; - virtual ~GlobalizerMesh(); - protected: - const MPI_Comm *_comm; - MEDCouplingFieldDouble *_local_field; - }; - - class GlobalizerMeshWorkingSide : public GlobalizerMesh - { - public: - GlobalizerMeshWorkingSide(const MPI_Comm *comm, MEDCouplingFieldDouble *localField, const std::string& distantMeth, const std::vector& lazyProcs); - ~GlobalizerMeshWorkingSide(); - // - const std::vector& getProcIdsInInteraction() const; - void sendSumToLazySide(const std::vector< std::vector >& distantLocEltIds, const std::vector< std::vector >& partialSumRelToDistantIds); - void recvSumFromLazySide(std::vector< std::vector >& globalSumRelToDistantIds); - private: - std::string _distant_method; - std::vector _lazy_procs; - }; - - class GlobalizerMeshLazySide : public GlobalizerMesh - { - public: - GlobalizerMeshLazySide(const MPI_Comm *comm, MEDCouplingFieldDouble *localField, const std::vector& computeProcs); - ~GlobalizerMeshLazySide(); - void recvFromWorkingSide(); - void sendToWorkingSide(); - private: - std::vector _compute_procs; - std::vector _values_added; - std::vector< std::vector > _ids_per_working_proc; - }; -} - -#endif diff --git a/src/ParaMEDMEM/Test/ParaMEDMEMTest_ICocoTrio.cxx b/src/ParaMEDMEM/Test/ParaMEDMEMTest_ICocoTrio.cxx deleted file mode 100644 index bb377556d..000000000 --- a/src/ParaMEDMEM/Test/ParaMEDMEMTest_ICocoTrio.cxx +++ /dev/null @@ -1,252 +0,0 @@ -#include "ParaMEDMEMTest.hxx" -#include -#include "CommInterface.hxx" -#include "ProcessorGroup.hxx" -#include "MPIProcessorGroup.hxx" -#include "DEC.hxx" -#include "IntersectionDEC.hxx" -#include -#include -#include "ICoCoTrioField.hxx" -#include -#include - -using namespace std; -using namespace ParaMEDMEM; -using namespace ICoCo; - -typedef enum {sync_and,sync_or} synctype; -void synchronize_bool(bool& stop, synctype s) -{ - int my_stop; - int my_stop_temp = stop?1:0; - - if (s==sync_and) - MPI_Allreduce(&my_stop_temp,&my_stop,1,MPI_INTEGER,MPI_MIN,MPI_COMM_WORLD); - else if (s==sync_or) - MPI_Allreduce(&my_stop_temp,&my_stop,1,MPI_INTEGER,MPI_MAX,MPI_COMM_WORLD); - stop =(my_stop==1); -} - -void synchronize_dt(double& dt) -{ - double dttemp=dt; - MPI_Allreduce(&dttemp,&dt,1,MPI_DOUBLE,MPI_MIN,MPI_COMM_WORLD); -} - - -void affiche( const TrioField& field) -{ - cout < emetteur_ids; - set recepteur_ids; - emetteur_ids.insert(0); - recepteur_ids.insert(1); - - MPIProcessorGroup recepteur_group(comm,recepteur_ids); - MPIProcessorGroup emetteur_group(comm,emetteur_ids); - - - string cas; - if (recepteur_group.containsMyRank()) - { - cas="recepteur"; - - } - else - cas="emetteur"; - - IntersectionDEC dec_emetteur(emetteur_group, recepteur_group); - - TrioField champ_emetteur, champ_recepteur; - - init_triangle(champ_emetteur); - //init_triangle(champ_emetteur); - init_quad(champ_recepteur); - //init_emetteur(champ_recepteur); - - if (cas=="emetteur") - { - champ_emetteur._field=new double[champ_emetteur._nb_elems]; - for (int ele=0;ele -#include "MEDLoader.hxx" -#include "MEDCouplingUMesh.hxx" -#include "MEDCouplingFieldDouble.hxx" - -#include -#include -#include -#include - -using namespace std; -using namespace INTERP_KERNEL; -using namespace ParaMEDMEM; - -void ParaMEDMEMTest::testMEDLoaderRead1() -{ - string medRootDir=getenv("MED_ROOT_DIR"); - medRootDir+="/share/salome/resources/med/pointe_import22.med"; - const char *fileName=medRootDir.c_str(); - vector meshNames=MEDLoader::GetMeshNames(fileName); - CPPUNIT_ASSERT_EQUAL(1,(int)meshNames.size()); - MEDCouplingUMesh *mesh=MEDLoader::ReadUMeshFromFile(fileName,meshNames[0].c_str(),0); - CPPUNIT_ASSERT_EQUAL(3,mesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(3,mesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(16,mesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(19,mesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(3,(int)mesh->getAllTypes().size()); - for(int i=0;i<12;i++) - CPPUNIT_ASSERT_EQUAL(NORM_TETRA4,mesh->getTypeOfCell(i)); - for(int i=12;i<14;i++) - CPPUNIT_ASSERT_EQUAL(NORM_HEXA8,mesh->getTypeOfCell(i)); - for(int i=14;i<16;i++) - CPPUNIT_ASSERT_EQUAL(NORM_PYRA5,mesh->getTypeOfCell(i)); - CPPUNIT_ASSERT_EQUAL(90,mesh->getNodalConnectivity()->getNbOfElems()); - CPPUNIT_ASSERT_EQUAL(701,std::accumulate(mesh->getNodalConnectivity()->getPointer(),mesh->getNodalConnectivity()->getPointer()+90,0)); - CPPUNIT_ASSERT_EQUAL(711,std::accumulate(mesh->getNodalConnectivityIndex()->getPointer(),mesh->getNodalConnectivityIndex()->getPointer()+17,0)); - CPPUNIT_ASSERT_DOUBLES_EQUAL(46.,std::accumulate(mesh->getCoords()->getPointer(),mesh->getCoords()->getPointer()+57,0),1e-12); - mesh->decrRef(); - // - vector families=MEDLoader::GetMeshFamilyNames(fileName,meshNames[0].c_str()); - CPPUNIT_ASSERT_EQUAL(8,(int)families.size()); - CPPUNIT_ASSERT(families[2]=="FAMILLE_ELEMENT_3"); - // - vector families2; - families2.push_back(families[2]); - mesh=MEDLoader::ReadUMeshFromFamilies(fileName,meshNames[0].c_str(),0,families2); - CPPUNIT_ASSERT_EQUAL(3,mesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(3,mesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(2,mesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(19,mesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(2,(int)mesh->getAllTypes().size()); - CPPUNIT_ASSERT_EQUAL(NORM_TETRA4,mesh->getTypeOfCell(0)); - CPPUNIT_ASSERT_EQUAL(NORM_PYRA5,mesh->getTypeOfCell(1)); - CPPUNIT_ASSERT_EQUAL(11,mesh->getNodalConnectivity()->getNbOfElems()); - CPPUNIT_ASSERT_EQUAL(132,std::accumulate(mesh->getNodalConnectivity()->getPointer(),mesh->getNodalConnectivity()->getPointer()+11,0)); - CPPUNIT_ASSERT_EQUAL(16,std::accumulate(mesh->getNodalConnectivityIndex()->getPointer(),mesh->getNodalConnectivityIndex()->getPointer()+3,0)); - CPPUNIT_ASSERT_DOUBLES_EQUAL(46.,std::accumulate(mesh->getCoords()->getPointer(),mesh->getCoords()->getPointer()+57,0),1e-12); - mesh->decrRef(); - // - vector groups=MEDLoader::GetMeshGroupsNames(fileName,meshNames[0].c_str()); - CPPUNIT_ASSERT_EQUAL(5,(int)groups.size()); - CPPUNIT_ASSERT(groups[0]=="groupe1"); - CPPUNIT_ASSERT(groups[1]=="groupe2"); - CPPUNIT_ASSERT(groups[2]=="groupe3"); - CPPUNIT_ASSERT(groups[3]=="groupe4"); - CPPUNIT_ASSERT(groups[4]=="groupe5"); - vector groups2; - groups2.push_back(groups[0]); - mesh=MEDLoader::ReadUMeshFromGroups(fileName,meshNames[0].c_str(),0,groups2); - CPPUNIT_ASSERT_EQUAL(3,mesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(3,mesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(7,mesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(19,mesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(2,(int)mesh->getAllTypes().size()); - for(int i=0;i<6;i++) - CPPUNIT_ASSERT_EQUAL(NORM_TETRA4,mesh->getTypeOfCell(i)); - CPPUNIT_ASSERT_EQUAL(NORM_PYRA5,mesh->getTypeOfCell(6)); - CPPUNIT_ASSERT_EQUAL(36,mesh->getNodalConnectivity()->getNbOfElems()); - CPPUNIT_ASSERT_EQUAL(254,std::accumulate(mesh->getNodalConnectivity()->getPointer(),mesh->getNodalConnectivity()->getPointer()+36,0)); - CPPUNIT_ASSERT_EQUAL(141,std::accumulate(mesh->getNodalConnectivityIndex()->getPointer(),mesh->getNodalConnectivityIndex()->getPointer()+8,0)); - CPPUNIT_ASSERT_DOUBLES_EQUAL(46.,std::accumulate(mesh->getCoords()->getPointer(),mesh->getCoords()->getPointer()+57,0),1e-12); - mesh->decrRef(); - // - std::vector fieldsName=MEDLoader::GetCellFieldNamesOnMesh(fileName,meshNames[0].c_str()); - CPPUNIT_ASSERT_EQUAL(2,(int)fieldsName.size()); - CPPUNIT_ASSERT(fieldsName[0]=="fieldcelldoublescalar"); - CPPUNIT_ASSERT(fieldsName[1]=="fieldcelldoublevector"); - std::vector > its0=MEDLoader::GetCellFieldIterations(fileName,fieldsName[0].c_str()); - CPPUNIT_ASSERT_EQUAL(1,(int)its0.size()); - CPPUNIT_ASSERT_EQUAL(-1,its0[0].first); - CPPUNIT_ASSERT_EQUAL(-1,its0[0].second); - std::vector > its1=MEDLoader::GetCellFieldIterations(fileName,fieldsName[1].c_str()); - CPPUNIT_ASSERT_EQUAL(1,(int)its1.size()); - CPPUNIT_ASSERT_EQUAL(-1,its1[0].first); - CPPUNIT_ASSERT_EQUAL(-1,its1[0].second); - // - MEDCouplingFieldDouble *field0=MEDLoader::ReadFieldDoubleCell(fileName,meshNames[0].c_str(),0,fieldsName[0].c_str(),its0[0].first,its0[0].second); - field0->checkCoherency(); - CPPUNIT_ASSERT(field0->getName()==fieldsName[0]); - CPPUNIT_ASSERT_EQUAL(1,field0->getNumberOfComponents()); - CPPUNIT_ASSERT_EQUAL(16,field0->getNumberOfTuples()); - const double expectedValues[16]={1.,1.,1.,1.,1.,1.,1.,1.,1.,1.,1.,1.,3.,3.,2.,2.}; - double diffValue[16]; - std::transform(field0->getArray()->getPointer(),field0->getArray()->getPointer()+16,expectedValues,diffValue,std::minus()); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::max_element(diffValue,diffValue+16),1e-12); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::min_element(diffValue,diffValue+16),1e-12); - const MEDCouplingUMesh *constMesh=dynamic_cast(field0->getMesh()); - CPPUNIT_ASSERT(constMesh); - CPPUNIT_ASSERT_EQUAL(3,constMesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(3,constMesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(16,constMesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(19,constMesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(3,(int)constMesh->getAllTypes().size()); - for(int i=0;i<12;i++) - CPPUNIT_ASSERT_EQUAL(NORM_TETRA4,constMesh->getTypeOfCell(i)); - for(int i=12;i<14;i++) - CPPUNIT_ASSERT_EQUAL(NORM_HEXA8,constMesh->getTypeOfCell(i)); - for(int i=14;i<16;i++) - CPPUNIT_ASSERT_EQUAL(NORM_PYRA5,constMesh->getTypeOfCell(i)); - CPPUNIT_ASSERT_EQUAL(90,constMesh->getNodalConnectivity()->getNbOfElems()); - CPPUNIT_ASSERT_EQUAL(701,std::accumulate(constMesh->getNodalConnectivity()->getPointer(),constMesh->getNodalConnectivity()->getPointer()+90,0)); - CPPUNIT_ASSERT_EQUAL(711,std::accumulate(constMesh->getNodalConnectivityIndex()->getPointer(),constMesh->getNodalConnectivityIndex()->getPointer()+17,0)); - CPPUNIT_ASSERT_DOUBLES_EQUAL(46.,std::accumulate(constMesh->getCoords()->getPointer(),constMesh->getCoords()->getPointer()+57,0),1e-12); - field0->decrRef(); - // - MEDCouplingFieldDouble *field1=MEDLoader::ReadFieldDoubleCell(fileName,meshNames[0].c_str(),0,fieldsName[1].c_str(),its1[0].first,its1[0].second); - field1->checkCoherency(); - CPPUNIT_ASSERT(field1->getName()==fieldsName[1]); - CPPUNIT_ASSERT_EQUAL(3,field1->getNumberOfComponents()); - CPPUNIT_ASSERT_EQUAL(16,field1->getNumberOfTuples()); - const double expectedValues2[48]={1.,0.,1.,1.,0.,1.,1.,0.,1.,2.,1.,0.,2.,1.,0.,2.,1.,0.,3.,0.,1.,3.,0.,1.,3.,0.,1.,4.,1.,0.,4.,1.,0.,4.,1.,0.,6.,1.,1.,6.,0.,0.,5.,0.,0.,5.,1.,1.}; - double diffValue2[48]; - std::transform(field1->getArray()->getPointer(),field1->getArray()->getPointer()+48,expectedValues2,diffValue2,std::minus()); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::max_element(diffValue2,diffValue2+48),1e-12); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::min_element(diffValue2,diffValue2+48),1e-12); - constMesh=dynamic_cast(field1->getMesh()); - CPPUNIT_ASSERT(constMesh); - CPPUNIT_ASSERT_EQUAL(3,constMesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(3,constMesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(16,constMesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(19,constMesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(3,(int)constMesh->getAllTypes().size()); - for(int i=0;i<12;i++) - CPPUNIT_ASSERT_EQUAL(NORM_TETRA4,constMesh->getTypeOfCell(i)); - for(int i=12;i<14;i++) - CPPUNIT_ASSERT_EQUAL(NORM_HEXA8,constMesh->getTypeOfCell(i)); - for(int i=14;i<16;i++) - CPPUNIT_ASSERT_EQUAL(NORM_PYRA5,constMesh->getTypeOfCell(i)); - CPPUNIT_ASSERT_EQUAL(90,constMesh->getNodalConnectivity()->getNbOfElems()); - CPPUNIT_ASSERT_EQUAL(701,std::accumulate(constMesh->getNodalConnectivity()->getPointer(),constMesh->getNodalConnectivity()->getPointer()+90,0)); - CPPUNIT_ASSERT_EQUAL(711,std::accumulate(constMesh->getNodalConnectivityIndex()->getPointer(),constMesh->getNodalConnectivityIndex()->getPointer()+17,0)); - CPPUNIT_ASSERT_DOUBLES_EQUAL(46.,std::accumulate(constMesh->getCoords()->getPointer(),constMesh->getCoords()->getPointer()+57,0),1e-12); - field1->decrRef(); - //fields on nodes - std::vector fieldsNameNode=MEDLoader::GetNodeFieldNamesOnMesh(fileName,meshNames[0].c_str()); - CPPUNIT_ASSERT_EQUAL(2,(int)fieldsNameNode.size()); - CPPUNIT_ASSERT(fieldsNameNode[0]=="fieldnodedouble"); - CPPUNIT_ASSERT(fieldsNameNode[1]=="fieldnodeint"); - std::vector > its0Node=MEDLoader::GetNodeFieldIterations(fileName,fieldsNameNode[0].c_str()); - CPPUNIT_ASSERT_EQUAL(3,(int)its0Node.size()); - CPPUNIT_ASSERT_EQUAL(1,its0Node[0].first); - CPPUNIT_ASSERT_EQUAL(-1,its0Node[0].second); - CPPUNIT_ASSERT_EQUAL(2,its0Node[1].first); - CPPUNIT_ASSERT_EQUAL(-1,its0Node[1].second); - CPPUNIT_ASSERT_EQUAL(-1,its0Node[2].first);//strange but like that - CPPUNIT_ASSERT_EQUAL(-1,its0Node[2].second); - MEDCouplingFieldDouble *field0Nodes=MEDLoader::ReadFieldDoubleNode(fileName,meshNames[0].c_str(),0,fieldsNameNode[0].c_str(),its0Node[0].first,its0Node[0].second); - field0Nodes->checkCoherency(); - CPPUNIT_ASSERT(field0Nodes->getName()==fieldsNameNode[0]); - CPPUNIT_ASSERT_EQUAL(1,field0Nodes->getNumberOfComponents()); - CPPUNIT_ASSERT_EQUAL(19,field0Nodes->getNumberOfTuples()); - const double expectedValues3[19]={1.,1.,1.,2.,2.,2.,3.,3.,3.,4.,4.,4.,5.,5.,5.,6.,6.,6.,7.}; - double diffValue3[19]; - std::transform(field0Nodes->getArray()->getPointer(),field0Nodes->getArray()->getPointer()+19,expectedValues3,diffValue3,std::minus()); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::max_element(diffValue3,diffValue3+19),1e-12); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::min_element(diffValue3,diffValue3+19),1e-12); - constMesh=dynamic_cast(field0Nodes->getMesh()); - CPPUNIT_ASSERT(constMesh); - field0Nodes->decrRef(); - // - field0Nodes=MEDLoader::ReadFieldDoubleNode(fileName,meshNames[0].c_str(),0,fieldsNameNode[0].c_str(),its0Node[1].first,its0Node[1].second); - field0Nodes->checkCoherency(); - CPPUNIT_ASSERT(field0Nodes->getName()==fieldsNameNode[0]); - CPPUNIT_ASSERT_EQUAL(1,field0Nodes->getNumberOfComponents()); - CPPUNIT_ASSERT_EQUAL(19,field0Nodes->getNumberOfTuples()); - const double expectedValues4[19]={1.,2.,2.,2.,3.,3.,3.,4.,4.,4.,5.,5.,5.,6.,6.,6.,7.,7.,7.}; - std::transform(field0Nodes->getArray()->getPointer(),field0Nodes->getArray()->getPointer()+19,expectedValues4,diffValue3,std::minus()); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::max_element(diffValue3,diffValue3+19),1e-12); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::min_element(diffValue3,diffValue3+19),1e-12); - constMesh=dynamic_cast(field0Nodes->getMesh()); - CPPUNIT_ASSERT(constMesh); - CPPUNIT_ASSERT_EQUAL(3,constMesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(3,constMesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(16,constMesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(19,constMesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(3,(int)constMesh->getAllTypes().size()); - for(int i=0;i<12;i++) - CPPUNIT_ASSERT_EQUAL(NORM_TETRA4,constMesh->getTypeOfCell(i)); - for(int i=12;i<14;i++) - CPPUNIT_ASSERT_EQUAL(NORM_HEXA8,constMesh->getTypeOfCell(i)); - for(int i=14;i<16;i++) - CPPUNIT_ASSERT_EQUAL(NORM_PYRA5,constMesh->getTypeOfCell(i)); - CPPUNIT_ASSERT_EQUAL(90,constMesh->getNodalConnectivity()->getNbOfElems()); - CPPUNIT_ASSERT_EQUAL(701,std::accumulate(constMesh->getNodalConnectivity()->getPointer(),constMesh->getNodalConnectivity()->getPointer()+90,0)); - CPPUNIT_ASSERT_EQUAL(711,std::accumulate(constMesh->getNodalConnectivityIndex()->getPointer(),constMesh->getNodalConnectivityIndex()->getPointer()+17,0)); - CPPUNIT_ASSERT_DOUBLES_EQUAL(46.,std::accumulate(constMesh->getCoords()->getPointer(),constMesh->getCoords()->getPointer()+57,0),1e-12); - field0Nodes->decrRef(); - // - field0Nodes=MEDLoader::ReadFieldDoubleNode(fileName,meshNames[0].c_str(),0,fieldsNameNode[0].c_str(),its0Node[2].first,its0Node[2].second); - field0Nodes->checkCoherency(); - CPPUNIT_ASSERT(field0Nodes->getName()==fieldsNameNode[0]); - CPPUNIT_ASSERT_EQUAL(1,field0Nodes->getNumberOfComponents()); - CPPUNIT_ASSERT_EQUAL(19,field0Nodes->getNumberOfTuples()); - const double expectedValues5[19]={1.,1.,1.,2.,2.,2.,3.,3.,3.,4.,4.,4.,5.,5.,5.,6.,6.,6.,7.}; - std::transform(field0Nodes->getArray()->getPointer(),field0Nodes->getArray()->getPointer()+19,expectedValues5,diffValue3,std::minus()); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::max_element(diffValue3,diffValue3+19),1e-12); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::min_element(diffValue3,diffValue3+19),1e-12); - constMesh=dynamic_cast(field0Nodes->getMesh()); - CPPUNIT_ASSERT(constMesh); - CPPUNIT_ASSERT_EQUAL(3,constMesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(3,constMesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(16,constMesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(19,constMesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(3,(int)constMesh->getAllTypes().size()); - for(int i=0;i<12;i++) - CPPUNIT_ASSERT_EQUAL(NORM_TETRA4,constMesh->getTypeOfCell(i)); - for(int i=12;i<14;i++) - CPPUNIT_ASSERT_EQUAL(NORM_HEXA8,constMesh->getTypeOfCell(i)); - for(int i=14;i<16;i++) - CPPUNIT_ASSERT_EQUAL(NORM_PYRA5,constMesh->getTypeOfCell(i)); - CPPUNIT_ASSERT_EQUAL(90,constMesh->getNodalConnectivity()->getNbOfElems()); - CPPUNIT_ASSERT_EQUAL(701,std::accumulate(constMesh->getNodalConnectivity()->getPointer(),constMesh->getNodalConnectivity()->getPointer()+90,0)); - CPPUNIT_ASSERT_EQUAL(711,std::accumulate(constMesh->getNodalConnectivityIndex()->getPointer(),constMesh->getNodalConnectivityIndex()->getPointer()+17,0)); - CPPUNIT_ASSERT_DOUBLES_EQUAL(46.,std::accumulate(constMesh->getCoords()->getPointer(),constMesh->getCoords()->getPointer()+57,0),1e-12); - field0Nodes->decrRef(); -} - -void ParaMEDMEMTest::testMEDLoaderPolygonRead() -{ - string medRootDir=getenv("MED_ROOT_DIR"); - medRootDir+="/share/salome/resources/med/polygones.med"; - const char *fileName=medRootDir.c_str(); - vector meshNames=MEDLoader::GetMeshNames(fileName); - CPPUNIT_ASSERT_EQUAL(1,(int)meshNames.size()); - CPPUNIT_ASSERT(meshNames[0]=="Bord"); - MEDCouplingUMesh *mesh=MEDLoader::ReadUMeshFromFile(fileName,meshNames[0].c_str(),0); - mesh->checkCoherency(); - CPPUNIT_ASSERT_EQUAL(3,mesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(2,mesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(538,mesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(579,mesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(2,(int)mesh->getAllTypes().size()); - for(int i=0;i<514;i++) - CPPUNIT_ASSERT_EQUAL(NORM_QUAD4,mesh->getTypeOfCell(i)); - for(int i=514;i<538;i++) - CPPUNIT_ASSERT_EQUAL(NORM_POLYGON,mesh->getTypeOfCell(i)); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,std::accumulate(mesh->getCoords()->getPointer(),mesh->getCoords()->getPointer()+1737,0),1e-12); - const double expectedVals1[12]={1.4851585216522212,-0.5,0.,1.4851585216522212,-0.4,0.,1.4851585216522212,-0.3,0., 1.5741585216522211, -0.5, 0. }; - double diffValue1[12]; - std::transform(mesh->getCoords()->getPointer(),mesh->getCoords()->getPointer()+12,expectedVals1,diffValue1,std::minus()); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::max_element(diffValue1,diffValue1+12),1e-12); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::min_element(diffValue1,diffValue1+12),1e-12); - CPPUNIT_ASSERT_EQUAL(2768,mesh->getNodalConnectivity()->getNbOfElems()); - CPPUNIT_ASSERT_EQUAL(651050,std::accumulate(mesh->getNodalConnectivity()->getPointer(),mesh->getNodalConnectivity()->getPointer()+2768,0)); - CPPUNIT_ASSERT_EQUAL(725943,std::accumulate(mesh->getNodalConnectivityIndex()->getPointer(),mesh->getNodalConnectivityIndex()->getPointer()+539,0)); - mesh->decrRef(); - // - std::vector fieldsName=MEDLoader::GetCellFieldNamesOnMesh(fileName,meshNames[0].c_str()); - CPPUNIT_ASSERT_EQUAL(3,(int)fieldsName.size()); - CPPUNIT_ASSERT(fieldsName[0]=="bord_:_distorsion"); - CPPUNIT_ASSERT(fieldsName[1]=="bord_:_familles"); - CPPUNIT_ASSERT(fieldsName[2]=="bord_:_non-ortho"); - std::vector > its0=MEDLoader::GetCellFieldIterations(fileName,fieldsName[0].c_str()); - CPPUNIT_ASSERT_EQUAL(1,(int)its0.size()); - MEDCouplingFieldDouble *field=MEDLoader::ReadFieldDoubleCell(fileName,meshNames[0].c_str(),0,fieldsName[0].c_str(),its0[0].first,its0[0].second); - field->checkCoherency(); - CPPUNIT_ASSERT(field->getName()==fieldsName[0]); - CPPUNIT_ASSERT_EQUAL(1,field->getNumberOfComponents()); - CPPUNIT_ASSERT_EQUAL(538,field->getNumberOfTuples()); - const MEDCouplingUMesh *constMesh=dynamic_cast(field->getMesh()); - CPPUNIT_ASSERT(constMesh); - CPPUNIT_ASSERT_EQUAL(3,constMesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(2,constMesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(538,constMesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(579,constMesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(2,(int)constMesh->getAllTypes().size()); - for(int i=0;i<514;i++) - CPPUNIT_ASSERT_EQUAL(NORM_QUAD4,constMesh->getTypeOfCell(i)); - for(int i=514;i<538;i++) - CPPUNIT_ASSERT_EQUAL(NORM_POLYGON,constMesh->getTypeOfCell(i)); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,std::accumulate(constMesh->getCoords()->getPointer(),constMesh->getCoords()->getPointer()+1737,0),1e-12); - std::transform(constMesh->getCoords()->getPointer(),constMesh->getCoords()->getPointer()+12,expectedVals1,diffValue1,std::minus()); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::max_element(diffValue1,diffValue1+12),1e-12); - CPPUNIT_ASSERT_DOUBLES_EQUAL(0.,*std::min_element(diffValue1,diffValue1+12),1e-12); - CPPUNIT_ASSERT_EQUAL(2768,constMesh->getNodalConnectivity()->getNbOfElems()); - CPPUNIT_ASSERT_EQUAL(651050,std::accumulate(constMesh->getNodalConnectivity()->getPointer(),constMesh->getNodalConnectivity()->getPointer()+2768,0)); - CPPUNIT_ASSERT_EQUAL(725943,std::accumulate(constMesh->getNodalConnectivityIndex()->getPointer(),constMesh->getNodalConnectivityIndex()->getPointer()+539,0)); - const double *values=field->getArray()->getPointer(); - CPPUNIT_ASSERT_DOUBLES_EQUAL(2.87214203182918,std::accumulate(values,values+538,0.),1e-12); - field->decrRef(); -} - -void ParaMEDMEMTest::testMEDLoaderPolyhedronRead() -{ - string medRootDir=getenv("MED_ROOT_DIR"); - medRootDir+="/share/salome/resources/med/poly3D.med"; - const char *fileName=medRootDir.c_str(); - vector meshNames=MEDLoader::GetMeshNames(fileName); - CPPUNIT_ASSERT_EQUAL(1,(int)meshNames.size()); - CPPUNIT_ASSERT(meshNames[0]=="poly3D"); - MEDCouplingUMesh *mesh=MEDLoader::ReadUMeshFromFile(fileName,meshNames[0].c_str(),0); - mesh->checkCoherency(); - CPPUNIT_ASSERT_EQUAL(3,mesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(3,mesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(3,mesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(19,mesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(2,(int)mesh->getAllTypes().size()); - CPPUNIT_ASSERT_EQUAL(NORM_TETRA4,mesh->getTypeOfCell(0)); - CPPUNIT_ASSERT_EQUAL(NORM_POLYHED,mesh->getTypeOfCell(1)); - CPPUNIT_ASSERT_EQUAL(NORM_POLYHED,mesh->getTypeOfCell(2)); - CPPUNIT_ASSERT_EQUAL(98,mesh->getNodalConnectivity()->getNbOfElems()); - CPPUNIT_ASSERT_EQUAL(725,std::accumulate(mesh->getNodalConnectivity()->getPointer(),mesh->getNodalConnectivity()->getPointer()+98,0)); - CPPUNIT_ASSERT_DOUBLES_EQUAL(110.,std::accumulate(mesh->getCoords()->getPointer(),mesh->getCoords()->getPointer()+57,0),1e-12); - CPPUNIT_ASSERT_EQUAL(155,std::accumulate(mesh->getNodalConnectivityIndex()->getPointer(),mesh->getNodalConnectivityIndex()->getPointer()+4,0)); - mesh->decrRef(); - // - mesh=MEDLoader::ReadUMeshFromFile(fileName,meshNames[0].c_str(),-1); - mesh->checkCoherency(); - CPPUNIT_ASSERT_EQUAL(3,mesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(2,mesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(17,mesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(19,mesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(3,(int)mesh->getAllTypes().size()); - for(int i=0;i<6;i++) - CPPUNIT_ASSERT_EQUAL(NORM_TRI3,mesh->getTypeOfCell(i)); - for(int i=6;i<14;i++) - CPPUNIT_ASSERT_EQUAL(NORM_QUAD4,mesh->getTypeOfCell(i)); - for(int i=14;i<17;i++) - CPPUNIT_ASSERT_EQUAL(NORM_POLYGON,mesh->getTypeOfCell(i)); - CPPUNIT_ASSERT_DOUBLES_EQUAL(110.,std::accumulate(mesh->getCoords()->getPointer(),mesh->getCoords()->getPointer()+57,0),1e-12); - CPPUNIT_ASSERT_EQUAL(83,mesh->getNodalConnectivity()->getNbOfElems()); - CPPUNIT_ASSERT_EQUAL(619,std::accumulate(mesh->getNodalConnectivity()->getPointer(),mesh->getNodalConnectivity()->getPointer()+83,0)); - mesh->decrRef(); - // - vector families=MEDLoader::GetMeshFamilyNames(fileName,meshNames[0].c_str()); - CPPUNIT_ASSERT_EQUAL(4,(int)families.size()); - CPPUNIT_ASSERT(families[0]=="FAMILLE_FACE_POLYGONS3"); - CPPUNIT_ASSERT(families[1]=="FAMILLE_FACE_QUAD41"); - CPPUNIT_ASSERT(families[2]=="FAMILLE_FACE_TRIA32"); - CPPUNIT_ASSERT(families[3]=="FAMILLE_ZERO"); - vector families2; - families2.push_back(families[0]); - mesh=MEDLoader::ReadUMeshFromFamilies(fileName,meshNames[0].c_str(),-1,families2); - mesh->checkCoherency(); - CPPUNIT_ASSERT_EQUAL(3,mesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(2,mesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(3,mesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(19,mesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(1,(int)mesh->getAllTypes().size()); - for(int i=0;i<3;i++) - CPPUNIT_ASSERT_EQUAL(NORM_POLYGON,mesh->getTypeOfCell(i)); - CPPUNIT_ASSERT_EQUAL(19,mesh->getNodalConnectivity()->getNbOfElems()); - CPPUNIT_ASSERT_EQUAL(117,std::accumulate(mesh->getNodalConnectivity()->getPointer(),mesh->getNodalConnectivity()->getPointer()+19,0)); - mesh->decrRef(); - // - mesh=MEDLoader::ReadUMeshFromFamilies(fileName,meshNames[0].c_str(),0,families2); - CPPUNIT_ASSERT_EQUAL(3,mesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(0,mesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(19,mesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(3,mesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(0,(int)mesh->getAllTypes().size()); - mesh->decrRef(); -} - -void ParaMEDMEMTest::testMEDLoaderWrite1() -{ - const char meshName[]="MEDLoaderWrite1"; - string tmpRootDir=getenv("TMP"); - string outFileName=tmpRootDir+"/toto22137.med"; - double targetCoords[18]={-0.3,-0.3, 0.2,-0.3, 0.7,-0.3, -0.3,0.2, 0.2,0.2, 0.7,0.2, -0.3,0.7, 0.2,0.7, 0.7,0.7 }; - int targetConn[18]={0,3,4,1, 1,4,2, 4,5,2, 6,7,4,3, 7,8,5,4}; - MEDCouplingUMesh *mesh=MEDCouplingUMesh::New(); - mesh->setMeshDimension(2); - mesh->allocateCells(5); - mesh->insertNextCell(INTERP_KERNEL::NORM_QUAD4,4,targetConn); - mesh->insertNextCell(INTERP_KERNEL::NORM_TRI3,3,targetConn+4); - mesh->insertNextCell(INTERP_KERNEL::NORM_TRI3,3,targetConn+7); - mesh->insertNextCell(INTERP_KERNEL::NORM_QUAD4,4,targetConn+10); - mesh->insertNextCell(INTERP_KERNEL::NORM_QUAD4,4,targetConn+14); - mesh->finishInsertingCells(); - DataArrayDouble *myCoords=DataArrayDouble::New(); - myCoords->alloc(9,2); - std::copy(targetCoords,targetCoords+18,myCoords->getPointer()); - mesh->setCoords(myCoords); - myCoords->decrRef(); - mesh->checkCoherency(); - CPPUNIT_ASSERT_EQUAL(2,mesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(2,mesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(5,mesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(9,mesh->getNumberOfNodes()); - bool normalThrow=false; - try - { - MEDLoader::writeUMesh(outFileName.c_str(),mesh); - } - catch(INTERP_KERNEL::Exception& e) - { - normalThrow=true; - } - CPPUNIT_ASSERT(normalThrow); - mesh->setName(meshName); - MEDLoader::writeUMesh(outFileName.c_str(),mesh); - mesh->decrRef(); - // - mesh=MEDLoader::ReadUMeshFromFile(outFileName.c_str(),meshName,0); - CPPUNIT_ASSERT_EQUAL(2,mesh->getSpaceDimension()); - CPPUNIT_ASSERT_EQUAL(2,mesh->getMeshDimension()); - CPPUNIT_ASSERT_EQUAL(5,mesh->getNumberOfCells()); - CPPUNIT_ASSERT_EQUAL(9,mesh->getNumberOfNodes()); - CPPUNIT_ASSERT_EQUAL(2,(int)mesh->getAllTypes().size()); - for(int i=0;i<2;i++) - CPPUNIT_ASSERT_EQUAL(NORM_TRI3,mesh->getTypeOfCell(i)); - for(int i=2;i<5;i++) - CPPUNIT_ASSERT_EQUAL(NORM_QUAD4,mesh->getTypeOfCell(i)); - CPPUNIT_ASSERT_DOUBLES_EQUAL(3.6,std::accumulate(mesh->getCoords()->getPointer(),mesh->getCoords()->getPointer()+18,0.),1.e-12); - mesh->decrRef(); -} - -void ParaMEDMEMTest::testMEDLoaderPolygonWrite() -{ - string medRootDir=getenv("MED_ROOT_DIR"); - medRootDir+="/share/salome/resources/med/polygones.med"; - const char *fileName=medRootDir.c_str(); - vector meshNames=MEDLoader::GetMeshNames(fileName); - CPPUNIT_ASSERT_EQUAL(1,(int)meshNames.size()); - CPPUNIT_ASSERT(meshNames[0]=="Bord"); - MEDCouplingUMesh *mesh=MEDLoader::ReadUMeshFromFile(fileName,meshNames[0].c_str(),0); - mesh->checkCoherency(); - string tmpRootDir=getenv("TMP"); - string outFileName=tmpRootDir+"/toto22138.med"; - MEDLoader::writeUMesh(outFileName.c_str(),mesh); - // - MEDCouplingUMesh *mesh2=MEDLoader::ReadUMeshFromFile(outFileName.c_str(),meshNames[0].c_str(),0); - // - mesh2->decrRef(); - mesh->decrRef(); -} diff --git a/src/ParaMEDMEM/Test/test_perf.cxx b/src/ParaMEDMEM/Test/test_perf.cxx deleted file mode 100644 index 30e921527..000000000 --- a/src/ParaMEDMEM/Test/test_perf.cxx +++ /dev/null @@ -1,317 +0,0 @@ -#include -#include -#include -#include "ParaMEDMEMTest.hxx" -#include - -#include "CommInterface.hxx" -#include "ProcessorGroup.hxx" -#include "MPIProcessorGroup.hxx" -#include "Topology.hxx" -#include "DEC.hxx" -#include "MxN_Mapping.hxx" -#include "IntersectionDEC.hxx" -#include "ParaMESH.hxx" -#include "ParaFIELD.hxx" -#include "ComponentTopology.hxx" -#include "ICoCoMEDField.hxx" -#include "MEDLoader.hxx" - -#include - -// use this define to enable lines, execution of which leads to Segmentation Fault -#define ENABLE_FAULTS - -// use this define to enable CPPUNIT asserts and fails, showing bugs -#define ENABLE_FORCED_FAILURES - -#ifndef CLK_TCK -#include -#define CLK_TCK sysconf(_SC_CLK_TCK); -#endif - -using namespace std; -using namespace ParaMEDMEM; - -void testIntersectionDEC_2D(const string& filename1, const string& meshname1, - const string& filename2, const string& meshname2, - int nproc_source, double epsilon, bool tri, bool all); -void get_time( float *telps, float *tuser, float *tsys, float *tcpu ); - -int main(int argc, char *argv[]) -{ - string filename1, filename2; - string meshname1, meshname2; - int nproc_source=1, rank; - double epsilon=1.e-6; - int count=0; - bool tri=false; - bool all=false; - - MPI_Init(&argc,&argv); - - for(int i=1;i self_procs; - set procs_source; - set procs_target; - - for (int i=0; icontainsMyRank()){ - string master = filename_xml1; - - ostringstream strstream; - if( nproc_source == 1 ) - strstream <getNumberOfCells(); - double *value=parafield->getField()->getArray()->getPointer(); - for(int ielem=0; ielemcontainsMyRank()){ - string master= filename_xml2; - ostringstream strstream; - if( (size-nproc_source) == 1 ) - strstream << master<<".med"; - else - strstream << master<<(rank-nproc_source+1)<<".med"; - ostringstream meshname ; - if( (size-nproc_source) == 1 ) - meshname<< meshname2; - else - meshname<< meshname2<<"_"<incrRef(); - - paramesh=new ParaMESH (mesh,*target_group,"target mesh"); - ParaMEDMEM::ComponentTopology comptopo; - parafield = new ParaFIELD(ON_CELLS,NO_TIME,paramesh, comptopo); - - int nb_local=mesh->getNumberOfCells(); - double *value=parafield->getField()->getArray()->getPointer(); - for(int ielem=0; ielemcontainsMyRank()){ - field_before_int = parafield->getVolumeIntegral(0); - get_time( &telps, &tcpu_u, &tcpu_s, &tcpu ); - dec.synchronize(); - get_time( &telps, &tcpu_u, &tcpu_s, &tcpu ); - if( rank == 0 ) - cout << "SYNCHRONIZE : Telapse = " << telps << " TuserCPU = " << tcpu_u << " TsysCPU = " << tcpu_s << " TCPU = " << tcpu << endl; - cout<<"DEC usage"<