expressions

<expressions> An expression is an arithmetic computation enclosed inside angle brakets "<>". An expression uses similar syntax to FORTRAN. The syntax is not as rigid as FORTRAN and some syntactical elements may be omitted. Expression evaluation is very slow, so you should use them sparingly.

Additional Information on:

  • constants
  • functions
  • operators
  • filenames
  • examples
  • order

    Data by default is entered in the following order. X Y DX DY SYMBOL

    Where: DX is the error or 1/2 bin width for X+-DX. DY is the error on Y+-DY. SYMBOL is the symbol to plot.

    You may change the actual order that data is entered with the SET ORDER command.

    Numbers

    Data may be expressed in any legal FORTRAN format. For example 1 = 1.0 = +1.0E0

    points

    Data is entered in a series of lines one point to a line. Each number may be separated by spaces, tabs, or commas",". Numbers may also be run together without separators, provided they begin with either plus "+" or minus "-". If you wish to enter several data points on a single line then they may be separated by semicolons ";". Instead of a number you may also use expressions by enclosing it inside angle brakets "<>".

    If you omit data the last value is used. See: Command READ POINTS.

    Symbols

    Symbols are 0O to 9O or any legal UGSYS duplex character set pair. "NONE" indicates no symbol. " " or "DOT" produces a dot. If the symbol is omitted it is assumed to be NONE and the datum is plotted by default as a point rather than a symbol. This may be modified by SET SYMBOL. If you wish to use the number 1 as a symbol it must be enclosed in quotes or apostrophes ("1").

    Time-Angles-Dates

    Time may be entered in hours in the format hh:mm:ss.nnn. You may also enter angles as dd:mm:ss.nn in degrees, minutes, seconds. Time or angle data must begin with a number. 0::1.5 is legal for 1.5 seconds after midnight, while ::1.5 is not legal.

    Dates may be entered in hours as YYYY\MM\DD. If omitted MM or DD are assumed to be 1. If you wish to enter both date and time the format is YYYY\MM\DD\HH:mm:ss.ss. See:Command SET DATE.

    If time is preceded by a sign, then all 3 HOURS,MINUTES, and SECONDS are considered negative. If a date or date\time is preceded by a sign it applies only to the YYYY (Year). Signs (+ -) may not be imbedding inside a date\time.

    Examples 10 (10 am) 10:00 (10 am) 15:30:25.2 (25.2 seconds past 3:30 pm) 0.5 (Half past midnight) 0:30 (Half past midnight) 24:30 (Half past midnight) 1987\12\25\12:30 (12:30 on Dec 25, 1987) -1:30:00 (10:30)

    types

    Data may either be X,Y,Z points or mesh data. A point consists of an X,Y,[Z] value with optional errors DX,DY,[DZ],[NDX], [NDY],[NDZ] Z and DZ are optional and may not necessarily be present. MESH data is a data set consisting of Z values as a function of X and Y. A mesh is essentially a square grid of data with X,Y vs Z. A mesh may also have optional DX, DY, and DZ values attached to it.

    Data may be subdivided into data sets. Each data set is numbered consecutively starting with 1. Within each data set the points are numbered from 1 to n. To create a new data set use the DATA SET command. Some commands such as FIT allow automatic creation of a new data set if the option APPEND is used.

    When plotting you may specify which data set you wish to plot with the option SET=n. For example PLOT SET=1 plots the first data set. You may also use FIRST,LAST,NEXT,PREVIOUS, or CURRENT to specify a data set. FIRST is always set number 1 while LAST is the number of data sets. CURRENT is the last set specified. NEXT is the current data set +1, while PREVIOUS is the current set -1.

    For example you may plot 2 sets by: TD:PLOT SET=FIRST TD:PLOT SET=NEXT You may also specify a range of sets. TD:PLOT SET=2 TO LAST plots all data sets except for number 1. Warning When plotting multiple data sets, the format of the plot is taken from the first data set. If the first set is a mesh, the plot will be 3-D.

    ON|OFF

    A number of options use ON or OFF to modify them. For example: TD:SET MODE VECTOR=OFF Uses hardware characters whenever possible. Instead of ON, OFF you may also use T,F or TRUE,FALSE or YES,NO.

    examples

    The following will enter a series of data points in the order x,dx,y,dy,symbol. TD:SET ORDER X DX Y DY SYMBOL TD:+1+.5+10+.5'0o' TD:2 .5 25 .5 1o TD:3 .25 10 .01 2o TD:4 .1 5 1e-1 3o