Freefem++ F. Hecht Laboratoire Jacques-Louis Lions Université Pierre et Marie C

Freefem++ F. Hecht Laboratoire Jacques-Louis Lions Université Pierre et Marie Curie Paris, France with A. Le Hyaric, S. Auliac, P. Jolivet,I. Danaila, O. Pironneau http://www.freefem.org mailto:hecht@ann.jussieu.fr Cours Freefem++, La Rochelle, Novembre 2013. F. Hecht et al. FreeFem++ Lecture 1 / 112 Outline 1 Introduction 2 Tools 3 Academic Examples 4 Numerics Tools 5 Schwarz method with overlap 6 Advance exercice 7 No Linear Problem 8 Technical Remark on freefem++ 9 Phase change with Natural Convection Cours Freefem++, La Rochelle, Novembre 2013. F. Hecht et al. FreeFem++ Lecture 2 / 112 Outline 1 Introduction History The main characteristics Changes Basement Weak form Poisson Equation 2 Tools 3 Academic Examples 4 Numerics Tools 5 Schwarz method with overlap 6 Advance exercice Cours Freefem++, La Rochelle, Novembre 2013. F. Hecht et al. FreeFem++ Lecture 3 / 112 News, FreeFem++ pass 22 109 unknowns The message from Pierre Jolivet Machine: Curie Thin Node@CEA Financement: PRACE project HPC-PDE (number 2011050840) Nombre de coeurs: 6144 Mémoire par coeurs: 4 Go Eléments finis: P3 Dimension: 2D Précision: 1e-08 Nombres d’inconnues: 1 224 387 085 Méthode de résolution: GMRES préconditionné par une méthode de décomposition de domaine à deux niveaux Nombre d’itérations: 18 Temps de résolution: 2 minutes Type de problème: équation de diffusion avec coefficients très hétérogènes (5 ordres de grandeur de variation) The FreeFem++ days, the 10,11,12 of December, 2013, UPMC, Jussieu, Paris, France Cours Freefem++, La Rochelle, Novembre 2013. F. Hecht et al. FreeFem++ Lecture 4 / 112 Introduction FreeFem++ is a software to solve numerically partial differential equations (PDE) in I R2) and in I R3) with finite elements methods. We used a user language to set and control the problem. The FreeFem++ language allows for a quick specification of linear PDE’s, with the variational formulation of a linear steady state problem and the user can write they own script to solve no linear problem and time depend problem. You can solve coupled problem or problem with moving domain or eigenvalue problem, do mesh adaptation , compute error indicator, etc ... By the way, FreeFem++ is build to play with abstract linear, bilinear form on Finite Element Space and interpolation operator. FreeFem++ is a freeware and this run on Mac, Unix and Window architecture, in parallel with MPI. Cours Freefem++, La Rochelle, Novembre 2013. F. Hecht et al. FreeFem++ Lecture 5 / 112 History 1987 MacFem/PCFem les ancêtres (O. Pironneau en Pascal) payant. 1992 FreeFem réécriture de C++ (P1,P0 un maillage) O. Pironneau, D. Bernardi, F. Hecht , C. Prudhomme (adaptation Maillage, bamg). 1996 FreeFem+ réécriture de C++ (P1,P0 plusieurs maillages) O. Pironneau, D. Bernardi, F. Hecht (algèbre de fonction). 1998 FreeFem++ réécriture avec autre noyau élément fini, et un autre langage utilisateur ; F. Hecht, O. Pironneau, K.Ohtsuka. 1999 FreeFem 3d (S. Del Pino) , Une première version de freefem en 3d avec des méthodes de domaine fictif. 2008 FreeFem++ v3 réécriture du noyau élément fini pour prendre en compte les cas multidimensionnels : 1d,2d,3d... Cours Freefem++, La Rochelle, Novembre 2013. F. Hecht et al. FreeFem++ Lecture 6 / 112 For who, for what ! For what 1 R&D 2 Academic Research , 3 Teaching of FEM, PDE, Weak form and variational form 4 Algorithmes prototyping 5 Numerical experimentation 6 Scientific computing and Parallel computing For who : the researcher, engineer, professor, student... The mailing list mailto:Freefempp@ljll.math.upmc.fr with 410 members with a flux of 5-20 messages per day. More than 2000 true Users ( more than 1000 download / month) Cours Freefem++, La Rochelle, Novembre 2013. F. Hecht et al. FreeFem++ Lecture 7 / 112 The main characteristics I/II (2D)(3D) Wide range of finite elements : continuous P1,P2 elements, discontinuous P0, P1, RT0,RT1,BDM1, elements ,Edge element, vectorial element, mini-element, ... Automatic interpolation of data from a mesh to an other one ( with matrix construction if need), so a finite element function is view as a function of (x, y, z) or as an array. Definition of the problem (complex or real value) with the variational form with access to the vectors and the matrix. Discontinuous Galerkin formulation (only in 2d to day). LU, Cholesky, Crout, CG, GMRES, UMFPack, SuperLU, MUMPS, HIPS , SUPERLU_DIST, PASTIX. ... sparse linear solver ; eigenvalue and eigenvector computation with ARPACK. Online graphics with OpenGL/GLUT/VTK, C++ like syntax. An integrated development environment FreeFem++-cs Cours Freefem++, La Rochelle, Novembre 2013. F. Hecht et al. FreeFem++ Lecture 8 / 112 The main characteristics II/II (2D)(3D) Analytic description of boundaries, with specification by the user of the intersection of boundaries in 2d. Automatic mesh generator, based on the Delaunay-Voronoï algorithm. (2d,3d (tetgen) ) load and save Mesh, solution Mesh adaptation based on metric, possibly anisotropic (only in 2d), with optional automatic computation of the metric from the Hessian of a solution. (2d,3d). Link with other soft : parview, gmsh , vtk, medit, gnuplot Dynamic linking to add plugin. Full MPI interface Nonlinear Optimisation tools : CG, Ipopt, NLOpt, stochastic Wide range of examples : Navier-Stokes 3d, elasticity 3d, fluid structure, eigenvalue problem, Schwarz’ domain decomposition algorithm, residual error indicator ... Cours Freefem++, La Rochelle, Novembre 2013. F. Hecht et al. FreeFem++ Lecture 9 / 112 The Changes form 01/11 to 08/11 correct problem of comm world on SuperLuDist (complex version) correct medit Makefile.am in case of no compilation of medit .. Add thresholdings.cpp thresholdings.edp in examples++-load to remove to small coef in a matrix . Add lots of DDM Schwarz GMRES preconditioned with a coarse grid solver overlapping : Add a true exemple to buld mesh form a image (lg.pgm) , Leman-mesh.edp Add New syntaxe in macro generation NewMacro a(i) .... EndMacro with // comment and macro definition. Add interface with special function to GSL http://www.gnu.org/software/gsl/ the full list is in the example examples++-loal/gsl.edp correct the precond of gmres algo in A−1 : (29 mars 2011) to build a correct Navier-Stokes add cast TypeOfSolver on int to parametrize the choise of linear solver. put comment in the documentation about negative tgv correct mpiReduce for complex and real data. add mpiAllReduce(umax,dmaxg,comm,mpiMAX); where for real umax,dmaxg ; update the finite element list in documentation add (load "Element-Mixte") NEW FINITE ELEMENT 2D TDNSS1 sym matrix 2x2 conforme in {H(divdiv)/div(divs)) 2 H−1}, RT1 and BDM1 conforme in H(div) Raviart Thomas of Degree 1 and Bezzi, Douglas, Marini RT1 and BDM1ortho conforme in H(curl) Nedelec Finite Elem. add matrix multiplication with lapack interface add tool to change the region and label number change(Th,fregion= integer function to set the region number ) nuTriangle now given the tet number in 3D. add mpireduce of matrix to build parallel matrix correct the Hips interface (not to bad , in test) add interface with MUMPS_4.10.0 version (with automatic download ) add P1dc3d finite element in pluging "Element_P1dc1" correct bug in gibbs renumbering in 1 case veru sample mesh) correct bug in interpolation operator with periodic B.C. Cours Freefem++, La Rochelle, Novembre 2013. F. Hecht et al. FreeFem++ Lecture 10 / 112 The Changes form 09/11 to 06/13 v 3.16 cmaes interface in scalar and MPI case (thank to S. Auliac) add NLopt interface (thank to S. Auliac) build a pkg under macos for distribution . rewrite the isoline-P1 plugins v 3.18 (11/01/2012) add tools for adaptation of P2 and P3 finite elements with metrics add plugins with sequential mumps without mpi add conversion of re and im part of complex sparse matrix add Ipopt interface (thanks to Sylvain Auliac) scotch partionner interface see scotch.edp v 3.19 (20 april 2012) add tool to create Quadrature formular 1d,2d,3d with add integration on levelset line (in test) add formal tools on array [] or matrix [[],[],] for elasitic problem. add new MUMPS parallel version plugin add paradiso interface (MKL) version 3.22 add multi windows graphics ; WindowIndex=0 in plot function and add new event in graphic windows * to set/unset default graphics stat to previous plot add getenv, setenv , unsetenv function in shell plugins for the management of environnemnt variable for openmp. correct pb un trunc for 3d mesh with too flat element (sliver) , and cleanning code . correct bug of the domain outsite flag in 3d in case when we use the brute force (searchMethod>0) version 3.23 do cleanning in version remove x11, glx, std : freefem++ add flags to remove internal boundary in 2d,3d in function change rmInternalEdges=1 glumesh in case of no mesh in 2d correct extract function of mesh Lo Sala <salalo80@gmail.com> correct int2d on levelset see example intlevelset.edp correct automake TESTING part (in progress) correct typo on the doc with .*= ./= operator correct bug in RT0 3d , code in the construction of the DOF. add new parameter to ffglut for demo of freefem++ to version 3.26-2. Correct compile problème, configuration clean up , ... Cours Freefem++, La Rochelle, Novembre 2013. F. Hecht et al. FreeFem++ Lecture 11 / 112 Element of syntax : Like in C 0/4 The key words are reserved The operator like in C exempt: ^ & | + - * / ^ // a^b= ab == != < > <= uploads/Litterature/ freefem.pdf

  • 25
  • 0
  • 0
Afficher les détails des licences
Licence et utilisation
Gratuit pour un usage personnel Attribution requise
Partager