07-26-2017 04:20 AM
Hello,
I have a question regarding "creating a spaced array" in LabView using this following math script.
Dt=diff(t1);
dt=mean(Dt);
tStart = min(t1(1),t2(1));
tEnd = max(t1(end),t2(end));
tEqui = (tStart:dt:tEnd)'
where, t1 And t2 are timestamps from labview.
Thanks in advance.
07-26-2017 04:32 AM
Look for the ramp function.
07-26-2017 06:39 AM
Is this the way to do?
Thanks,
Akash
07-26-2017 08:59 AM
I don't think you need that FOR loop around the Ramp Function. You could also replace some of that Math Script with real LabVIEW code to get some performance boost.
07-26-2017 09:26 AM
hey,
can I know which array function you used in that code?
I couldn't find it.
and I have attached the m-file of the project I am working on trying to convert the Matlab code to labview but getting errors as I am analyzing dynamic data.
so any way you could just give pointers about these functions from m-file in converting into labview code:
ind_nonunique=find(diff(time)==0)+1;
nFFT = 2^nextpow2(2*n-1);
Xc = real(ifft(X.*conj(Y)));
Thanks,
Akash
07-26-2017 10:13 AM
@Akash_MV wrote:
can I know which array function you used in that code?
Which one? I have Delete From Array, Array Max & Min, Build Array (which is resizable), Derivative x(t).vi, and Ramp Pattern.vi.
07-26-2017 10:23 AM
yes I figured it out. it was delete from array function.
Thanks,
Akash.