Creating Math Functions
To create a new math function:
- Click button to create a new math function.
- In the box, type the name of your math function.
- Use the Using math on data registers below). Also, see the Math Function Reference for more information. , , and menus to construct your math expression. A constant value can also be typed or use data registers (see
- Click the button to locate and fix any syntax errors.
- In the box, type a description for the math function.
- Click the button to update any traces that use the math function.
The VSA stores math functions as files with the same name as the math function with the extension .MTHX. The math functions are located in this directory:
%USERPROFILE%\My Documents\Keysight\89600B VSA\MathFunctions
Entering constants in math functions
In addition to buttons and selections from lists, constant values can also be typed to be used in calculations.
For example, to double the amplitude of a spectrum, create the following math function to double the amplitude. (Note that the Log Mag trace format is used, the amplitude increases by 6 dB.)
-
Click
to insert the text Data('Spectrum1') into the math expression. -
Click
to insert an asterisk (*) to signify multiplication. - Type the number 2.
The resulting expression should be Data('Spectrum1') * 2
Enter complex numbers in the format (x + jy) where x is the real part and y is the imaginary part. For example, to shift the phase of a time-domain signal 90 degrees, multiply the signal by j1:
-
Click
to insert the text Data('InstMainTime1') into the math expression. -
Click
to insert an asterisk (*) to signify multiplication. - Type the complex number "j1".
The resulting expression should be Data('Inst Main Time1') * j1
Using math on data registers
Data registers that contain information are listed in the copy or recall data into the register.
menu. Empty data registers are not listed. To perform math operations on a data register, firstSee Also