[MBDyn-users] Coupling of MBDyn with an external code using a variable timestep (recomputed at each temporal iteration)

Yoann Robert yoann.robert at ec-nantes.fr
Fri Jan 23 12:46:05 CET 2015

Dear developers and users of MBDyn,

A colleague of mine has already coded a tool coupling MBDyn and the CFD 
code of our team. His simulations were launched with a constant 
timestep. In my case, the physics of the problem forces me to use a 
variable timestep, depending on the Courant number, and which is 
recomputed at each temporal iteration in the CFD code. So my CFD code 
must impose the timestep value to MBDyn.
 From this, several questions comes to mind.

1) In the current version of MBDyn, is this possible to do such a coupling?
2) If this is not possible, is it planned in the next versions? How soon?
3) If it is not the case, are the modifications of the source code of 
MBDyn quite easy to do by myself? And could you tell me in which files 
or functions this modifications would take place?


This question is about something less important but it would allow me to 
lighten my input files, especially the drives in my joint elements.
I browsed the documentation and I learned we can define some "plugin 
variables" from the nodes or from the elements, using directly the data 
accessible through the node/element in question, such as

set: integer NODENAME = 1000;
# the node must exist
set: [node,VARNAME,NODENAME,abstract,string="xP"];


set: integer ELEMNAME = 1000;
# the joint must exist
set: [element,VARNAME,ELEMNAME,joint,string="Fz"];

Unfortunately, it does not seem to me that the definition of more 
complex time-dependent variables is allowed. For instance, supposing 
that the three following constants are defined, such a definition is not 
possible (or a least not in this way):

set: integer NODENAME = 1000;
# the node must exist

It does not seem more likely that a definition of a time-dependent 
variable also depending on data from multiple nodes and/or elements is a 

Did I miss something or is it the case in the current state of the code 
? I know I may be too greedy... :-)

Thanks and Regards,

Yoann Robert

More information about the MBDyn-users mailing list