LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

numeric integration extract portion

hello
i was getting signals from sensor. to wipe off the effect of noise on the result, i have set threshold level. what i need to do is to get the area under the 2 curve(shown in the attached diagram, with the threshold level is shown). setting the threshold level, i am able to get 4 instant time/ index by using basic level trigger vi. i then use this 4 value  to get dt (dt1=t2-t1, dt2=t4-t3). with both curves initial time is t1 and t3, using the extraction portion of signal vi to extract the signal with given initial time and dt(shown in diagram 2). what my question is after extracting the signal, the baseline is based on the threshold value i set in the 'basic level trigger' vi?or it just instead of the value of zero ?
it is because after extracting signal, i will need to carry the numeric integration.(i used simpson rule).  the numeric integration vi is integrating to get the area  from the baseline (either zero or starts from the threshold ? value)
however, remembering that i need to get the area under the curves. what i get is only the small portion of curve, how am i going to get the remaining portion(the portion starts from baseline to the threshold level in the curve) to carry the integration?is any vi in labview will help this?i read about the messages posted  in forum. but i was thinking that the method of getting area under the curve which i did was wrong. . did i?i doubt
(remark: the diagram at the right is the extraction portion of signal from the first curve)
anyone pls help.
thanks
regards
0 Kudos
Message 1 of 2
(2,866 Views)
Hello,

Performing numerical integration on the data set shown in your second graph will include the area from zero to your curve.  If you want it to include only the area from your baseline to your curve, you can just subtract your baseline value from the array before performing the integration to account for the offset.  Keep in mind that in LabVIEW, you can wire the array directly to a subtraction function with your baseline value as the other input - LabVIEW will take care of subtracting the baseline value from every element in your array. 
Cheers,

Matt Pollock
National Instruments
0 Kudos
Message 2 of 2
(2,830 Views)