1. 28 Jan, 2021 1 commit
  2. 13 Jan, 2021 1 commit
    • Alexis SALZMAN's avatar
      [XFEM] change API of LOCALVECTOR concept (xAssembler concept) · 1a4cd3f6
      Alexis SALZMAN authored
      This commit pass from () to [] operator for LOCALVECTOR concept of
      xAssembler concept. This is opening usage of assemble_vector method
      to a wider range of container types. LOCALVECTOR may now be a
      xCSRVector or a std::vector for example. xFemVector having both
      operator remains functional (maybe () operator should be removed now ?).
      Some comments are added to try to clarify LOCALVECTOR and LOCALMATRIX
  3. 28 Sep, 2020 2 commits
    • Benoît LÉ's avatar
      [xFEM] Forgot to use xtool::xDataType<S>::zero() in xAssemblerLumpedBlockEqu... · 0c0aaefa
      Benoît LÉ authored
      [xFEM] Forgot to use xtool::xDataType<S>::zero() in xAssemblerLumpedBlockEqu and xAssemblerLumpedBlockEquInVector
    • Benoît LÉ's avatar
      [xFEM] Added xAssemblerLumpedBlockEqu and xAssemblerLumpedBlockEquInVector. · d5c4a868
      Benoît LÉ authored
      These assemblers can be used to assemble lumped matrix. They will both do the same thing, aside from
      the fact that xAssemblerLumpedBlockEquInVector will assemble in a vector containing the diagonal coeffcients
      of the lumped matrix (so it will be used with a bilinear form to assemble in a vector).
      These assemblers take each block of the assembled matrix, compute the average and assemble it on the corresponding diagonal coefficients.
      For instance, the lumped version of the following matrix
          [a b 0 0]
          [c d 0 0]
          [0 0 e f]
          [0 0 g h]
      would be
          [m1 0  0  0]
          [0  m1 0  0]
          [0  0  m2 0]
          [0  0  0 m2]
      where m1 = (a+b+c+d)/4 and  m2 = (e+f+g+h)/4
      They are not supposed to be used with vectors, so (for now) the assemble_vector gives a throw.
  4. 27 Jan, 2020 1 commit
    • Grégory LEGRAIN's avatar
      Let there be template fields ! · 3cc692f4
      Grégory LEGRAIN authored
      This is a first implementation of template fields in eXlibris.
      Thanks a lot to Alexis (@asalzman) and Nicolas (@nchevaugeon) for fruitful discussions !
      Fields can now handle other quantities than double (complex for instance).
      This has led to multiple changes:
      * xDoubleManager disappears
      * xValueDouble disappears
      * Assembly is now templatized
      However, the changes are small with respect to the interface in your applications (see the testcases).
          Notable changes
      Is replaced by  xValueManagerDist<T> ("Dist" stands for "distributed"). This template class handles other values  than double.
      Example : xValueManagerDist<double> value_manager;
      In your end-user code (AND NOWHERE ELSE), you can define a convenient typedef :
      using  xDoubleManager = xValueManagerDist<double>;
      xValueDouble is replaced by xSingleValue<T> where T stands for the type which is stored.
      Move value creators in xValueCreators.h
      is now template (should not influence end-user code)
      xStateDofCreator, xStateFixedCreator are also template.
      now template against the approximated quantity: xField<double> for a double-valued field
      Major internal modifications: "everything" is handled by the specialization of getVal and getGrad. For example:
      template <class iterFct, class iterVal>
      static void getVal (iterFct it, iterFct ite, iterVal first, iterVal last, int size_Fct_Val,
                    const xGeomElem* geo_appro, const xGeomElem* geo_integ, std::complex<double>& v);
      xFormBilinear, xFormLinear:
      A new template is added (double by default):
      template <typename VT = double> class xFormBilinear;
      It corresponds to the type of quantity which is stored in the elementary stiffness matrices (note that xFemMatrix and other are now template). Usually, you can keep it as double, but this is not mandatory (see BUILD_COMPLEX_VALUED_OPERATORS in test case complex2d).
      xAssembler, xAssemblerTraitPolicy, xDispatcher are modified to take into account the other changes.
      An example of complex-valued field is given in Xtest/xfem-para-test/complex2d (however, see issue #58)
      KNOWN limitations/issues (that will be fixed later on):
      * type dependent code in xField is still part of the class. We should try to move this code away from the core of the class (issue #60).
      * float and complex version of mumps are still not available, so you cannot fully run any float or complex testcases for the moment  (see issue #58)
      * the compiler on titan (gcc 4.8) has troubles during template deduction for some template functions (DeclareInterpolation, DeclareState), see issue #59. The syntax had to be modified in order to help the compiler, leading to verbose notations.
  5. 14 Jun, 2019 1 commit
    • Gilles MARCKMANN's avatar
      refactoring 2019: renames namespace, creates new directories, ... · e6039c6a
      Gilles MARCKMANN authored
          rename directory and namespaces. Modifications below:
          Original directory (Master)    ->             New directory (refactoring)                 Namespace (refactoring)
          ===========================                   ===========================                 =======================
             |_eXlibris_tools                           xTool                                     xtool::
             |                                          xUtil
             |_cmakeUtile                                   |_cmakeUtile
             |_FloUtil                                      attic
             |_Split                                        attic
             |_doxygen_tools                                attic
             |_tags_tools                                   attic
          Xcrack                                        xCrack
               |_ xCrack                                     |_ src                               xcrack::
               |_ xCrackFMM                                  attic
          Xcut                                          xCut
             |_XdoubleCut                                  |_xDoubleCut                           xcut::
          Xdomaindecomp                                 xDomainDecomp
                      |_DomainManager                               |_DomainManager               xdomaindecomp::
                      |_Solvers                                     |_Solver                      xdomaindecomp::
             |_AnalyicalSolutions                       xAnalyticalSolution
             |                  |_Elastic2D                               |_Elastic2D             xanalyticalsolution::
             |_Xext                                     xExt
                  |_src                                    |_src                                  xext::
                  |_ImageProcessing                        attic
             |_Xfem ___________________________________ xFEM                                      xfem::
                                               \_______ xCut
                                                \          |_xLegacySimpleCut                     xcut::
                                                  \____ xExport                                   xexport::
                                                   \___ xTensor                                   xtensor::
                                                    \__ xMapping                                  xmapping
                                                     \_ xQuadrature                               xquadrature::
          FastMarching                                  xFastMarching
                     |_src                                          |_src                         xfastmarching::
                     |   |_FMSkeleton                               |   |_Skeleton                xfastmarching::skeleton
                     |                                              |
                     |_xDistFM                                      |_xDistFM                     xfastmarching::
                             |_xDistFM                                      |_src                 xfastmarching::
          Geom                                          xGeom                                     xgeom::
          Xinterfaces                                   xInterface
                    |_XAOMDInterface                             |_AOMD                           xinterface::aomd::
                    |                                            |
                    |_GraphInterface                             |_Graph
                    |              |_ParMetis                    |     |_ParMetis                 xinterface::parmetis::
                    |                                            |
                    |_XoctreeInterface                           |_xOctree                        xinterface::xoctree::
                    |                                                    |
                    |_xSplitMeshInterface                                |_xTemplateRefineMesh    xinterface::xtempaterefinemesh::
                    |_SolverInterfaces                   xLinAlg
                                     |_SolverBase              |_SolverBase                       xlinalg::
                                     |_SuperLu                 |_xInterfaceSuperLu                xlinalg::
                                     |_Taucs                   |_xInterfaceTaucs                  xlinalg::
                                     |_Lapack                  |_xInterfaceTaucs                  xlinalg::
                                     |_Mumps                   |_xInterfaceMumps                  xlinalg::
                                     |_BasicIterSolver         |_xInterfaceBasicIterSolver        xlinalg::
                                     |_Pastix                  |_xInterfacePastix                 xlinalg::
                                     |_NonLinearSolver         attic
                                     |_PetscParallel           attic
                                     |_PetscSeq                attic
                                     |_SparsKit                attic
                                     |_Itl                     attic
                                     |_Mtl                     attic
                                     |_KSPParallel             attic
          MeshMachine                                   xMeshTools
                    |_DistMesh                                   |_xDistMesh                      xmeshtool::
                    |_SplitMesh                                  |_xTemplateRefineMesh            xmeshtool::
                    |_FastMarching                               attic
                    |_LinearAlgebra                              attic
                    |_Stlmesh                                    attic
          Octree                                        xOctree                                   xoctree::
                |_Physics                               xPhysics
                        |_Materials                            |_Materials                        xphysics::
                        |_src                                  |_src                              xphysics::
             |_xTLS                                     xTLS                                      xtls::
          Xfem splitting:
                 |__ xDoubleCut
                 |             |__(unchanged)
                 |__ xLegacySimpleCut
                                    |__ xPhysSurfByTagging.cc
                                    |__ xPhysSurfByTagging.h
                                    |__ xPhysSurf.cc
                                    |__ xPhysSurf.h
                                    |__ xPhysSurfParameter.cc
                                    |__ xPhysSurfParameter.h
                                    |__ xRefCut.cc
                                    |__ xRefCut.h
                                    |__ xRefCutToAOMD.cc
                                    |__ xRefCutToAOMD.h
                                    |__ xRefCutToIsoZeroVector.cc
                                    |__ xRefCutToIsoZeroVector.h
                                    |__ xRefMesh.cc
                                    |__ xRefMesh.h
                    |__ xExport.cc
                    |__ xExportEnsight.cc
                    |__ xExportEnsight.h
                    |__ xExportGmsh.cc
                    |__ xExportGmsh.h
                    |__ xExportGmsh_imp.h
                    |__ xExport.h
                    |__ xExportManager.cc
                    |__ xExportManager.h
                    |__ xExportTranslate.cc
                    |__ xExportTranslate.h
                    |__ xPostPro.cc
                    |__ xPostPro.h
                    |__ xPostProMSH.cc
                    |__ xPostProMSH.h
                    |__ xPostProVTU.cc
                    |__ xPostProVTU.h
                    |__ xSensors.cc
                    |__ xSensors.h
                    |__ xPoint.h
                    |__ xTensor2.cc
                    |__ xTensor2.h
                    |__ xTensor2Sym.cc
                    |__ xTensor2Sym.h
                    |__ xTensor3.h
                    |__ xTensor4.h
                    |__ xTensorOperations.h
                    |__ xVector.cc
                    |__ xVector.h
                    |__ xVectorScalarProd.h
          cmake variables rules for module Xfiles/xFoe (no more Xfiles/Xfoe) :
                Xfiles/xFoe  => find_package(xFoe)  => xFoe_INCLUDE_DIR  / xFoe_LIBRARIES
          in C++ source files, namespace are in lower cases: xfoe
          New xfastmarching namespace have been introduced but pack/unPack helping function
          must remain in :: namescpace (i.e. in no namescpace). This is to let FMupdaterGeneric
          call ::pack  ::unPack in a generic way (no assumption on VECT or TRANSPORTED
          Macro Super for SuperLU 5 (experimental ) added in xinterface superlu
          modifiyed xCSRVector.h and cc so that the .h does not include xBlasDef.h since it can produce conflict when including xVector.h in superLU interface
  6. 25 Feb, 2019 1 commit
  7. 21 Mar, 2017 1 commit
    • Grégory LEGRAIN's avatar
      Set of commits to modernize the code to C++11. · 37189545
      Grégory LEGRAIN authored
          * use nullptr for more safety
          * fix deprecated headers
          Everything was done using clang-tidy.
          /usr/share/clang/run-clang-tidy.py -header-filter='.*' -checks='-*,modernize-use-nullptr' -fix
          /usr/share/clang/run-clang-tidy.py -header-filter='.*' -checks='-*,modernize-deprecated-headers' -fix
  8. 27 May, 2016 3 commits
  9. 08 Jun, 2015 1 commit
  10. 07 May, 2015 1 commit
    • Nicolas CHEVAUGEON's avatar
      · 90f01553
      Nicolas CHEVAUGEON authored
      The initial goal of the following changes was to deliver new implementations of BilinearForm that are potentially faster for large finite element space and or high number of integration points. They can be found in the new file xFormOptimized.h. These new bilinear forms use BLAS intensivelly in order to speed up the computation of elementary matrices. Measurement  were done  solving 3d mechanical problems with high order shape function. Results are quite good since speedup from to 2 up to 4 were measured in the assembly time of the global finite element problem.
      I tryed as much as possible to make this new implementations easy to use, but to do that I had to make a number of changes in the library. In the following I try to explain my design choices :
         As previously mensionned, I used blas a lot in the new bilinearform. But BLAS is made to work with column major matrix. We do have a column major matrix type in the library inside xDenseMatrix, with interfaces to blas. Up to now, Bilinear form was storing the finite element matrix in the xFemMatrix class which is row major and does not have much function to work with.
      To avoid to copy and or changes format of the matrices, I had to implement the new forms so that they return an xDenseMatrix when calling getMatrix(). This was breaking the interface of the xBilinearForm, so that :
       1/ The new BilinearForm do not derive from xBilinearForm.
       2/ the Assemblers (xAssemblerXXXX) should now be able to take a    xFemMatrix and or a xDenseMatrix.
      In order to permit that, the assemble member functions of xAssembler are now template on the matrix type passed to them. Since they are now template, they cannot be virtual anymore. That's why there are no more base class xAssembler in xAssembler.h
      All the classes defined in xAssembler have been rewritten. all the assemble_xxx function, used by the Assemble algorithm (see xAlgorithm.h), are now template on the type of per element data passed to them. Previously each assembler had the following 4 member function :
      void assemble(iterDof, iterDof, iterDof, iterDof, const xFemMatrix &)
      void assemble(iterDof, iterDof, const xFemMatrix &)
      void assemble(iterDof, iterDof, const xFemVector &)
      void assemble(const double &)
      They are replaced by 
      template <class LOCALMATRIX>
      void assemble_matrix(iterDof, iterDof, iterDof, iterDof, const LOCALMATRIX &)
      template <class LOCALMATRIX>
      void assemble_matrix(iterDof, iterDof, const LOCALMATRIX &)
      template <class LOCALVECTOR>
      void assemble_vector(iterDof, iterDof, const LOCALVECTOR &)
      template <class LOCALSCALAR>
      void assemble_scalar(const LOCALSCALAR &)
      Note that to avoid ambiguity I had to change the name of these functions.
      We gain the possibility of assembling any type of Matrix, vector etc ... and also the possibility to optimize the assemble function for different type of matrix by template specialization. We loose  some runtime polymorphism with the disparition of the xAssembler base class. 
      A side effect is that all the algorithms that needs to refer to an assembler have been modifyied to be template on the assembler type. For most user it will change nothing for algorithm defined in the Xfem library : I updated them all, and no change are needed in client codes.
      If you defined your own algorithm refering to an object of the xAssembler base class, you need to rewrite them. usually it amount to make them template on the xAssembler class.
       The good point is that it's now much easier to try new assembler since one do not need to derive from the xAssembler base class any more.
      While modifying the Assemble type algorithm, I used the opportunity to remove all references and specials actions at the Assemble level to the eventual symmetry of the BilinearForm: this referecence or action are now defered to the Form as it should be. 
      Now a typical usage of a form in an algorithm is to first call init(...) on it, then a certain number of accumulate() (usually via the xintegrateFormCommand) then a call to finalize(), before retriving the elementary matrix and pass it to the assembler.
      It's now up to the finalize() member function of the Bilinear form to do all needed work to make sure the Matrix is ready to be assembled (Typically we used to symmetrize some matrix in some case depending on the bilinearfoerm, inside the Assemble algorithm, now this  would be done  during the call to finalize() ) This changes could be usefull later in multithreading contexts.
      There are also some minor changes in xVector, xTensor2 and xTensor4 : a common way to access directly to the data of each of the instance of these class, some function to compute factorization of xTensor2 ,xTensor4 and xTensor4Isotropic (see choleskyL and choleskyU), a function to compute a product of 2 xTensor4, a function to compute a norm of a xTensor4
      The output of an xTEnsor4 on a stream has been chaged so that the it is now printed in the usuall ijkl order and not ikjl
      The previous changes have been propagated in Physics/ and Xcrack/
      That's it (mostly) for this commit.
      M    Physics/Physics/src/xpElastic.cc
      M    Physics/Physics/src/xpElastic.h
      M    Physics/Physics/src/xpFluidMechanics.cc
      M    Physics/Physics/src/xpFluidMechanics.h
      M    Physics/Physics/src/xpPhysicalFormulation.h
      M    Physics/Physics/src/xpThermic.cc
      M    Physics/Physics/src/xpThermic.h
      M    Xcrack/Xcrack/src/JintParks.h
      M    Xcrack/Xcrack/src/xcInteractionIntegralsOnCrack.cc
      M    Xcrack/Xcrack/src/xcInteractionIntegralsOnCrack.h
      M    Xfem/Xfem/src/xAlgorithm.h
      M    Xfem/Xfem/src/xApproxFunctionHighOrder.cc
      M    Xfem/Xfem/src/xApproxFunctionHighOrder.h
      D    Xfem/Xfem/src/xAssembler.cc
      M    Xfem/Xfem/src/xAssembler.h
      D    Xfem/Xfem/src/xAssembler_imp.h
      M    Xfem/Xfem/src/xChrono.cc
      M    Xfem/Xfem/src/xFemMatrix.h
      M    Xfem/Xfem/src/xForm.cc
      M    Xfem/Xfem/src/xForm.h
      A    Xfem/Xfem/src/xFormOptimized.h
      M    Xfem/Xfem/src/xNonLocalInfoForKeysAndFcts_imp.h
      M    Xfem/Xfem/src/xSpacePolynomial.cc
      M    Xfem/Xfem/src/xSpacePolynomial.h
      M    Xfem/Xfem/src/xTensor2.cc
      M    Xfem/Xfem/src/xTensor2.h
      M    Xfem/Xfem/src/xTensor4.h
      M    Xfem/Xfem/src/xValueCreatorLinkOnFrontFiltered_imp.h
      M    Xfem/Xfem/src/xVector.h
      git-svn-id: https://svn.ec-nantes.fr/eXlibris/Xfiles@1112 05fba31e-542e-4c34-abd9-da38eceff631
  11. 27 Apr, 2012 1 commit
    • Grégory LEGRAIN's avatar
      Bug corrections : · bbfdbd59
      Grégory LEGRAIN authored
      xData.cc : fix compiler warnings
      xFactory.h : better message when throwing
      xOperators.h : fix compiler warnings
      xTensor2Sym.h : correct out of bounds initialization
      xTensors.cc : fix compiler warnings
      New features :
      * xLevelSet.cc : new operator =
      * xExport.cc,h : Implement recurSplit for Quads and Hex
      * xAssembler.h, xAssembler_imp.h : add assemble method for xFemVector : 
      assemble(iterDof first, iterDof last, const xFemVector& vect)
      * xApproxFunctionHighOrderQH.h, cc, xSpacePolynomialQH.h, cc : p-What-You-Want Lagrange space 
      on Quads and Hexs. Note that for the moment, it is impossible to mix simplex and Hexs/Quads. 
      In this case, we should merge the two interfaces (xSpacePolynomialQH and xSpacePolynomial) 
      and check compatibility between the shape functions.
      * xAttachableGaussPoints.h, xIntegrationRuleStored.h : New integration rule based on 
      attached gausspoints. It is possible (not committed yet) to drop the subelements and work 
      only with gauss points located at the right place and with the right weight (i.e. located 
      where they would be if subelements were defined).
      * xGeomElem.h : add setMapping, setIntegrator methods
      git-svn-id: https://svn.ec-nantes.fr/eXlibris/Xfiles@985 05fba31e-542e-4c34-abd9-da38eceff631
  12. 26 Sep, 2011 1 commit
    • Alexis SALZMAN's avatar
      ================================================== · 20c7884f
      Alexis SALZMAN authored
      From N. Moes, N. Cheveaugeaon and A. Salzman work
      This commit concerne only Xfiles
      It follow Xinterface changes : Use of traits, new namespace lalg and solver interface change.
      Please wait for next commit comming soon to have a correct test database before
      applying any comits
      Following have not been update :
       * XcrackFMM
      xAlgorithm.h  : L2Projection
      use new connecMatrix interface with old xCSRMatrix container style (ndof at construction)
      xAlgorithm.h  : AssembleGraph
      New function to generate graph matrix by following the same principle as the Assemble function.
      It  doesn't use dispatcher as graph is only impacted by a small amount of value type : dof and linear combination
      It use a fast treatement by block.
      xAlgorithm.h/cc  : addLinCombDOF
      add this recursive function for AssembleGraph. It add free dof out of linear combination to
      the list of dof to add to the matrix Graph. It is recursive as linear combination may be
      Traits of matrix drive assembling process.
      Add policy to assemble only half matrix when in symetrique pattern.
      Add policy to assemble only diagonal matrix term when in diagonal pattern.
      Add policy to assemble all matrix term when in unsymetric pattern.
      Right end side contribution (non null diriclet condition) is also made dependant of policy as
      non symetrique pattern don't follow the wall elementary matrix.
      use new lalg namespace
      replace xCSRVector in lalg namespace
      for some source
      use new lalg namespace
      use  new SuperLu interface (connecMatrix) with old xCSRMatrix container
      bug correction ??? inverting RHS and sol
      for some source
      use new lalg namespace
      Eliminate include when possible
      for some source
      use new lalg namespace
      Eliminate include when possible
      for some source
      solver_l2 changed in new SuperLu interface (connecMatrix)
      modification to had matrix_type and vector_type as new template parameter. Coherance with new nonLinearSystemSolverNR interface.
      This is needed as now theire is no corelation betewn solver and matrix used in the solver
      Change dumy returned value of the virtual get_field method, into a real dumy (NULL) value to
      suppresse warnings for test cases
      git-svn-id: https://svn.ec-nantes.fr/eXlibris/Xfiles@966 05fba31e-542e-4c34-abd9-da38eceff631
  13. 05 Sep, 2011 1 commit
  14. 23 Nov, 2009 1 commit
  15. 25 Jul, 2008 1 commit
  16. 26 Jun, 2008 1 commit
  17. 05 Mar, 2007 1 commit
  18. 13 Feb, 2007 1 commit
  19. 05 Feb, 2007 1 commit
  20. 29 Sep, 2005 1 commit
  21. 26 Sep, 2005 1 commit