LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Network Analyzer labview program

i don't know i'm having a hard time understanding

0 Kudos
Message 41 of 75
(1,716 Views)

The way the program is setup you have it with a single loop, can i implement that code you have in a nested for loop where the outer loop will be sweeping in the "X direction of the grid" and the inner loop sweeping in the "Y direction of the grid."

0 Kudos
Message 42 of 75
(1,705 Views)

You can use two loops if you wish. I chose to do it with one loop since it made the arithmetic easier. You just need to calculate the correct indices for the Replace Array Subset based on which iterations you are doing of the outer and inner loop.

0 Kudos
Message 43 of 75
(1,691 Views)

I tried using the nested for loops i'm having a hard time coming up how to connect for the outer loop 

0 Kudos
Message 44 of 75
(1,686 Views)

Update. When i Run the program i only get the amount i set in the "Sweep X." It is as if it doesn't even go inside the nested for loop. 

0 Kudos
Message 45 of 75
(1,656 Views)

I would bundle the frequency and data arrays in to a cluster and then deal with a 1D array of clusters.

 

Don't know if that's how the experts would do it, but I try to avoid multidimensional arrays when possible because I find that my diagram is hard to read when using multidimensional arrays.

0 Kudos
Message 46 of 75
(1,623 Views)

I think the way my code is set up i think I need to use multidimensional arrays because I don't know how I would shift over my data(append all the columns to each other). See when i run my code, if i set my "Sweep X" to 2 and my "Sweep Y" to 4, the program will run 8 times which is correct but in my output on excel it only display 2 times thats where i'm getting stuck. 

0 Kudos
Message 47 of 75
(1,618 Views)

I think the way my code is set up i think I need to use multidimensional arrays because I don't know how I would shift over my data(append all the columns to each other). See when i run my code, if i set my "Sweep X" to 2 and my "Sweep Y" to 4, the program will run 8 times which is correct but in my output on excel it only display 2 times thats where i'm getting stuck. 

0 Kudos
Message 48 of 75
(1,618 Views)

Do you know how I can add headers to each of those columns? 

 

File Attached

0 Kudos
Message 49 of 75
(1,586 Views)

You don't want to be using the write string to file VI, you will want to use the write to spreadsheet VI.  Attached is a snippet of what you want to do instead of the write string to file.

20451i455C7D287EBC8E74

National Instruments
Applications Engineer
0 Kudos
Message 50 of 75
(1,568 Views)