The SEDRIS Data Representation Model
APPENDIX C - Types
SE_Predefined_Function
/*
 * REGISTERABLE ENUM: SE_Predefined_Function
 *
 *   Definitions for individual functions signify argument usage by
 *   labelling the argument with capital letters, such that
 *   A = first argument, B = second argument, and so on.
 */
typedef SE_Short_Integer SE_Predefined_Function;
Enumerant Definition Value
SE_PREDEFFN_ADD
 Definition: A + B

 This is a binary operator, for which the first of the ordered
 arguments is "left" of the operator and the second is "right".
1
SE_PREDEFFN_DIVIDE
 Definition: A / B

 This is a binary operator, for which the first of the ordered
 arguments is "left" of the operator and the second is "right".
2
SE_PREDEFFN_MODULO
 Definition: A % B

 This is a binary operator, for which the first of the ordered
 arguments is "left" of the operator and the second is "right".
3
SE_PREDEFFN_MULTIPLY
 Definition: A * B

 This is a binary operator, for which the first of the ordered
 arguments is "left" of the operator and the second is "right".
4
SE_PREDEFFN_SUBTRACT
 Definition: A - B

 This is a binary operator, for which the first of the ordered
 arguments is "left" of the operator and the second is "right".
5
SE_PREDEFFN_COSINE
 Definition: cosine(A)
6
SE_PREDEFFN_SINE
 Definition: sine(A)
7
SE_PREDEFFN_TANGENT
 Definition: tangent(A)
8
SE_PREDEFFN_ARCCOSINE
 Definition: arccosine(A)
9
SE_PREDEFFN_ARCSINE
 Definition: arcsine(A)
10
SE_PREDEFFN_ARCTANGENT
 Definition: arctangent(A)
11
SE_PREDEFFN_ARCTANGENT2
 Definition: The square of arctangent(A)
12
SE_PREDEFFN_HYPOTENUSE
 Definition: hypotenuse(A, B)
13
SE_PREDEFFN_ABSOLUTE
 Definition: /A/ : absolute value of "A"
14
SE_PREDEFFN_EXPONENT
 e^A
15
SE_PREDEFFN_LN
 ln(A) : natural logarithm of "A"
16
SE_PREDEFFN_LOG
 log(A, B) : log, base "B" of "A"
17
SE_PREDEFFN_POWER
 Definition: A^B : "A" raised to the "Bth" power
18
SE_PREDEFFN_SQRT
 sqrt(A)
19
SE_PREDEFFN_MAXIMUM
 if (A > B) return A; else return B;
20
SE_PREDEFFN_MINIMUM
 if (A < B) return A; else return B;
21
SE_PREDEFFN_NOT
 Definition: Not (the logical operator)

 Symbol: !A, where A is the operand

 Return Type: Boolean

 This unary logical operator treats an operand with a value
 of zero (0) as FALSE, while an operand with a non-zero
 value is treated as TRUE.
22
SE_PREDEFFN_AND
 Definition: And (the logical operator)

 Symbol: A && B, for operands A, B

 This binary logical operator treats its first ordered argument
 (A) as "left" of the operator, while the second (B) is "right".
 An operand with a value of zero (0) is treated as FALSE, while
 an operand with a non-zero value is treated as TRUE.
23
SE_PREDEFFN_EQUAL
 A == B
24
SE_PREDEFFN_GREATER_THAN
 A > B
25
SE_PREDEFFN_GREATER_THAN_OR_EQUAL
 A >= B
26
SE_PREDEFFN_LESS_THAN
 A < B
27
SE_PREDEFFN_LESS_THAN_OR_EQUAL
 A <= B
28
SE_PREDEFFN_NOT_EQUAL
 A != B
29
SE_PREDEFFN_OR
 Definition: Or (the logical operator)

 Symbol: A || B, for operands A, B

 This binary logical operator treats its first ordered argument
 (A) as "left" of the operator, while the second (B) is "right".
 An operand with a value of zero (0) is treated as FALSE, while
 an operand with a non-zero value is treated as TRUE.
30
SE_PREDEFFN_EXCLUSIVE_OR
 Definition: Exclusive Or (the logical operator)

 Symbol: A ?? B, for operands A, B

 This binary logical operator treats its first ordered argument
 (A) as "left" of the operator, while the second (B) is "right".
 An operand with a value of zero (0) is treated as FALSE, while
 an operand with a non-zero value is treated as TRUE.
31
SE_PREDEFFN_IF
 Definition: if (A) return B; else return C

 Accepts exactly 3 arguments: A, B, and C.
32
SE_PREDEFFN_PI
 The mathematical constant PI
33
SE_PREDEFFN_SIMULATION_TIME
 Returns time, in floating point seconds, since simulation start.
34
SE_PREDEFFN_SIMULATION_UTIME
 Returns time, in unsigned microseconds, since simulation start.
 The value is allowed to overflow and roll back to zero.
35
SE_PREDEFFN_REFERENCE_SURFACE_ELEVATION
 Returns the height of the terrain at the point specified by the
 arguments.  Arguments are interpreted as coordinates within the currently
 scoped SRF defined by the current transmittal.
 Argument order should match the field order defined by <Location 3D>.
36
SE_PREDEFFN_CYCLE_TIME
 Returns a cycling time value in seconds of the kind specified by the
 arguments. These arguments are:
 A - a trigger boolean to start the cycle(s)
 B - cycle length in seconds
 C - an <Expression> instance that returns time in seconds
 D - number of cycles to do before stopping
 E - cycle time at which to start
 F - cycle time at which to end
 G - Boolean specifying whether the cycle runs one way
     (start > end, start > end) or whether it reverses at the end
     (start > end > start)
37
SE_PREDEFFN_TABLE_VALUE
 The given <Predefined Function> instance PF in this case exists to
 provide a mechanism for a <Property Table> instance T to drive the
 <Control Link> instance that contains PF. This mechanism operates
 in the following manner.

 PF has a <Property Table Reference> instance PTR as a component,
 where PTR references the <Property Table> instance T that is to
 drive the target <Control Link> instance. The values shall be
 stored in cells with a <Table Property Description>, the meaning
 and value_type of which are appropriate for the target <Control Link>
 instance that is to be driven.

 PF returns the value referenced from T as the value that drives
 the target <Control Link> instance. PTR can itself be controlled
 using a <Property Table Reference Control Link> instance, allowing
 different values to be referenced from T.
38



Prev: SE_Predef_Func_Structure. Next: SE_Present_In.


Return to: Top of this Page, Type Index