07-14-2012 08:36 AM
Hello to all Labview friends,
I measure one inductive sensor twice to see how good repeatability the sensor has.The waves i have is as you see in the picture named inductive sensor.Compare this two signal in to XY graph Voltage Vs Distance, i notice that i have very good repeatability till a certain point and after that point i don't have good repeatbaility.So i build a small labview program to calculate the phase difference in degrees between those two waves.
My first signal has: period 67.2271, frequency 0.01487, duty cycle 57.22%, amplitude 4.58
My second signal has: period 66.9537, frequency 0.01494, duty cycle 57.18%, amplitude 4.58
and the phase diffence in degrees my program has calculate is 3.38388.
I would like to ask more expert people here than me if my approach to this problem is right and if my calculation are correct
According to the datasheet of the sensor the accuracy must be <5% if this angle i have calculate is right how can i say that i am below or above 5%?
Any solution for kind of problem?
Thank for reading.
07-16-2012 10:32 PM - edited 07-16-2012 10:35 PM
Hi gstathatos,
A far easier calculation would be to simply use the Extract Single Tone Information .vi to get the phase. Then your phase difference calculation becomes a simple subtraction. Could you post the specifications of the sensor that you are using?
07-17-2012 02:11 AM
Hello and Goo Morning Cole R,
I try the Extract Single Tone Information .vi which is faster than my code but if my program is correct why the phase difference i calculate with my program ise different when i use the the Extract Single Tone Information .vi. Do you think that my program is working wrong?
Here is also the datasheet of the sensor
07-17-2012 03:20 AM
Do you find logic in a signal like that to have a phase degree of 359,104?When i use the Extract Single Tone Information to calculate the degrees for each signal and to subtract those degrees i have a phase of 359,104.
With my program i have a phase of 2,79495 degrees.The difference is huge as you can see.So the question is which is the right to use???
07-18-2012 03:56 PM
Hello gstathatos,
I see now that your signal is not a sine or cosine, check out this article:
http://digital.ni.com/public.nsf/allkb/F4BB644ECCA595D886256FFE00722E29
Use the pulse measurements vi to get the pulse center, then calculate the phase between the two. This should give you a comparison that closely resembles the data you have. Your phase shift should be very small since your signals are almost completely overlapping.
07-18-2012 04:37 PM
Thank for the reply i have done that and now i think is correct,the phase shift in degrees is 0,902894.Now with angle how can i say that i am below 5% accuracy as mention in the datasheet of the sensor?Is there a correspondance i can do so i can decide if mu signal are below or above 5%?
07-20-2012 08:40 AM
Hello,
In this case we really won't be able to measure a true accuracy unless we are taking measurements of a known signal to compare against. All we will be able to test is variation between our measurements. I would suggest getting several measurements and calculate the average of any waveform characteristics you desire, then compare the average to your individual signals. In this sense, you can get an idea of the variance between your measurements, but again, this will not be a reflection of their true accuracy.
07-20-2012 09:59 AM
ok,i think i have already done something like that.In my program i am calculating an average in every peak of my signal and i take my max average value multiply by 5% minus the maximum value,the result is my lower limit.My upper limit is the maximum value of the signal and i am checking if the minimum average value of the signal is between those limits then i have accuracy below 5%.I think this is a good aprroach