LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

concetanate arrays

Solved!
Go to solution

Hello,

 

I need to concetanate an array with zeros this way: for example, the original array: 123, created array:102030.

I am struggling with this for a long time, because I am a newbie in labview. The solution must be simple, but I can't find it.

Thanks!

 

Zoli

0 Kudos
Message 1 of 10
(3,574 Views)
Solution
Accepted by topic author borzola

Try the attached VI


Thanks,

Ninad Regundwar
Junior Engineer | ARAV Technologies | www.aravtech.com
0 Kudos
Message 2 of 10
(3,570 Views)

Thank you, you helped a lot!

0 Kudos
Message 3 of 10
(3,565 Views)

kudos are all time accepted

 


Thanks,

Ninad Regundwar
Junior Engineer | ARAV Technologies | www.aravtech.com
Message 4 of 10
(3,562 Views)

Your "solution" is undeserving of kudos.  There is absolutely no need to convert to/from strings to perform this operation.

 

concenate%20arrays[1].png

 

 


@borzola wrote:

Hello,

 

I need to concetanate an array with zeros this way: for example, the original array: 123, created array:102030.

I am struggling with this for a long time, because I am a newbie in labview. The solution must be simple, but I can't find it.

Thanks!

 

Zoli


That's not concatenation, that's interleaving that you've described.

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

Message 5 of 10
(3,545 Views)

you are right, it's so simple this way!

0 Kudos
Message 6 of 10
(3,534 Views)

@jcarmody wrote:

Your "solution" is undeserving of kudos.  There is absolutely no need to convert to/from strings to perform this operation.

 

 


That's not concatenation, that's interleaving that you've described.


I agree that the string conversion is silly, but would point out that the option selected for the loop output (right click, Tunnel Mode) uses the NI term "Concatenating".

 

Never used that feature myself; was curious about the unique looking terminal.

 

See LV2012 Features and changesThanks @tst !

 

I learned something new today! 

 

Concatenating.png


Now is the right time to use %^<%Y-%m-%dT%H:%M:%S%3uZ>T
If you don't hate time zones, you're not a real programmer.

"You are what you don't automate"
Inplaceness is synonymous with insidiousness

0 Kudos
Message 7 of 10
(3,530 Views)

@PhillipBrooks wrote:

@jcarmody wrote:

 

That's not concatenation, that's interleaving that you've described.


I agree that the string conversion is silly, but would point out that the option selected for the loop output (right click, Tunnel Mode) uses the NI term "Concatenating".

 


That *is* concatenating; I was referring to to the OP's use of the term.  I replaced the concatenating For loop with an Interleave Array node.

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 8 of 10
(3,499 Views)

I was obsessed with the strange for loop output that I missed that. I stand corrected Smiley Embarassed


Now is the right time to use %^<%Y-%m-%dT%H:%M:%S%3uZ>T
If you don't hate time zones, you're not a real programmer.

"You are what you don't automate"
Inplaceness is synonymous with insidiousness

0 Kudos
Message 9 of 10
(3,494 Views)

@jcarmody wrote:

Your "solution" is undeserving of kudos.  There is absolutely no need to convert to/from strings to perform this operation.

 

concenate%20arrays[1].png

 

 


@borzola wrote:

Hello,

 

I need to concetanate an array with zeros this way: for example, the original array: 123, created array:102030.

I am struggling with this for a long time, because I am a newbie in labview. The solution must be simple, but I can't find it.

Thanks!

 

Zoli


That's not concatenation, that's interleaving that you've described.


Of course if you want to save a couple scalar buffers (that really don't need to be there) and a bit of real estate.

Capture.PNG

SIDE NOTE: Smart compiler in 2013!  it really only has one of the duplicated array constants allocated.


"Should be" isn't "Is" -Jay
Message 10 of 10
(3,433 Views)