complexType MathOperationType
diagram SpaceSystemV1.2-27Feb2014-mods_p263.png
namespace http://www.omg.org/space/xtce
children xtce:ValueOperand xtce:ThisParameterOperand xtce:ParameterInstanceRefOperand xtce:Operator
used by
elements MetaCommandType/ParameterToSetList/ParameterToSet/Derivation ParameterToSetType/Derivation MathAlgorithmType/MathOperation CalibratorType/MathOperationCalibrator
annotation
documentation
Postfix (aka Reverse Polish Notation (RPN)) notation is used to describe mathmatical equations. It uses a stack where operands (either fixed values or ParameterInstances) are pushed onto the stack from first to last in the XML. As the operators are specified, each pops off operands as it evaluates them, and pushes the result back onto the stack. In this case postfix is used to avoid having to specify parenthesis. To convert from infix to postfix, use Dijkstra's "shunting yard" algorithm.
source <complexType name="MathOperationType">
 
<annotation>
   
<documentation xml:lang="en">Postfix (aka Reverse Polish Notation (RPN)) notation is used to describe mathmatical equations. It uses a stack where operands (either fixed values or ParameterInstances) are pushed onto the stack from first to last in the XML. As the operators are specified, each pops off operands as it evaluates them, and pushes the result back onto the stack. In this case postfix is used to avoid having to specify parenthesis. To convert from infix to postfix, use Dijkstra's "shunting yard" algorithm.</documentation>
 
</annotation>
 
<choice maxOccurs="unbounded">
   
<element name="ValueOperand" type="double">
     
<annotation>
       
<documentation xml:lang="en">Use a constant in the calculation</documentation>
     
</annotation>
   
</element>
   
<element name="ThisParameterOperand">
     
<annotation>
       
<documentation xml:lang="en">Use the value of this parameter in the calculation</documentation>
     
</annotation>
   
</element>
   
<element name="ParameterInstanceRefOperand" type="xtce:ParameterInstanceRefType">
     
<annotation>
       
<documentation xml:lang="en">Use the value of another Parameter in the calculation</documentation>
     
</annotation>
   
</element>
   
<element name="Operator" type="xtce:MathOperatorsType">
     
<annotation>
       
<documentation xml:lang="en">Binary operators: +, -, *, /, %, ^ operate on the top two values in the stack, leaving the result on the top of the stack.  Unary operators: 1/x, x!, e^x, ln, log, and trigonometric operators operate on the top member of the stack also leaving the result on the top of the stack.  'ln' is a natural log where 'log' is a base 10 logarithm.  Trigonometric operators use degrees.  'swap' swaps the top two members of the stack.</documentation>
     
</annotation>
   
</element>
 
</choice>
</complexType>

element MathOperationType/ValueOperand
diagram SpaceSystemV1.2-27Feb2014-mods_p264.png
namespace http://www.omg.org/space/xtce
type double
properties
content simple
annotation
documentation
Use a constant in the calculation
source <element name="ValueOperand" type="double">
 
<annotation>
   
<documentation xml:lang="en">Use a constant in the calculation</documentation>
 
</annotation>
</element>

element MathOperationType/ThisParameterOperand
diagram SpaceSystemV1.2-27Feb2014-mods_p265.png
namespace http://www.omg.org/space/xtce
annotation
documentation
Use the value of this parameter in the calculation
source <element name="ThisParameterOperand">
 
<annotation>
   
<documentation xml:lang="en">Use the value of this parameter in the calculation</documentation>
 
</annotation>
</element>

element MathOperationType/ParameterInstanceRefOperand
diagram SpaceSystemV1.2-27Feb2014-mods_p266.png
namespace http://www.omg.org/space/xtce
type xtce:ParameterInstanceRefType
properties
content complex
attributes
Name  Type  Use  Default  Fixed  Annotation
parameterRef  xtce:NameReferenceType  required      
instance  integer    0    
useCalibratedValue  boolean    true    
annotation
documentation
Use the value of another Parameter in the calculation
source <element name="ParameterInstanceRefOperand" type="xtce:ParameterInstanceRefType">
 
<annotation>
   
<documentation xml:lang="en">Use the value of another Parameter in the calculation</documentation>
 
</annotation>
</element>

element MathOperationType/Operator
diagram SpaceSystemV1.2-27Feb2014-mods_p267.png
namespace http://www.omg.org/space/xtce
type xtce:MathOperatorsType
properties
content simple
facets
Kind Value Annotation
enumeration +
enumeration -
enumeration *
enumeration /
enumeration %
enumeration ^
enumeration &amp;
enumeration |
enumeration &lt;&lt;
enumeration &gt;&gt;
enumeration &gt;&gt;&gt;
enumeration y^x
enumeration ln
enumeration log
enumeration e^x
enumeration 1/x
enumeration x!
enumeration abs
enumeration tan
enumeration cos
enumeration sin
enumeration atan
enumeration acos
enumeration asin
enumeration tanh
enumeration cosh
enumeration sinh
enumeration atanh
enumeration acosh
enumeration asinh
enumeration swap
enumeration ==
enumeration !=
enumeration &lt;
enumeration &lt;=
enumeration >
enumeration >=
annotation
documentation
Binary operators: +, -, *, /, %, ^ operate on the top two values in the stack, leaving the result on the top of the stack.  Unary operators: 1/x, x!, e^x, ln, log, and trigonometric operators operate on the top member of the stack also leaving the result on the top of the stack.  'ln' is a natural log where 'log' is a base 10 logarithm.  Trigonometric operators use degrees.  'swap' swaps the top two members of the stack.
source <element name="Operator" type="xtce:MathOperatorsType">
 
<annotation>
   
<documentation xml:lang="en">Binary operators: +, -, *, /, %, ^ operate on the top two values in the stack, leaving the result on the top of the stack.  Unary operators: 1/x, x!, e^x, ln, log, and trigonometric operators operate on the top member of the stack also leaving the result on the top of the stack.  'ln' is a natural log where 'log' is a base 10 logarithm.  Trigonometric operators use degrees.  'swap' swaps the top two members of the stack.</documentation>
 
</annotation>
</element>


XML Schema documentation generated by XMLSpy Schema Editor http://www.altova.com/xmlspy