12-10-2014 04:25 PM
Hi everyone,
I am trying to simulate the second-order generalized-integral SOGI in LabVIEW and compare step by step with Simulink. The results are the same until I make two feedback loops by using feedback nodes. The graphs in LabVIEW show nothing. Can you give me some recommends for these iteration loop?
I attach SOGI and my simulation model for detail.
I really appreciate your nice help!
Best,
Tuan
12-10-2014 05:49 PM
How are you running this? I don't see a while loop in your VI. Feedback nodes and shift registers are similar, but have some subtle differences in their means of initialization. And Feedback nodes have different ways to initialize them as well.
It looks to me that this is a run once VI, and every time you click the run arrow to run it, you are reinitializing your feedback nodes with an empty array, which is why you are getting nothing.
12-10-2014 05:55 PM
Hi,
I just capture my SOGI part. The whole simulation is in while loop. I am wondering is neccessary to put feedback in a separate loop? In SOGI there is to iteration loop and LabVIEW automatically creates feedback node for me. I am still testing how it work but seem complicated to me. I attach my .vi model if you have time to look into it.
I would be happier to learn from you.
Best,
Tuan
12-11-2014 08:32 AM - edited 12-11-2014 08:35 AM
You need to initialize your feednode nodes to an array of the appropriate size to match your waveform length.
In LabVIEW, what happens if you have {1,2,3} - {0,2}? The output array will be of length of the smallest of the arrays being subtracted. So you will get {1,0}. So what happens when you subtract an empty array? You will have an empty array as your output.
Here's a quick edit of your code.