|
C++ mpi module for stochmagnet_main Package
|
This class is a one simulation of a beam for Stoch Magnet package. More...
#include <SM_System.h>


Public Member Functions | |
| virtual tMemSize | getMemorySize () const |
| return the memory size of the class and the memory size of all its attributes/associations More... | |
| virtual tMemSize | getContentsMemorySize () const |
| return the memory size of the included associations More... | |
| void | setNetwork (CORE_UniquePointer< SM_Network > net) |
| set the network More... | |
| const SM_Network & | getNetwork () const |
| get the network More... | |
| SM_Network & | getNetwork () |
| get the network More... | |
| tBoolean | hasNetwork () const |
| return true if the system has a network More... | |
| const SM_Material & | getMaterial () const |
| get the material of the network More... | |
| SM_Material & | getMaterial () |
| get the material of the network More... | |
| void | setInitialMagneticMomentDirections (const std::valarray< tReal > &S0) |
| set the initial unit direction of spins More... | |
| void | setInitialMagneticMomentDirections (const SM_RealField &S0) |
| set the initial unit direction of spins More... | |
| void | setInitialMagneticMomentDirections (const tIndex &N, const std::array< tReal, SM_Constants::DIM > &S0) |
| set the initial unit direction of spins More... | |
| virtual tBoolean | updateInitialMagneticMomentDirections (const SM_RealField &S0) |
| update the initial unit direction of spins More... | |
| const SM_RealField & | getInitialMagneticMomentDirections () const |
| get the initial unit direction of spins More... | |
| SM_RealField & | getInitialMagneticMomentDirections () |
| get the initial unit direction of spins for writting More... | |
| const SM_RealField & | getMagneticMomentDirections () const |
| get the unit direction of spins at time More... | |
| SM_RealField & | getMagneticMomentDirections () |
| get the unit direction of spins at time for writting More... | |
| virtual tBoolean | initializeMagneticMomentDirections () |
| initialize magnetic moments direction More... | |
| void | addOperator (CORE_UniquePointer< SM_Operator > op) |
| add operator More... | |
| const SM_SliceOperator * | getOperator (const tString &name) const |
| get the operator with name More... | |
| SM_SliceOperator * | getOperator (const tString &name) |
| get the operator with name More... | |
| void | copyOperators (const SM_System &system) |
| copy the operator More... | |
| const std::map< tString, CORE_UniquePointer< SM_Operator > > & | getOperators () const |
| get the operators More... | |
| std::map< tString, CORE_UniquePointer< SM_Operator > > & | getOperators () |
| get the operators More... | |
| tIndex | getOperatorsNumber () const |
| get the operators number More... | |
| void | getOperatorsName (std::vector< tString > &names) const |
| get the operator names More... | |
| virtual void | setStochasticNoise (const tReal &eps) |
| set the stochastic noise without dimension More... | |
| const tReal & | getStochasticNoise () const |
| get the stochastic noise without dimension More... | |
| virtual void | setNoiseTemperature (const tReal &T) |
| set the noise as a temperature in Kelvin More... | |
| const tReal & | getNoiseTemperature () const |
| get the noise temperature in Kelvin More... | |
| virtual tULLInt | getGeneratedRandomNumbers () const =0 |
| get the generated of random number More... | |
| const tIndex & | getStepIndex () const |
| get the step index More... | |
| tIndex & | getStepIndex () |
| get the step index More... | |
| virtual void | normalize (const tBoolean &isAdimensionized) |
| normalize the system More... | |
| virtual void | sumOverNetworks (const int &rootNetwork, tIndex &n, const tIndex &nValues, tReal *values) const |
| sum the values of all network More... | |
| void | computeMagneticMomentDirectionsSumOverNetworks (const int &rootNetwork, std::array< tReal, SM_Constants::DIM > &sumS) const |
| compute the sum over the domain of magnetic moment dierctions More... | |
| void | computeMagneticMomentDirectionsMeanOverNetworks (const int &rootNetwork, std::array< tReal, SM_Constants::DIM > &meanS) const |
| compute the mean over the domain of magneticmoment directions More... | |
| void | computeMagneticMomentDirectionsSum (const tInteger &start, const tInteger &end, std::array< tReal, SM_Constants::DIM > &sumS) const |
| compute the sum of magnetic moment directions over the network More... | |
| virtual void | discretize () |
| discretize the system More... | |
| void | updateOperatorsState (const tIndex &timeIndex, const SM_Network &network, const SM_Material &material, const SM_RealField &S) |
| update the operators state before computeing magnetic field More... | |
| void | computeMagneticField (const tIndex &timeIndex, const SM_Network &network, const SM_Material &material, const SM_RealField &S, SM_RealField &H) const |
| compute the magnetic field at time step index t by calling the virtual method SM_Operator::computeMagneticField() More... | |
| tReal | computeSpinEnergy (const tIndex &i, const SM_Network &network, const SM_Material &material, const SM_RealField &S) const |
| compute the energy of the spin of the system More... | |
| tReal | computeSpinEnergy (const tIndex &i, const tIndex &timeIndex, const SM_Network &network, const SM_Material &material, const SM_RealField &S) const |
| compute the energy of the spin of the system More... | |
| const tReal & | computeEnergies (std::valarray< tReal > &energies) const |
| compute the energies per operators More... | |
| const tReal & | computeEnergies (const tIndex &timeIndex, std::valarray< tReal > &energies) const |
| compute the energies per operators More... | |
| virtual tString | toString () const override |
| turn the class into a string representation More... | |
Public Member Functions inherited from SM_Object | |
| SM_Object (void) | |
| create | |
| virtual | ~SM_Object (void) |
| destroy | |
Public Member Functions inherited from CORE_Object | |
| template<class T > | |
| std::shared_ptr< T > | getSharedPointer () |
| return the shared pointer for this More... | |
| template<class T > | |
| std::shared_ptr< const T > | getConstSharedPointer () const |
| return a const shared pointer for this More... | |
| template<class T > | |
| tBoolean | isInstanceOf () const |
| test if the clas T is an instance of this class More... | |
| tString | getClassName () const |
| return the name of the class More... | |
| tString | getPointerString () const |
| retrun the pointer of the class as a string More... | |
| tString | getIdentityString () const |
| retrun the string identification of the class More... | |
Static Public Member Functions | |
| static void | ComputeFieldSum (const tInteger &start, const tInteger &end, const SM_RealField &F, std::array< tReal, SM_Constants::DIM > &sumF) |
| compute the sum of F over the network More... | |
Static Public Member Functions inherited from CORE_Object | |
| static tBoolean | EnableMemoryStack (const tBoolean &isMemoryChecked) |
| enable the memory stack More... | |
| static void | EnableMemoryStack () |
| enable the memory stack | |
| static void | DisableMemoryStack () |
| disable the memory stack | |
| static tBoolean | IsMemoryStackEnabled () |
| return trur if the memory stack is enabled | |
| static tString | MemoryStackToString () |
| get the memory stack in string More... | |
| static tIndex | GetRegisteredClassesNumber () |
| get the memory stack in string More... | |
Protected Member Functions | |
| SM_System (void) | |
| create a class | |
| virtual | ~SM_System (void) |
| destroy the class | |
| tReal | computeEnergy (const SM_Network &network, const SM_Material &material, const SM_RealField &S) const |
| compute the energy of the system More... | |
| tReal | computeEnergy (const tIndex &timeIndex, const SM_Network &network, const SM_Material &material, const SM_RealField &S) const |
| compute the energy of the system More... | |
Protected Member Functions inherited from CORE_Object | |
| CORE_Object () | |
| build an instance of the object | |
| virtual | ~CORE_Object () |
| destroy the instance of object std | |
This class is a one simulation of a beam for Stoch Magnet package.
The system class SM_System describes a simulation of ne trajectory of a beam. A system class contains the attributes data:
A system class contains the attributes state:
A system class is linked to:
This class implements:
There is two kinds of implemtation of system
|
inline |
add operator
| [in,out] | op | : operator to add. op points to null at the output |
|
inline |
compute the energies per operators
| [in] | timeIndex | index of time (O per default) |
| [out] | energies | energies per operator of size number Of operatorq + 1 |
|
inline |
compute the energies per operators
| [out] | energies | energies per operator of size number Of operatorq + 1 |
|
inlineprotected |
compute the energy of the system
| [in] | network | : network of the system |
| [in] | material | : material of the system |
| [in] | S | direction of the magnetic moments of size nParticles x SM_Constants::DIM |
|
inlineprotected |
compute the energy of the system
| [in] | timeIndex | index of time |
| [in] | network | : network of the system |
| [in] | material | : material of the system |
| [in] | S | direction of the magnetic moments of size nParticles x SM_Constants::DIM |
|
inlinestatic |
compute the sum of F over the network
| [in] | start | start element to compute the sum |
| [in] | end | : end element to compute the sum |
| [in] | F | field to compute teh sumper coordinate for element in [start,end[ |
| [out] | sumF | : \( \forall k in [0,d[, F_k=\sum_i F_k[i] \) |
|
inline |
compute the magnetic field at time step index t by calling the virtual method SM_Operator::computeMagneticField()
| [in] | timeIndex | index of the time step |
| [in] | network | : network of the system |
| [in] | material | : material of the system |
| [in] | S | direction of the magnetic moments of size nParticles x SM_Constants::DIM |
| [out] | H | magnetic field of size nParticles x SM_Constants::DIM |
|
inline |
compute the mean over the domain of magneticmoment directions
| [in] | rootNetwork; | index of the root network to store the results |
| [out] | meanS | : mean of S over the particles of the networks |
|
inline |
compute the sum of magnetic moment directions over the network
| [in] | start | start element to compute the sum |
| [in] | end | : end element to compute the sum |
| [out] | sumS | : \( \forall k in [0,d[, \forall p in [start,end[ S_k+= S_k[p] \) |
|
inline |
compute the sum over the domain of magnetic moment dierctions
| [in] | rootNetwork; | index of the root network to store the results |
| [out] | sumS | : sum of S on all the particles of the networks: \( \forall k in [0,d[, \forall p in \mathcal{R}, F_k+=F_k[p] \) |
|
inline |
compute the energy of the spin of the system
| [in] | i | index of the spin |
| [in] | network | : network of the system |
| [in] | material | : material of the system |
| [in] | S | direction of the magnetic moments of size nParticles x SM_Constants::DIM |
|
inline |
compute the energy of the spin of the system
| [in] | i | index of the spin |
| [in] | timeIndex | index of time |
| [in] | network | : network of the system |
| [in] | material | : material of the system |
| [in] | S | direction of the magnetic moments of size nParticles x SM_Constants::DIM |
|
inline |
copy the operator
| [in] | system | : the operators of the system are copied. |
|
inlinevirtual |
discretize the system
Reimplemented in SM_MonteCarloSystem, SMOMPI_StratonovichSystem, SMOMPI_StratonovichNormalizedSystem, SMOMPI_LandauLifschitzSystem, SMOMPI_HeunSystem, and SM_LandauLifschitzSystem.
|
inlinevirtual |
return the memory size of the included associations
Reimplemented from CORE_Object.
Reimplemented in SMOMPI_MonteCarloSystem, SM_MonteCarloSystem, SMOMPI_LandauLifschitzSystem, SMOMPI_HeunSystem, and SM_LandauLifschitzSystem.
|
pure virtual |
get the generated of random number
Implemented in SM_MonteCarloSystem, and SM_LandauLifschitzSystem.
|
inline |
get the initial unit direction of spins for writting
|
inline |
get the initial unit direction of spins
|
inline |
get the unit direction of spins at time for writting
|
inline |
get the unit direction of spins at time
|
inline |
get the material of the network
|
inline |
get the material of the network
|
inlinevirtual |
return the memory size of the class and the memory size of all its attributes/associations
Reimplemented from SM_Object.
Reimplemented in SMOMPI_MonteCarloSystem, SM_MonteCarloSystem, SMOMPI_StratonovichSystem, SMOMPI_StratonovichNormalizedSystem, SMOMPI_LandauLifschitzSystem, SMOMPI_ItoSystem, SMOMPI_HeunSystem, and SM_LandauLifschitzSystem.
|
inline |
get the network
|
inline |
get the network
|
inline |
get the noise temperature in Kelvin
|
inline |
get the operator with name
| [in] | name | : name of the operator |
|
inline |
get the operator with name
| [in] | name | : name of the operator |
|
inline |
get the operators
|
inline |
get the operators
|
inline |
get the operator names
| [out] | names | : names of the operator |
|
inline |
get the operators number
|
inline |
get the step index
|
inline |
get the step index
|
inline |
get the stochastic noise without dimension
|
inline |
return true if the system has a network
|
inlinevirtual |
initialize magnetic moments direction
Reimplemented in SM_LandauLifschitzSystem, SMOMPI_MonteCarloSystem, and SMOMPI_LandauLifschitzSystem.
|
inlinevirtual |
normalize the system
| [in] | isAdimensionized | true to adimensionize the system |
Reimplemented in SM_MonteCarloSystem, and SM_LandauLifschitzSystem.
|
inline |
set the initial unit direction of spins
| [in] | S0 | initial dierction of spins as an unit vector |
|
inline |
set the initial unit direction of spins
| [in] | S0 | initial dierction of spins as an unit vector |
|
inline |
set the initial unit direction of spins
| [in] | N | : number of particles |
| [in] | S0 | constant value of S |
|
inline |
set the network
| [in] | net | : net of the system |
|
inlinevirtual |
set the noise as a temperature in Kelvin
| [in] | T | : temperature |
Reimplemented in SM_MonteCarloSystem, and SM_LandauLifschitzSystem.
|
inlinevirtual |
set the stochastic noise without dimension
| [in] | eps | stochastic noise |
|
inlinevirtual |
sum the values of all network
| [in] | rootNetwork; | index of the root network to store the results |
| [in,out] | n | number of elements used for computing each element of values at input : per network , at output : for all networks |
| [in] | nValues | number of elements of values |
| [in,out] | values | values computed at input : per network, at output: for all networks Do nothing by defaut because there is only one network |
Reimplemented in SMOMPI_LandauLifschitzSystem.
|
inlineoverridevirtual |
turn the class into a string representation
Reimplemented from CORE_Object.
Reimplemented in SM_MonteCarloSystem, and SM_LandauLifschitzSystem.
|
inlinevirtual |
update the initial unit direction of spins
| [in] | S0 | initial dierction of spins as an unit vector |
Reimplemented in SMOMPI_LandauLifschitzSystem, and SM_LandauLifschitzSystem.
|
inline |
update the operators state before computeing magnetic field
| [in] | timeIndex | index of the time step |
| [in] | network | : network of the system |
| [in] | material | : material of the system |
| [in] | S | direction of the magnetic moments of size nParticles x SM_Constants::DIM |