How do I use Expressions and Conversion Functions?
Previous  Top 

GSEOS offers two different kinds of mathematical conversions for data items and display purposes. Expressions are general purpose formulas that can take data items as well as constants as parameters and that can be displayed on a screen.
Conversion functions are bound to a particular data item and perform a conversion for this specific data item, usually an engineering unit conversion.

Both Expressions and Conversion functions are defined in a formula file. This formula file needs to be loaded for the formulas to be accessible (as opposed to GSEOS 5.0 and earlier where the formula file was referenced directly from the screen file).

Once you have defined and loaded your Expressions and Conversion functions you can access them by placing an Expression object on a screen. If you place a simple data item that has a conversion function associated you can select the conversion function with the item select dialog.

Expressions and Conversions can also be accessed from Python and are available in the Conversion module. In order to use your functions all you have to do is import the Conversion module:

Example

import Conversion
Conversion.Calibrate(3, Rates.Mass[0], 0.9899)