C++ mpi module for stochmagnet_main Package
core package

core package package contains all core classes used in all modules.

core package package contains all core classes used in all modules.

UML Convention

It contains templated functions:

It contains utility classes:

This package in DEBUG mode enable a memory stack to ensure all created objects has been destoyed at the end. Note that the memory stack is also disabled in OpenMP module manged by the OMP_Thread class

A class contains:

The coding conventions:

The smart pointer definition :

All the used types are defined in a types.h

To cast the variable from type to another use static_cast : Q j=static_cast[Q](i); or one of them:

using of constexpr for a variable instead of #define or const for expression evaluated at compilation.

using for ( const type iter : values) when values is a class containing begin() and end() and iter is an iterator

For looping when begin() and end() it is possible to use: for (const auto & e : elements) { } when data has a begin & end funtcion std::for_each(begin(),end(),[parameters](const T& v){lambda function where v in [begin(),end()[;}); std::sort(begin(),end(),[](const T& a,const T& b){ return (a>b);});

parameters:

We can define a lambda funtion outside the key word auto lambdaF = [parameters](args){body}; auto lambdaF =[](const auto & val){cout<<val<<"\n";};

list std::tuple<T1,T2,T3> tuple(a,b,c);

list std::variant<T1,T2,T3> var(a,b,c);

For testing the template attributes it is possible to use:

For primary types:

For categories types:

For properties type:

For relations type:

Note
{ In debug mode, a list of classes in memory is maintened in order to be sure that at end of running all the class is destroyed ie the list is empty. This list is maintained by the CORE_Class in core package which is a base class of all the classes of the program. }

The organization of this package is as follow: