35
Presentation of XLI FE++ Install, development environment and documentation Nicolas KIELBASIEWICZ Unité de Mathématiques Appliquées, ENSTA - Paristech 25 Juin 2014 N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 1/22

Presentation of XLiFE++

Embed Size (px)

Citation preview

Page 1: Presentation of XLiFE++

Presentation of XLIFE++Install, development environment and documentation

Nicolas KIELBASIEWICZ

Unité de Mathématiques Appliquées,ENSTA - Paristech

25 Juin 2014

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 1/22

Page 2: Presentation of XLiFE++

Overview

1 Development environment

2 Documentation

3 Install and use

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 2/22

Page 3: Presentation of XLiFE++

Development environment

1 Development environmentDevelopment policyDevelopment environment

2 DocumentationXLIFE++ on the webUser documentationDeveloper documentationSource documentation

3 Install and useRequirementsHow to install XLIFE++?How to compile with XLIFE++?

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 3/22

Page 4: Presentation of XLiFE++

Development environment

Development policy

There are 4 categories of people :

Beginner users don’t really know about C++ and compilation and use top-level functionalities ofXLIFE++

Advanced users know enough about C++ and compilation use low-level functionalities ofXLIFE++

Beginner developers are able to add some routines, . . . without knowing about the computationengine.

Advanced developers are able to fix, develop anywhere in the code.

XLIFE++ is developed so that each of them can use it or contribute easily.

No pointers, no templates (except Real/Complex), no references for user programs.

Names of classes and methods are as natural as possible.

Documentation

Scripts and/or applications to install on every OS and to write a program

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 4/22

Page 5: Presentation of XLiFE++

Development environment

Development policy

There are 4 categories of people :

Beginner users don’t really know about C++ and compilation and use top-level functionalities ofXLIFE++

Advanced users know enough about C++ and compilation use low-level functionalities ofXLIFE++

Beginner developers are able to add some routines, . . . without knowing about the computationengine.

Advanced developers are able to fix, develop anywhere in the code.

XLIFE++ is developed so that each of them can use it or contribute easily.

No pointers, no templates (except Real/Complex), no references for user programs.

Names of classes and methods are as natural as possible.

Documentation

Scripts and/or applications to install on every OS and to write a program

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 4/22

Page 6: Presentation of XLiFE++

Development environment

Development policy

There are 4 categories of people :

Beginner users don’t really know about C++ and compilation and use top-level functionalities ofXLIFE++

Advanced users know enough about C++ and compilation use low-level functionalities ofXLIFE++

Beginner developers are able to add some routines, . . . without knowing about the computationengine.

Advanced developers are able to fix, develop anywhere in the code.

XLIFE++ is developed so that each of them can use it or contribute easily.

No pointers, no templates (except Real/Complex), no references for user programs.

Names of classes and methods are as natural as possible.

Documentation

Scripts and/or applications to install on every OS and to write a program

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 4/22

Page 7: Presentation of XLiFE++

Development environment

Development environment

XLIFE++ is under the SCM GIT, to manage properly the work of development team.XLIFE++ is a private project on InriaGforge.

There are conventions to control code development. Then, code is quite homogeneous, andclear.

Source documentation is managed by DOXYGEN

Documentations are available on the XLIFE++ website

Language of XLIFE++ documentation and comments is English.

Management of errors, warnings and infos messages is multi-lingual.

A strong test policy exists : unitary tests to debug relatively easily, and system tests to checkperformances and accuracy.

XLIFE++ is a multi-platform library, so it is tested on Windows, Unix/Linux and MacOS. Forcompilation, we use CMAKE.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 5/22

Page 8: Presentation of XLiFE++

Documentation

1 Development environmentDevelopment policyDevelopment environment

2 DocumentationXLIFE++ on the webUser documentationDeveloper documentationSource documentation

3 Install and useRequirementsHow to install XLIFE++?How to compile with XLIFE++?

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 6/22

Page 9: Presentation of XLiFE++

Documentation

XLIFE++ on the web

Main url : http://uma.ensta-paristech.fr/soft/XLiFE++

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 7/22

Page 10: Presentation of XLiFE++

Documentation

XLIFE++ on the web

Forge url : https://gforge.inria.fr/projects/xlifepp

The ’Fichiers’ tab is devoted to download released archives of XLIFE++

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 8/22

Page 11: Presentation of XLiFE++

Documentation

XLIFE++ on the web

Forge url : https://gforge.inria.fr/projects/xlifepp

The ’Code Source’ tab is devoted to XLIFE++ repository

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 9/22

Page 12: Presentation of XLiFE++

Documentation

User documentation

available at$XLIFEPP_INSTALL_DIR/doc/tex/usr-documentation.pdf orhttp://uma.ensta-paristech.fr/soft/XLiFE++/?module=usrdoc&action=index

∼ 88 pages

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 10/22

Page 13: Presentation of XLiFE++

Documentation

Developer documentation

available at$XLIFEPP_INSTALL_DIR/doc/tex/dev-documentation.pdf orhttp://uma.ensta-paristech.fr/soft/XLiFE++/?module=devel&action=index

∼ 327 pages

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 11/22

Page 14: Presentation of XLiFE++

Documentation

Source documentation

Source documentation is managed by DOXYGEN

Online source documentation is available athttp://uma.ensta-paristech.fr/soft/XLiFE++/Doxygen/index.html

Local source documentation is available at $XLIFEPP_INSTALL_DIR/doc/api/

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 12/22

Page 15: Presentation of XLiFE++

Documentation

Source documentation - class index

You can navigate trough each class.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 13/22

Page 16: Presentation of XLiFE++

Documentation

Source documentation - example of Geometry

A class web page begins by includes and inheritance diagram if it exists.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 14/22

Page 17: Presentation of XLiFE++

Documentation

Source documentation - example of Geometry

Next comes attributes and member functions with their comments.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 14/22

Page 18: Presentation of XLiFE++

Documentation

Source documentation - example of Geometry

At last comes member functions definitions. Please notice that it tells whichfunctions or attributes are called or used and which functions call it.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 14/22

Page 19: Presentation of XLiFE++

Documentation

Source documentation - files index

You can navigate trough each file.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 15/22

Page 20: Presentation of XLiFE++

Documentation

Source documentation - example of TermMatrix.hpp

A directory web page shows subdirectories and files.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 16/22

Page 21: Presentation of XLiFE++

Documentation

Source documentation - example of TermMatrix.hpp

A file web page shows classes, namespaces, . . .

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 16/22

Page 22: Presentation of XLiFE++

Documentation

Source documentation - example of TermMatrix.hpp

. . . typedefs and external functions . . .

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 16/22

Page 23: Presentation of XLiFE++

Documentation

Source documentation - example of TermMatrix.hpp

. . . and ends with the eventual detailed description attached to the file.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 16/22

Page 24: Presentation of XLiFE++

Documentation

Source documentation - example of TermMatrix.hpp

You can also see the file content and navigate through it.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 16/22

Page 25: Presentation of XLiFE++

Install and use

1 Development environmentDevelopment policyDevelopment environment

2 DocumentationXLIFE++ on the webUser documentationDeveloper documentationSource documentation

3 Install and useRequirementsHow to install XLIFE++?How to compile with XLIFE++?

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 17/22

Page 26: Presentation of XLiFE++

Install and use

Requirements

User requirements :

CMAKE

A user account on the inria gforge and a registration in xlifepp members. This constraints willbe relaxed soon.

Developer requirements :

CMAKE

GIT

C++ compilation tools

A user account on the inria gforge and a registration in xlifepp members with at least "juniordeveloper" profile.

You can use XLIFE++ or develop for it whatever the OS (Windows, Unix/Linux or Mac OS) andwhatever the IDE (Eclipse, CodeBlocks, Xcode, Visual Studio, command-line tools, . . . ).

Optional requirements :

GMSH, to use the associated mesh generator

ARPACK++

UMFPACK

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 18/22

Page 27: Presentation of XLiFE++

Install and use

How to install XLIFE++?

Unix/Linux and Mac OS cases :

1 You download the latest release from the INRIA gforge (or you clone the repository)

2 You extract the source files in a directory you choose, called $XLIFEPP_INSTALL_DIR

3 Inside $XLIFEPP_INSTALL_DIR, you create a directory called build and move to it.

4 You run the following command : cmake .. This will configure and generate Makefile from defaultconfiguration.

5 You run the following command : make to compile XLIFE++ libraries and tests

6 You run the following command : make test_check to run all tests (it will take some time) or at leastmake test_check_unit to execute unitary tests only.

Windows case :

The last 4 steps are done graphically by using theCMAKE graphical application.

No need of cygwin anymore, as for MELINA++

You can also generate an IDE project by using CMAKE(Eclipse, CodeBlocks, XCode, . . . )

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 19/22

Page 28: Presentation of XLiFE++

Install and use

How to install XLIFE++?

Unix/Linux and Mac OS cases :

1 You download the latest release from the INRIA gforge (or you clone the repository)

2 You extract the source files in a directory you choose, called $XLIFEPP_INSTALL_DIR

3 Inside $XLIFEPP_INSTALL_DIR, you create a directory called build and move to it.

4 You run the following command : cmake .. This will configure and generate Makefile from defaultconfiguration.

5 You run the following command : make to compile XLIFE++ libraries and tests

6 You run the following command : make test_check to run all tests (it will take some time) or at leastmake test_check_unit to execute unitary tests only.

Windows case :

The last 4 steps are done graphically by using theCMAKE graphical application.

No need of cygwin anymore, as for MELINA++

You can also generate an IDE project by using CMAKE(Eclipse, CodeBlocks, XCode, . . . )

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 19/22

Page 29: Presentation of XLiFE++

Install and use

How to install XLIFE++?

Unix/Linux and Mac OS cases :

1 You download the latest release from the INRIA gforge (or you clone the repository)

2 You extract the source files in a directory you choose, called $XLIFEPP_INSTALL_DIR

3 Inside $XLIFEPP_INSTALL_DIR, you create a directory called build and move to it.

4 You run the following command : cmake .. This will configure and generate Makefile from defaultconfiguration.

5 You run the following command : make to compile XLIFE++ libraries and tests

6 You run the following command : make test_check to run all tests (it will take some time) or at leastmake test_check_unit to execute unitary tests only.

Windows case :

The last 4 steps are done graphically by using theCMAKE graphical application.

No need of cygwin anymore, as for MELINA++

You can also generate an IDE project by using CMAKE(Eclipse, CodeBlocks, XCode, . . . )

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 19/22

Page 30: Presentation of XLiFE++

Install and use

How to compile with XLIFE++? - the command-line way

for Unix/Linux and Mac OS

1 You copy both CMakeLists.txt and main.cpp files from the $XLIFEPP_INSTALL_DIR/usrdirectory into your working directory.

2 Inside $XLIFEPP_INSTALL_DIR, you create a directory called build and move to it.3 You run the following command : cmake .. This will configure and generate Makefile from

default configuration.4 You run the following command : make to compile your program.

You can also generate an IDE project by using CMAKE (Eclipse, CodeBlocks, XCode, . . . )

It also can be done with xlifepp_project_setup.sh script in $XLIFEPP_INSTALL_DIR/bin directory.

This replaces themecpmake script ofMELINA++

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 20/22

Page 31: Presentation of XLiFE++

Install and use

How to compile with XLIFE++? - the graphical way

for Windows and Mac OS (Unix/Linux will come soon)

You launch xlifepp_project_setup Qt application from $XLIFEPP_INSTALL_DIR/bin/Win32 or$XLIFEPP_INSTALL_DIR/MacOS directory.

If you look at the menu items,you will have an access to the localsource documentation

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 21/22

Page 32: Presentation of XLiFE++

Install and use

How to compile with XLIFE++? - available compilation options

To use the following options with CMAKE, you just have to prefix them with -D

Using ARPACK++:

XLIFEPP_ENABLE_ARPACKPP=ON/OFF if ON, CMAKE will try to detect arpack, blas and lapacklibraries on your computer. If found, XLIFE++ will be compiled with ARPACK++

ARPACK_LIB_DIR=xxx to set the directory containing arpack, blas and lapack libraries are in it.(may be optional)

ARPACKPP_INCLUDE_DIR=xxx to set the directory containing ARPACK++ header files.

Using UMFPACK:

XLIFEPP_ENABLE_UMFPACK=ON/OFF if ON, CMAKE will try to detect libraries needed to useUMFPACK (suiteSparse) on your computer. If found, XLIFE++ will be compiledwith UMFPACK

UMFPACK_HOME_DIR=xxx to set the home directory containing UMFPACK (suiteSparse).

Using OPENMP:

XLIFEPP_ENABLE_OMP=ON/OFF if ON, CMAKE will compile XLIFE++ with OPENMP.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 22/22

Page 33: Presentation of XLiFE++

Install and use

How to compile with XLIFE++? - available compilation options

To use the following options with CMAKE, you just have to prefix them with -D

Using ARPACK++:

XLIFEPP_ENABLE_ARPACKPP=ON/OFF if ON, CMAKE will try to detect arpack, blas and lapacklibraries on your computer. If found, XLIFE++ will be compiled with ARPACK++

ARPACK_LIB_DIR=xxx to set the directory containing arpack, blas and lapack libraries are in it.(may be optional)

ARPACKPP_INCLUDE_DIR=xxx to set the directory containing ARPACK++ header files.

Using UMFPACK:

XLIFEPP_ENABLE_UMFPACK=ON/OFF if ON, CMAKE will try to detect libraries needed to useUMFPACK (suiteSparse) on your computer. If found, XLIFE++ will be compiledwith UMFPACK

UMFPACK_HOME_DIR=xxx to set the home directory containing UMFPACK (suiteSparse).

Using OPENMP:

XLIFEPP_ENABLE_OMP=ON/OFF if ON, CMAKE will compile XLIFE++ with OPENMP.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 22/22

Page 34: Presentation of XLiFE++

Install and use

How to compile with XLIFE++? - available compilation options

To use the following options with CMAKE, you just have to prefix them with -D

Using ARPACK++:

XLIFEPP_ENABLE_ARPACKPP=ON/OFF if ON, CMAKE will try to detect arpack, blas and lapacklibraries on your computer. If found, XLIFE++ will be compiled with ARPACK++

ARPACK_LIB_DIR=xxx to set the directory containing arpack, blas and lapack libraries are in it.(may be optional)

ARPACKPP_INCLUDE_DIR=xxx to set the directory containing ARPACK++ header files.

Using UMFPACK:

XLIFEPP_ENABLE_UMFPACK=ON/OFF if ON, CMAKE will try to detect libraries needed to useUMFPACK (suiteSparse) on your computer. If found, XLIFE++ will be compiledwith UMFPACK

UMFPACK_HOME_DIR=xxx to set the home directory containing UMFPACK (suiteSparse).

Using OPENMP:

XLIFEPP_ENABLE_OMP=ON/OFF if ON, CMAKE will compile XLIFE++ with OPENMP.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 22/22

Page 35: Presentation of XLiFE++

Install and use

How to compile with XLIFE++? - available compilation options

To use the following options with CMAKE, you just have to prefix them with -D

Using ARPACK++:

XLIFEPP_ENABLE_ARPACKPP=ON/OFF if ON, CMAKE will try to detect arpack, blas and lapacklibraries on your computer. If found, XLIFE++ will be compiled with ARPACK++

ARPACK_LIB_DIR=xxx to set the directory containing arpack, blas and lapack libraries are in it.(may be optional)

ARPACKPP_INCLUDE_DIR=xxx to set the directory containing ARPACK++ header files.

Using UMFPACK:

XLIFEPP_ENABLE_UMFPACK=ON/OFF if ON, CMAKE will try to detect libraries needed to useUMFPACK (suiteSparse) on your computer. If found, XLIFE++ will be compiledwith UMFPACK

UMFPACK_HOME_DIR=xxx to set the home directory containing UMFPACK (suiteSparse).

Using OPENMP:

XLIFEPP_ENABLE_OMP=ON/OFF if ON, CMAKE will compile XLIFE++ with OPENMP.

N. KIELBASIEWICZ Presentation of XLIFE++ 25 Juin 2014 22/22