Code_Aster ®
Version
8.2
Titrate:
Operator DEFI_FONCTION


Date:
02/03/06
Author (S):
Key COURTEOUS Mr.
:
U4.31.02-I1 Page:
1/8

Organization (S): EDF-R & D/AMA
Handbook of Utilization
U4.3- booklet: Function
Document: U4.31.02

Operator DEFI_FONCTION

1 Goal

To define a real or complex function of a real variable. This operator allows to define, by
example, of the characteristics materials function of the temperature, or the boundary conditions which
depend on a variable of space or time.

The concept produced by this operator is of function type.

Handbook of Utilization
U4.3- booklet: Function
HT-62/06/004/A

Code_Aster ®
Version
8.2
Titrate:
Operator DEFI_FONCTION


Date:
02/03/06
Author (S):
Key COURTEOUS Mr.
:
U4.31.02-I1 Page:
2/8

2 Syntax
F [function] =
DEFI_FONCTION




(NOM_PARA
= Np,





NOM_RESU
=/“TOUTRESU”,
[DEFAUT]
/
NR,
[K8]






/
VALE
=
lv,
[l_R]
/
VALE_C
=
lv,
[l_C]
/
VALE_PARA

=
,
[listr8]







VALE_FONC = lo, [listr8]
/
NOEUD_PARA
=
lno, [l_noeud]








MAILLAGE

=
my,
[grid]







VALE_Y = ly, [l_R]





PROL_DROITE =/“CONSTANT”,

/“LINEAIRE”,

/“EXCLUDED”, [DEFECT]





PROL_GAUCHE =/“CONSTANT”,
/“LINEAIRE”,
/“EXCLU”,
[DEFAUT]





Interpol
= | “LIN”,
[DEFAUT]










| “LOG”,










| “NON”,





INFO
=
/
1,
[DEFAUT]









/2,





VERIF =
| “CROISSANT”,
[DEFAUT]










| “NON”,





TITER =
Ti, [l_Kn]




)

Handbook of Utilization
U4.3- booklet: Function
HT-62/06/004/A

Code_Aster ®
Version
8.2
Titrate:
Operator DEFI_FONCTION


Date:
02/03/06
Author (S):
Key COURTEOUS Mr.
:
U4.31.02-I1 Page:
3/8

3 Operands

3.1 Operand
NOM_PARA

NOM_PARA = Np

Indicate the name of the parameter (variable or X-coordinate) of the function.
The possible values for Np are:

“TEMP”
“INST”
“EPSI”
“SIGM” “META”
“X”
“Y”
“Z”


“FREQ”
“PULS”
“AMOR”
“ABSC” “DSP”
“DX”
“DY”
“DZ”


“DRX”
“DRY”
“DRZ”


“HYDR”
“SECH”
“PORO”
“SAT” “PGAZ”

“PCAP”
“QUICKLY” “ENDO”
“NORM”



This list is not exhaustive, the user can choose the name of its parameter (cf notices
in NOM_RESU).

3.2 Operand
NOM_RESU

NOM_RESU = NR

Indicate the name of the result (8 characters). The function thus created is NR = F (Np).

Note:

Certain commands (CALC_FONCTION, DEFI_MATERIAU…) check coherence
names of the parameter and result according to their context. For example, one
a traction diagram defined by a function waits of which NOM_PARA=' EPSI' and
NOM_RESU=' SIGM'.

3.3 Operand
VALE


/VALE = lv

lv is the list of values (x1, y1,…, xn, yn) with in the order:

·
X
(the first value of the parameter and the corresponding value of the result),
1, y1
… ,
·
X
(the last value of the parameter and the corresponding value of the result).
N, yn

Note:

The list lv of values must be described in the order of the X-coordinates (X) increasing.

3.4 Operand
VALE_C


/VALE_C = lv

lv is the list of the values (X, y, Z,…, xn, yn, Zn) with:

·
xi values of the parameter
… ,
·
y
the real part and the imaginary part of the function complex for it
I, zi
parameter.
Handbook of Utilization
U4.3- booklet: Function
HT-62/06/004/A

Code_Aster ®
Version
8.2
Titrate:
Operator DEFI_FONCTION


Date:
02/03/06
Author (S):
Key COURTEOUS Mr.
:
U4.31.02-I1 Page:
4/8

3.5 Operand
VALE_PARA


/VALE_PARA =

is the list of the values of the parameter Np (X-coordinates): it is a concept of the listr8 type
created previously by command DEFI_LIST_REEL [U4.34.01].

3.6 Operand
VALE_FONC


/VALE_FONC = lo

lo is the list of the values of the parameter NR (ordered): it is a concept of the listr8 type
created previously by command DEFI_LIST_REEL [U4.34.01].
VALE_PARA and VALE_FONC must be identical cardinals if not the command stops
in error.

3.7 Operand
NOEUD_PARA


/NOEUD_PARA = lno

lno list of nodes allowing to define the values of the X-coordinates of the function to be defined.
The X-coordinates will be equal to the curvilinear X-coordinates of the nodes on the curve that they
define.

3.8 Operands
PROL_DROITE and PROL_GAUCHE

PROL_DROITE and PROL_GAUCHE =

Define the type of prolongation on the right (on the left) of the field of definition of the variable:

·
“CONSTANT” for a prolongation with the last (or first) value of
function,
·
“LINEAIRE” for a prolongation along the first definite segment
(PROL_GAUCHE) or of the last definite segment (PROL_DROITE),
·
“EXCLU”
if the extrapolation of the values apart from the field of definition of
parameter is prohibited (in this case if a calculation requires a value
function out of the field of definition, the code will stop in
fatal error).

For example:

·
PROL_DROITE = “CONSTANT”, PROL_GAUCHE = “CONSTANT”

y
X
X
X
X
X
1
2
n-1
N

Handbook of Utilization
U4.3- booklet: Function
HT-62/06/004/A

Code_Aster ®
Version
8.2
Titrate:
Operator DEFI_FONCTION


Date:
02/03/06
Author (S):
Key COURTEOUS Mr.
:
U4.31.02-I1 Page:
5/8

·
PROL_DROITE = “LINEAR”, PROL_GAUCHE = “EXCLUDED”

y
X
X
X
X
1
x2
n-1
N


Note:

The type of prolongation and interpolation are independent one of the other.

3.9 Operand
Interpol

Interpol
=

Type of interpolation of the function enters the values of the field of definition of the function: one
type for the interpolation of the parameter and for the interpolation of the function. This is obtained in
providing a list of texts among:

Interpol
=
(“LIN”,
“LOG”)

“LIN”: linear,
“LOG”: logarithmic curve,
“NON”: one does not interpolate (and thus the program will stop if for the value is asked
function for a value of the parameter where it was not defined).

Note:

If only one value is specified, it is taken into account at the same time by the interpolation of
parameter and of the function. Interpol = “LOG” is equivalent to (“LOG”, “LOG”).

3.10 Operand
INFO

INFO
=
Specify the options of impression on file MESSAGE.

1: no the impression (default option)
2: impression of the parameters plus the list of the first 10 values in the ascending order
parameter

3.11 Operand
VERIF

VERIF
=

Operator DEFI_FONCTION checks that the values of the X-coordinates are strictly increasing.
If it is not the case, an error is started. This is the behavior by defect, VERIF
“CROISSANT is worth”.
The user with the possibility of not making this checking by indicating VERIF=' NON'. In it
case, one does not start an error and the function is reordered by increasing X-coordinates.
Handbook of Utilization
U4.3- booklet: Function
HT-62/06/004/A

Code_Aster ®
Version
8.2
Titrate:
Operator DEFI_FONCTION


Date:
02/03/06
Author (S):
Key COURTEOUS Mr.
:
U4.31.02-I1 Page:
6/8

3.12 Operand
TITER

TITER = Ti

Titrate attached to the concept produced by this operator [U4.03.01].

3.13 Operands
MAILLAGE and VALE_Y

These two key words should be informed if one defines the function starting from NOEUD_PARA.

MAILLAGE = my

Name of the grid associated with the list with node lno.

VALE_Y = lv

List values of the ordinates of the function to be defined.
Handbook of Utilization
U4.3- booklet: Function
HT-62/06/004/A

Code_Aster ®
Version
8.2
Titrate:
Operator DEFI_FONCTION


Date:
02/03/06
Author (S):
Key COURTEOUS Mr.
:
U4.31.02-I1 Page:
7/8

4
Definition of a function depending on time

4.1
Function and variables entered in the form of realities

·
Definition of a function (linear by pieces) depends on time (parameter INST).


EX 1 = CHALLENGE FUNCTION (
NOM_PARA=' INST',
VALE = (0. , - 1.,
1. , 0., -
2
3. , 1.,
6. , 2.,),
1
PROL GAUCHE=' CONSTANT',
0
1
3
6
T
- 1
PROL DROITE=' LINEAIRE',
);


4.2
Function and variables entered in the form of concepts listr8

·
It is possible to define this function using concepts of the listr8 type created by
the intermediary of operator DEFI_LIST_REEL [U4.34.01]:


X-COORDINATE = DEFI_LIST_REEL (BEGINNING = 0. ,






INTERVAL = (_F (JUSQU_A = 1., NOMBRE = 1,),



_F
(
JUSQU_A
=
3.,
NOMBRE
=
1,),



_F
(
JUSQU_A
=
6.,
NOMBRE
=
1,),)









)

ORDINATE = DEFI_LIST_REEL (BEGINNING = - 1. ,






INTERVAL = (_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:

The second example is obviously quite complicated to define the function suggested.
We wanted only to highlight the principle of use of the possibility
offered.
This one becomes interesting when one uses functions defined in large
a number of points.
Another reason to use the definition by DEFI_LIST_REEL is when the lists are
necessary like argument for another operator: (list of the moments of a calculation
evolutionary THER_LINEAIRE, DYNA_LINE_TRAN,…), this avoids duplication then
information.
Handbook of Utilization
U4.3- booklet: Function
HT-62/06/004/A

Code_Aster ®
Version
8.2
Titrate:
Operator DEFI_FONCTION


Date:
02/03/06
Author (S):
Key COURTEOUS Mr.
:
U4.31.02-I1 Page:
8/8

Intentionally white left page.
Handbook of Utilization
U4.3- booklet: Function
HT-62/06/004/A

Outline document