11-08-2018 10:16 PM
Hi Guys I am struggling putting a correction factor onto current raw data trace when developing RF test software. I was using Agilent E4440 PSA, PSA screenshot.gif was the screen that I was working as a example. so right now I can get this raw data trace from instrument displaying in my graph successfully with some other returning parameters such as start and stop frequency, frequency increment rate etc. (see output1.png). at the same time I have second trace representing correction factor that I want to add onto the raw data trace. (see output2.png). my question is how can I add them together to get a final corrected plot in graph within 30-300MHz ? because they are different in size and frequency so I can't simply add them up.
any ideas are welcome, no need specific code, thanks!
output1.png is from 30MHz to 300MHz, 601 elements
output2.png is from 10MHz to 6GHz, 16 elements
PSA Screenshot
Output1
Output2
Solved! Go to Solution.
11-12-2018
10:07 AM
- last edited on
11-07-2024
11:31 AM
by
Content Cleaner
Here are my thoughts off the bat:
1. Take your raw waveform data and determine the number of samples in that array
2. Take your 1D correction factor array and resample it (with interpolation) such that it has the same number of samples as your waveform data
3. Take your equal-sized arrays and use LabVIEW math primitives to multiply / add them. If the raw data is waveform data, just pull the Y component for this operation before rebundling at the end.
Note: make sure you're converting between a multiplicative factor and the dB scale on step 3 if you haven't already
For the resampleingpart, I'd look at a function like this:
Resample Waveforms (continuous) VI
11-17-2018 05:52 PM
Hi Sam thank you very much for you reply. I thought I would got no reply until NI sent me a notification. your thought are exactly how I fix this problem after I get to know from one of youtube tutorials that there are bunch of interpolation VI that I can use in mathematics pallete, what I was struggling before is just I was trying to do interpolation algorithm myself and ended up out of my capability. I used interpolation 1D arry VI resampled correction factor 1D array, so I have equal sized two arrays to be sum up now. good to know there is a resample VI as well in signal process pallete maybe I will need to use it in the future. cheers