4. Examples#

4.1. Creating a table from a function#

FCT = DEFI_FONCTION (NOM_PARA =”X”,

VALE =( 0.0,5.0,4.0,17.5));

T_ FCT = CREA_TABLE (FONCTION =_F (FONCTION = FCT));

IMPR_TABLE (TABLE =T_ FCT);

The printout of the created table is as follows:

X TOUTRESU

0.00000E+00 5.00000E+00

4.00000E+00 1.75000E+01

4.2. Creating a table from three lists, of heterogeneous types#

T_ LST = CREA_TABLE (LISTE =(

_F (LISTE_R =( 0.0,4.0), PARA =”X”),

_F (LISTE_R =( 5.0,17.5), PARA =”Y”),);

_F (LISTE_I =( 6.7), PARA =”K”)

IMPR_TABLE (TABLE =T_ LST);

The printout of the created table is as follows:

X Y K

0.00000E+00 5.00000E+00 6

4.00000E+00 1.75000E+01 7

4.3. Creating a hole table#

TAB = CREA_TABLE (

LISTE =( _F (PARA =” NUME_ORDRE “, LISTE_I =( 8,15,156,67), ), _F (PARA =” VAR “, LISTE_R =( 2.,15.,18), NUME_LIGN =( 1,3,4), ), _F (PARA =” COMMENT “, LISTE_K =( “VALEUR”,), TYPE_K =”K24”, NUME_LIGNE =1, ), ),

The printout of the created table is as follows:

NUME_ORDRE VAR COMMENT

8 2.00000E+00 VALEUR

15 — -

156 1.50000E+01 -

67 1.80000E+01 -

4.4. Creating a table from a field#

TB01 = CREA_TABLE (RESU =_F (RESULTAT = TEMP0,

TOUT =” OUI “,

NUME_ORDRE =4,

TOUT_CMP =” OUI “,

NOM_CHAM =” TEMP “,),)

The printout of the created table is as follows:

 # TABLE_SDASTER

 RESULTAT NOM_CHAM NUME_ORDRE NOEUD COOR_X COOR_Y TEMP

 TEMP0 TEMP 4 N1 1.0 0.0 85.0

 TEMP0 TEMP 4 N2 2.0 0.0 85.0

 TEMP0 TEMP 4 N3 2.0 4.0 85.0

 TEMP0 TEMP 4 N4 1.0 4.0 85.0