LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Creating Spaced array in Labview

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.

 

 

 

0 Kudos
Message 1 of 7
(2,779 Views)

Look for the ramp function.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 2 of 7
(2,771 Views)

Is this the way to do?

 

 

Thanks,

Akash

0 Kudos
Message 3 of 7
(2,738 Views)

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.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 4 of 7
(2,710 Views)

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

 

0 Kudos
Message 5 of 7
(2,700 Views)

@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.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 6 of 7
(2,674 Views)

yes I figured it out. it was delete from array function.

 

Thanks,

Akash.

 

 

0 Kudos
Message 7 of 7
(2,669 Views)