|
C++ mpi module for stochmagnet_main Package
|
This class describes a landau lifschitz function of the form : More...
#include <SM_LandauLifschitzFunction.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... | |
| void | copy (const SM_LandauLifschitzFunction &LL) |
| copy the LL function More... | |
| void | setAlphaFunction (const LambdaF &L) |
| set the alpha function More... | |
| void | setGamma (const tReal &gamma) |
| set the alpha parameter \( \alpha=\frac{\gamma }{\lambda^2 +1} \) More... | |
| void | setLambda (const tReal &v) |
| set the lambda parameter \( \alpha=\frac{\gamma }{\lambda^2 +1} \) More... | |
| void | setAlpha (const tReal &v) |
| set the alpha parameter directly without setting setGamma() More... | |
| void | setIsSNormalized (const tBoolean &v) |
| set true if M is supposed to be normalized More... | |
| const tReal & | getGamma () const |
| get the gamma parameter More... | |
| const tReal & | getAlpha () const |
| get the alpha parameter More... | |
| const tReal & | getLambda () const |
| get the lambda parameter More... | |
| tBoolean | isSNormalized () const |
| return true if M is supposed to be normalized More... | |
| void | computeFunction (const tIndex &nParticles, const SM_RealField &S, const SM_RealField &B, SM_RealField &F) const |
| computes the magnetic function More... | |
| void | computeFunction (const tIndex &nSParticles, const tReal *S, const tIndex &nBParticles, const tReal *B, tReal *F) const |
| compute the magnetic function More... | |
| virtual tString | toString () const override |
| turn the class into a string 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... | |
| virtual tMemSize | getContentsMemorySize () const |
| return nthe memory size of the included associations 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... | |
Protected Member Functions | |
| SM_LandauLifschitzFunction (void) | |
| create | |
| virtual | ~SM_LandauLifschitzFunction (void) |
| destroy | |
| virtual void | computeLLFunction (const tIndex &nSParticles, const tReal *S, const tIndex &nBParticles, const tReal *B, tReal *F) const =0 |
| compute the magnetic function More... | |
| virtual void | computeNLLFunction (const tIndex &nSParticles, const tReal *S, const tIndex &nBParticles, const tReal *B, tReal *F) const =0 |
| compute the normalized magnetic function More... | |
| void | computeSliceLLFunction (tIndex start, tIndex end, const tIndex &nSParticles, const tReal *S, const tIndex &nBParticles, const tReal *B, tReal *F) const |
| compute the magnetic function for particle indices in [start,end[ More... | |
| void | computeSliceNLLFunction (tIndex start, tIndex end, const tIndex &nSParticles, const tReal *S, const tIndex &nBParticles, const tReal *B, tReal *F) const |
| compute the normalized magnetic function for particle indices in [start,end[ 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 | |
Additional Inherited Members | |
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... | |
This class describes a landau lifschitz function of the form :
\( f(\mu,b)= \displaystyle -\gamma/(1+\lambda^2) \left ( \mu \wedge b + \lambda( \mu \cdot b \mu - |\mu|^2 b ) \right ) \).
The normalized formultation on the landau lifschitz function when \( |\mu|=1 \) is :
\( f(\mu,b)= \displaystyle \alpha(\gamma,\lambda) \left ( \mu \wedge b + \lambda ( \mu \cdot b \mu - b ) \right ) \).
with \( alpha=-\frac{\gamma}{1+\lambda^2} \) by default
The main method to compute the function is the method SM_LandauLifschitzFunction::computeFunction()
|
inline |
computes the magnetic function
| [in] | nParticles | number of particles to compute LL function (S may be greater than nParticles because of halo particles) |
| [in] | S | the magnetic moment directions |
| [in] | B | the total magnetic field |
| [out] | F | the return output vector |
\( F=f(S,B)= \displaystyle alpha. \left ( S \wedge B + \lambda S \wedge ( S \wedge B ) \right ) \). or \( F=f(S,B)= \displaystyle alpha. \left ( S \wedge B + \lambda ( <S,B> S - |S|^2 . B ) \right ) \).
|
inline |
compute the magnetic function
| [in] | nSParticles | : number of particles of S |
| [in] | S | the magnetic moment |
| [in] | nBParticles | : number of particles of B |
| [in] | B | the total magnetic field |
| [out] | F | the return output vector of size of B \( F=f(S,B)= \displaystyle alpha. \left ( S \wedge B + \lambda S \wedge ( S \wedge B ) \right ) \). or \( F=f(S,B)= \displaystyle alpha. \left ( S \wedge B + \lambda ( <S,B> S - |S|^2 . B ) \right ) \). |
|
protectedpure virtual |
compute the magnetic function
| [in] | nSParticles | : number of particles of mu |
| [in] | S | the magnetic moment |
| [in] | nBParticles | : number of particles of B |
| [in] | B | the total magnetic field |
| [out] | F | the return output vector |
Implemented in SMOMPI_LandauLifschitzFunction.
|
protectedpure virtual |
compute the normalized magnetic function
| [in] | nSParticles | : number of particles of mu |
| [in] | S | the magnetic moment |
| [in] | nBParticles | : number of particles of B |
| [in] | B | the total magnetic field |
| [out] | F | the return output vector |
\( F=f(\mu,b)= \displaystyle alpha. \left ( \mu \wedge B + \lambda \mu \wedge ( \mu \wedge B ) \right ) \). or \( F=f(\mu,b)= \displaystyle alpha. \left ( \mu \wedge B + \lambda ( <\mu,B> mu - |mu|^2 . B ) \right ) \).
Implemented in SMOMPI_LandauLifschitzFunction.
|
inlineprotected |
compute the magnetic function for particle indices in [start,end[
| [in] | start | : index of the start particle |
| [in] | end | : index of the end particle |
| [in] | nSParticles | : number of S Particles |
| [in] | S | the magnetic moment |
| [in] | nBParticles | : number of B Particles |
| [in] | B | the total magnetic field |
| [out] | F | the return output vector |
\( F=f(\mu,b)= \displaystyle alpha. \left ( \mu \wedge B + \lambda \mu \wedge ( \mu \wedge B ) \right ) \). or \( F=f(\mu,b)= \displaystyle alpha. \left ( \mu \wedge B + \lambda ( <\mu,B> mu - |mu|^2 . B ) \right ) \).
|
inlineprotected |
compute the normalized magnetic function for particle indices in [start,end[
| [in] | start | : index of the start particle |
| [in] | end | : index of the end particle |
| [in] | nSParticles | : number of S Particles |
| [in] | S | the magnetic moment |
| [in] | nBParticles | : number of B Particles |
| [in] | B | the total magnetic field |
| [out] | F | the return output vector |
\( F=f(\S,b)= \displaystyle alpha. \left ( \S \wedge B + \lambda \S \wedge ( \S \wedge B ) \right ) \). or \( F=f(\S,b)= \displaystyle alpha. \left ( \S \wedge B + \lambda ( <\S,B> S - |S|^2 . B ) \right ) \).
|
inline |
copy the LL function
| [in] | LL | : the function to copy |
|
inline |
get the alpha parameter
|
inline |
get the gamma parameter
|
inline |
get the lambda parameter
|
inlinevirtual |
return the memory size of the class and the memory size of all its attributes/associations
Reimplemented from SM_Object.
Reimplemented in SMOMPI_LandauLifschitzFunction.
|
inline |
return true if M is supposed to be normalized
|
inline |
set the alpha parameter directly without setting setGamma()
| [in] | v | alpha value |
|
inline |
set the alpha function
| [in] | L | : function= Ecxmaple of function L=([](const tReal& gamma,const tReal& lambda,tReal& alpha) {
alpha=lambda;
alpha*=alpha;
alpha+=1;
alpha/=alpha;
alpha*=gamma;
return alpha;
});
|
|
inline |
set the alpha parameter \( \alpha=\frac{\gamma }{\lambda^2 +1} \)
| [in] | gamma | gamma value |
|
inline |
set true if M is supposed to be normalized
| [in] | v | : true to normalize M |
|
inline |
set the lambda parameter \( \alpha=\frac{\gamma }{\lambda^2 +1} \)
| [in] | v | lambda value |
|
inlineoverridevirtual |
turn the class into a string
Reimplemented from CORE_Object.