
WR6K-OM-E Rev A
ISSUED: October 2003
281
that is never greater than plus one or less than minus one.
CSng
CSng (A) calculates a single precision real variable equal to A.
Exp
Exp (A) calculates the value of e
A
.
Int
Cint (A) calculates the integer value next below A, which can be any acceptable
VBS number. Int (-7.4) = -8.
Log
Log (A) calculates the natural logarithm (to base e), of any acceptable VBS
number greater than zero. A negative number or zero will create an error.
To calculate Log
10
(A), use Log
10
(A) = Log(A) / Log(10)
Mod
A Mod (B) calculates the modulus of A, which is the remainder after A has been
divided by B.
34 Mod 8 = 2. 34 Mod 55 = 0. -34 Mod 13 = -8. 21 Mod -8 = 5.
Randomize
Calculates a new seed for the pseudo-random number generator.
Randomize Timer uses the real-time clock for this purpose.
Sin
Sin (A) calculates the sine of any integer or real number, giving an output that is
never greater than +1 or less than -1.
Sqr
Sqr (A) calculates the square root of any integer or a real number that is not
negative. If A is negative, an error will occur.
Timer
Time since the previous midnight in whole seconds.
Hints and Tips for VBScripting
Set the trigger to Single or Stopped if you need to do a lot of editing: it is faster.
Before starting a script, remove any existing scripts that you do not need. This is because errors
in an existing script will give you error messages, even if your current script is perfect. And an
existing good script may develop a fault if you change the setup. For example, you might change
the vertical scale or the memory length and get an overflow if you did not guard against it in the
script.
When starting a script, make sure that you have chosen the right kind: function or parameter. You
can get some very frustrating problems if you are in the wrong mode. You can cut and paste the
VBS statements if you discover this error.
If your calculation requires a long memory, development might be quicker if you test the principles
on a shorter trace at first.
Note that the pseudo-random number generator is reset at the start of a script. If you want a
different set of pseudo-randoms every time, put Randomize Timer in the program, to be run once,
before any pseudo-randoms are generated. You can use this instruction to re-seed the generator
at any time during execution.
Содержание 6000 SERIES
Страница 59: ...WR6K OM E Rev A ISSUED October 2003 57 4 Select a language 5 Click Next when the Wizard appears ...
Страница 60: ...Operator s Manual 58 ISSUED October 2003 WR6K OM E Rev A 6 Select Complete setup 7 Click Install ...
Страница 65: ...WR6K OM E Rev A ISSUED October 2003 63 Proper Orientation of Drive ...
Страница 131: ...WR6K OM E Rev A ISSUED October 2003 129 Example ...
Страница 141: ...WR6K OM E Rev A ISSUED October 2003 139 ...
Страница 236: ...Operator s Manual 234 ISSUED October 2003 WR6K OM E Rev A Example 6 ...
Страница 247: ...WR6K OM E Rev A ISSUED October 2003 245 In this figure the panel has been pasted onto the Excel sheet for comparison ...
Страница 261: ...WR6K OM E Rev A ISSUED October 2003 259 ...
Страница 286: ...Operator s Manual 284 ISSUED October 2003 WR6K OM E Rev A ...
Страница 304: ...Operator s Manual 302 ISSUED October 2003 WR6K OM E Rev A ...
Страница 307: ...WR6K OM E Rev A ISSUED October 2003 305 Convolve two signals ...
Страница 327: ...WR6K OM E Rev A ISSUED October 2003 325 How JitterTrack s Interval Error works when Clock Mode is selected ...
Страница 348: ...Operator s Manual 346 ISSUED October 2003 WR6K OM E Rev A ...
Страница 398: ...Operator s Manual 396 ISSUED October 2003 WR6K OM E Rev A Setting Up the Line Voltage and Current Signals ...
Страница 402: ...Operator s Manual 400 ISSUED October 2003 WR6K OM E Rev A ...