I'm working with a 4GHz VSA80000A and have tried to do some math functions to operate on two input channels. One channel carries a bandlimited (but wide), delayed version of the other. If I use the built-in CrossCorrelation, all works fine and as expected.

But if I make my own math correlation function, such as:

ifft(fft(Data('Raw Main Time 2'))*conj(fft(Data('Raw Main Time 1'))))

I get a ratty looking result or in some cases a crash of the VSA.

If I use any windowing function at all (Hann or Gauss) on the data before the FFTs, I get no data result at all (just a line at 0).

Worse, if I play with the math function much at all, such as using "Main Time 1" instead of "Raw Main Time 1", the VSA crashes and I have to start it up again, sometimes having to reboot the machine to get it to recognize the hardware again. The crash very often happens about a second after I hit the Math "Check Syntax" button. Other times it happens when I try to use a checked (and verified syntax) function.

I also tried to do a deconvolution of one channel versus the other, and the result I get is quite different from what I would have expected (it doesn't much resemble an impulse and varies quite a bit with every sweep).

So my most pressing question is: what formula does the built-in Convolution function use (the one found from the "Trace->Data->ChX:->CrossCorrel" menu)?

And my second is: is there a fix for the math entry crashing issue? I'm not having much luck with the user-defined math setup at all, either with the user interface or with the operation of the functions.

And while I'm asking questions, what exactly is the difference between "Raw Main Time 1" and "Main Time 1"? I couldn't find these terms defined in the Help files.

Thanks

But if I make my own math correlation function, such as:

ifft(fft(Data('Raw Main Time 2'))*conj(fft(Data('Raw Main Time 1'))))

I get a ratty looking result or in some cases a crash of the VSA.

If I use any windowing function at all (Hann or Gauss) on the data before the FFTs, I get no data result at all (just a line at 0).

Worse, if I play with the math function much at all, such as using "Main Time 1" instead of "Raw Main Time 1", the VSA crashes and I have to start it up again, sometimes having to reboot the machine to get it to recognize the hardware again. The crash very often happens about a second after I hit the Math "Check Syntax" button. Other times it happens when I try to use a checked (and verified syntax) function.

I also tried to do a deconvolution of one channel versus the other, and the result I get is quite different from what I would have expected (it doesn't much resemble an impulse and varies quite a bit with every sweep).

So my most pressing question is: what formula does the built-in Convolution function use (the one found from the "Trace->Data->ChX:->CrossCorrel" menu)?

And my second is: is there a fix for the math entry crashing issue? I'm not having much luck with the user-defined math setup at all, either with the user interface or with the operation of the functions.

And while I'm asking questions, what exactly is the difference between "Raw Main Time 1" and "Main Time 1"? I couldn't find these terms defined in the Help files.

Thanks

t(xc) = I(F[t2] * conj(F[r * t1]))

Where: F = Fast Fourier Transform (FFT)

I = Inverse Fast Fourier Transform

t1 = Time record 1

t2 = Time record 2

t(xc) = cross-correlation time record

* = multiplication

r = rectangular window that has a size of 0.5 * t2

User Math doesn't have a convenient way to create or apply a rectangular window like this, so it will not be easy to make a user math function which exactly duplicates what the cross correlation trace does. If you make an external file that contains this window, and recalls it into a data register and multiply by t1 this may work.

I do not have access to one of these scopes so I have asked a coworker to look into the crashes that you have reported. I was unable to duplicate this problem on an external PC.

The difference beteen Main Time and Raw Main Time:

Raw Main Time is the actual time data recieved from the hardware.

Main Time is the time record after resampling for the user specified frequency span.