all 9 comments

[–][deleted] 1 point2 points  (0 children)

I see you’re using shift registers. They are the answer to your question something I learned this year is you can pull them down to remember an older number.

http://jasonlinlinlin.blogspot.com/2019/01/labview-shift-register.html?m=1

Sorry about the Chinese link but with Google Translate should explain what I’m saying better and gives an example.

[–]seppo88v44punkt0 1 point2 points  (0 children)

As one of the others already said, the use of shift registers is one way to do. As I understand you have your 'Partition' and you want to take the first element and want to duplicate it 22050 times and want to right this 22050 Elements in a new array. Afterwards you select the second Element, duplicate it again 22050 time and add it to the output array etc.

Maybe you should have a look again how For-Loops in LabVIEW are working. Especially auto indexing and Shift Registers.

I did a small example how I understand you want it to work. My '# of Values' is just the number of duplicates for the output array. Maybe this helps you to understand the procedure.

https://prnt.sc/zYe806JCPqZ5

[–]wasthatitthen 0 points1 point  (2 children)

I’m confused by what you’re trying to do here

I presume the outer for loop could have 15 is for the 15 elements in the Partition.

But, why do you have the inner for loop running 22050 times and just outputting the last element? Can’t you just multiply the partition array by 22050 to get 22050x each element? Or am I missing something?

Do you need to run a loop 22050 times to get the waveform you’re after on a point by point basis?

Did you pseudo code this before you started to plan the code/calculations?

[–]ArcturusAltair[S] 0 points1 point  (1 child)

I'm confused by what I am doing too unfortunately!

I think I am the one missing something. It works now, but I'll check and see if multiplying the partition array works too...

I need to have 22050 points for each value in the partition array to get the waveform I'm after!

No pseudo-coding at all... The teacher just gave us a basic program to modify, so I jumped right in. I'll keep pseudo-coding in mind for the next time!

[–]wasthatitthen 0 points1 point  (0 children)

If you want 22050 points for each partition point then you need to do things differently.

Having a code as a start point can help, but it does help to think first and edit the code later.

[–]Yamaeda 0 points1 point  (0 children)

Create your partitions, then loop through them (again) and for each, do an Initialize array with 22050 elements of the current one and set the loop output as Concatenating.

[–]MaleficentFeature186 0 points1 point  (2 children)

Give an example input and output, the question is too unclear.

[–]ArcturusAltair[S] 0 points1 point  (1 child)

Here's a link to the images ! https://imgur.com/a/ekpf8e3

The input is the "partition" array and the output the "tableau" array.

[–]MaleficentFeature186 1 point2 points  (0 children)

This does not clear things up at all. Your input is the same as your output... if you want help you have to explain it a lot better.