Robotran C Documentation
Classes | Macros | Typedefs | Functions
mbs_euler_explicit.h File Reference

This header defines global functions for Euler Explicit integrator in C. More...

#include "mbs_data.h"
#include "integrator.h"
#include "mbs_dirdyn.h"
#include "useful_functions.h"
#include "mbs_dirdyn_struct.h"
#include "mbs_project_interface.h"
#include "MBSfun.h"

Go to the source code of this file.

Classes

struct  MbsDirdynEulerEx
 Euler Explicit structure for dirdyn. More...
 

Macros

#define P_INF_VALUE   0.143
 

Typedefs

typedef void(* euler_integrator_implementation) (double h, MbsData *mbs_data, MbsDirdyn *mbs_dd)
 This pointer is used to choose between the two implementations of euler. More...
 

Functions

void initialize_eulerEx (MbsData *mbs_data, MbsDirdyn *mbs_dd)
 Initialize all needed fields in MbsDirdyn for Euler Explicit integrator. More...
 
int loop_eulerEx (double t0, double tf, MbsData *mbs_data, MbsDirdyn *mbs_dd)
 Integrate the motion from t0 to tf. More...
 
void finish_eulerEx (MbsData *mbs_data, MbsDirdyn *mbs_dd)
 Finalize and clear memory allocated for Euler Explicit integrator. More...
 
void euler_explicit (double h, MbsData *mbs_data, MbsDirdyn *mbs_dd)
 Source code for the Euler Explicit integration. More...
 
void eulaire (double h, MbsData *mbs_data, MbsDirdyn *mbs_dd)
 Source code for unknown integrator but based partially on euler explicit We call it Eulaire. More...
 
void alpha_method (double h, MbsData *mbs_data, MbsDirdyn *mbs_dd)
 Source code for a simplified alpha-method We call it AlphaM. More...
 
void error_eulerEx (MbsData *mbs_data, MbsDirdyn *dd, int err)
 If an error occurs during time integration, this function prints the error message and call finish_eulerEx. More...
 

Detailed Description

This header defines global functions for Euler Explicit integrator in C.

Creation date: May 2018

Author
Sebastien Timmermans

(c) Universite catholique de Louvain

Macro Definition Documentation

◆ P_INF_VALUE

#define P_INF_VALUE   0.143

Typedef Documentation

◆ euler_integrator_implementation

typedef void(* euler_integrator_implementation) (double h, MbsData *mbs_data, MbsDirdyn *mbs_dd)

This pointer is used to choose between the two implementations of euler.

Function Documentation

◆ alpha_method()

void alpha_method ( double  h,
MbsData mbs_data,
MbsDirdyn mbs_dd 
)

Source code for a simplified alpha-method We call it AlphaM.

Reference : Chen, Qiong-zhong and Acary, Vincent and Virlez, Geoffrey and Bruls, Olivier. (2013). A nonsmooth generalized-alpha scheme for flexible multibody systems with unilateral constraints. International Journal for Numerical Methods in Engineering. 96. 487-511. 10.1002/nme.4563.

Parameters
hThe integration step size
mbs_dataThe computed MBS structure
mbs_ddThe associated MbsDirdyn structure

◆ error_eulerEx()

void error_eulerEx ( MbsData mbs_data,
MbsDirdyn dd,
int  err 
)

If an error occurs during time integration, this function prints the error message and call finish_eulerEx.

Parameters
mbs_dataThe computed MBS structure
mbs_ddThe associated MbsDirdyn structure
errThe error number

◆ eulaire()

void eulaire ( double  h,
MbsData mbs_data,
MbsDirdyn mbs_dd 
)

Source code for unknown integrator but based partially on euler explicit We call it Eulaire.

Parameters
hThe integration step size
mbs_dataThe computed MBS structure
mbs_ddThe associated MbsDirdyn structure

◆ euler_explicit()

void euler_explicit ( double  h,
MbsData mbs_data,
MbsDirdyn mbs_dd 
)

Source code for the Euler Explicit integration.

Parameters
hThe integration step size
mbs_dataThe computed MBS structure
mbs_ddThe associated MbsDirdyn structure

◆ finish_eulerEx()

void finish_eulerEx ( MbsData mbs_data,
MbsDirdyn mbs_dd 
)

Finalize and clear memory allocated for Euler Explicit integrator.

Parameters
mbs_dataThe computed MBS structure
mbs_ddThe associated MbsDirdyn structure

◆ initialize_eulerEx()

void initialize_eulerEx ( MbsData mbs_data,
MbsDirdyn mbs_dd 
)

Initialize all needed fields in MbsDirdyn for Euler Explicit integrator.

Parameters
mbs_dataThe computed MBS structure
mbs_ddThe associated MbsDirdyn structure

◆ loop_eulerEx()

int loop_eulerEx ( double  t0,
double  tf,
MbsData mbs_data,
MbsDirdyn mbs_dd 
)

Integrate the motion from t0 to tf.

Parameters
t0The initial time
tfThe final time
mbs_dataThe computed MBS structure
mbs_ddThe associated MbsDirdyn structure
Returns
Error status, <0 in case of failure.

user loop

user loop