LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

dot product vi inialization and 1D vector input

Solved!
Go to solution

I am trying to build an adaptive noise canceller (LMS type 11) as shown in an NI document. I'm having trouble with the dot product vi. One input vector is an empty array and of course the output is NaN. Its in a feedback loop, so I think the vi should initialized with zero's .

My questions are:

How do I convert a 1D array to a 1D vector?

How do I initialize the VI?

 

The top part of the vi is a noisy singenerator and the bottom part is the adaptive noise canceller.

0 Kudos
Message 1 of 5
(3,696 Views)

Hi penguin,

 

shift registers are a little bit easier to "understand" than feedback nodes - atleast when it comes to initialisation:

check.png

It also helps to have a value different then zero for "y"!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 5
(3,691 Views)

Hi GerdW,

Thanks for your input. I appreciate your effort.  I will review what you have done. The question I have now is; how do the filter coefficients get updated without feedback? You show the output of the adder at the edge of the while loop not connected, or are you just showing the initialization part?

Regards,

penguin11

 

 

0 Kudos
Message 3 of 5
(3,648 Views)
Solution
Accepted by topic author penguin11

Hi penguin,

 

how do the filter coefficients get updated without feedback?

There is a feedback: It's called shift register.

 

You show the output of the adder at the edge of the while loop not connected

The output of the add function has a wire attached. And it is connected to a shift register. Did I mention shift registers before?

 

or are you just showing the initialization part?

I just cleaned up your VI. I did not change any functionality (by intention)!

 

When you have problems to work with shift registers you should take the free online courses offered by NI to LabVIEW beginners!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 4 of 5
(3,629 Views)

GerdW,

Thanks for your help. I read Hands on Labview  (Essick's) chapter on shift registers after I asked the follow up questions, of course. I see what you are talking about. The shift registers seem much simpler than feedback nodes. Your help when beyond the initial questions and is much appreciated.

regards,

Penguin11

0 Kudos
Message 5 of 5
(3,602 Views)