4. Definition of a time-dependent function#
4.1. Function and variables are entered as real numbers#
Definition of a function (piecewise linear) depends on time (parameter INST).
4.2. Function and variables are entered as listr8 concepts#
It is possible to define this function using listr8 concepts created using the DEFI_LIST_REEL [U4.34.01] operator:
INTERVALLE = (_F (JUSQU_A = 1., NOMBRE = 1,), _F (JUSQU_A = 3., NOMBRE = 1,), _F (JUSQU_A = 6., NOMBRE = 1,),) )
ORDONNEE = DEFI_LIST_REEL (DEBUT = -1. , INTERVALLE = (_F (JUSQU_A = 0., NOMBRE = 1,), _F (JUSQU_A = 1., NOMBRE = 1,), _F (JUSQU_A = 2., NOMBRE = 1,),) )
EX_2 = DEFI_FONCTION (NOM_PARA = “INST”, VALE_PARA = ABSCISSE, VALE_FONC = ORDONNEE, PROL_DROITE = “CONSTANT”, PROL_GAUCHE = “LINEAIRE”, )
Note:
This example is obviously very complicated to define the proposed function.
We only wanted to highlight the principle of using the opportunity offered.
This becomes interesting when using functions defined at a large number of points.
Another reason to use the definition by DEFI_LIST_REEL is when lists are needed as an argument for another operator: (list of the moments of an evolutionary calculation THER_LINEAIRE, DYNA_LINE_TRAN, , …), this then avoids the duplication of information.