4. Examples#

4.1. Case of a function#

4.1.1. Define function FORMULE sin (t)#

IF = FORMULE (NOM_PARA = 'INST',

VALE = 'sin (INST) ')

4.1.2. Tabulate sin (t) from a list of reals#

PAS0 = DEPI /200. LI1 = DEFI_LIST_REEL (DEBUT = 0, INTERVALLE =_F (JUSQU_A = DEPI, PAS = PAS0),)

SI1 = CALC_FONC_INTERP (FONCTION = YES, LIST_PARA = LI1, NOM_RESU = “DEPL”, PROL_GAUCHE =” EXCLU “, PROL_DROITE =” CONSTANT”, INTERPOL =” LIN “, TITRE =” FONCTION SINUS”)

4.1.3. Tabulate sin (t) from a list of values#

SI2 = CALC_FONC_INTERP (FONCTION = YES, VALE_PARA = LI2, NOM_PARA =” INST “, PROL_GAUCHE = “EXCLU”, PROL_DROITE = “EXCLU”, INTERPOL = “LIN”, TITRE = “FONCTION SINUS”)

4.2. Case of a tablecloth#

4.2.1. Define function FORMULE sin (omega*t)#

IF = FORMULE (NOM_PARA = ('FREQ', 'INST'),

VALE = 'sin (2*pi* FREQ * INST) ')

4.2.2. Tabulate sin (omega*t) from a list of moments#

The tablecloth parameter is” FREQ “, the variable for the functions defining the tablecloth is” INST “. We check in CALC_FONC_INTERP that the first parameter of the formula is the same as NOM_PARA, and that the second parameter of the formula is identical to NOM_PARA_FONC.

LI_FREQ = DEFI_LIST_REEL (DEBUT = 10, INTERVALLE =_F (JUSQU_A =100, PAS =10),)

LI_INST = DEFI_LIST_REEL (DEBUT = 0, INTERVALLE =_F (JUSQU_A =100, PAS =1),)


SI1 = CALC_FONC_INTERP (FONCTION = YES,

NOM_RESU = “DEPL”, NOM_PARA_FONC =” INST “,

LIST_PARA_FONC = LI_INST

PROL_GAUCHE_FONC =” EXCLU “, PROL_DROITE_FONC =” CONSTANT “, INTERPOL_FONC =” LIN “,

NOM_PARA =” FREQ “,

LIST_PARA = LI_FREQ

PROL_GAUCHE =” LINEAIRE “, PROL_DROITE =” LINEAIRE “, INTERPOL =” LIN “,

TITRE =” FONCTION SINUS “,)