From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

mean graph

If I have two graphs. Let's say y = mx + c and y =ax^2 +bx + c. Can I find the mean graph in labVIEW using some mathematical function? Can that grpah be plotted along with the two graphs mentioned? Let's say y is Force (N) and x is speed (m/s).
0 Kudos
Message 1 of 14
(3,149 Views)
I am assuming that you have an array of numbers for your X and Y (force and m/s).  You can feed the array into the Mean.vi located in Mathmatics>Prob & Stats > Mean.vi.  You can then take the output of the VI (the mean of the values) and use that to create your mean grpah.

Kenny
Kenny

Message 2 of 14
(3,144 Views)
Let's the first graph values are (1,9), (3,12), (5, 23), (7, 17) etc. and the second graph values are (2,4), (4,3), (6, 9), (8,67) etc. Both have units (m/s, N). How to find the mean graph? In ther words plot the ratio of the (Y value of graph 1)/(Y value of graph 2) vs the x value. Sorry it is actually not the mean graph but a ratio vs x graph. If not labVIEW which software is useful?
0 Kudos
Message 3 of 14
(3,130 Views)
Hi
 
Reading your last post, I see the problem of different x values. I assume you first have to inter- and extrapolate the y-values to have it available for the same x value.
 
Then you can make calculations on this values.
 
Here is an example. It first inter- and extrapolates the values for 1-8 and than calculates the average of two y-values. All is then displayed in a graph.
 
Hope this helps.
 
Thomas
Using LV8.0
--------------------------------------------------------------------
Don't be afraid to rate a good answer... 😉
--------------------------------------------------------------------
Message 4 of 14
(3,128 Views)
I do not have labview 8.0. I only have labVIEW 6.0. Anyway I am interested in "Here is an example. It first inter- and extrapolates the values for 1-8" Can you sent it in labVIEW6.0 or picture form.
0 Kudos
Message 5 of 14
(3,113 Views)
Here is a picture of it, as I have no possibility to convert it to LV6.0:
The arrays x1,y1 and x2,y2 correspond to the values you provided a few posts above. As I said, you have to inter- and extrapolate values to have the same x-values available. I used Hermite interpolation vis, which are provided with LV8.0. I don't know if there is something similar in LV6.0.
 
I hope this helps you.
 
Thomas

Message Edited by becktho on 05-11-2006 04:37 PM

Using LV8.0
--------------------------------------------------------------------
Don't be afraid to rate a good answer... 😉
--------------------------------------------------------------------
Message 6 of 14
(3,112 Views)
what is the sub vi attached to the x-values 0,1,2....8? Whee do I find it? Is in the mathematical pallete? Is it available in labVIEW6.0?
0 Kudos
Message 7 of 14
(3,100 Views)
It is a spline interpolation sub vi. And was added in 8.0.  I do not think there is a 7.1 equivalent, much less a 6.0 one.  Robot Sad  You may be able to roll your own sub vi using the 1D interpolation found on the array palette.

If you have the option, it would be easiest if you could modify the way the data is aquired so that they share a comon X.  Then finding the mean is trivial.
0 Kudos
Message 8 of 14
(3,089 Views)
"You may be able to roll your own sub vi using the 1D interpolation found on the array palette." Can give me more info on that? Can it be done using excel?
0 Kudos
Message 9 of 14
(3,082 Views)

I opened up LV 6.0i (been a long time since I have used that version) and I found the spline interpolant.vi under Mathmatics>Curve Fitting.  You may also have poly, rational and one other interpolation VI.

I do get an error that says that those VIs were last saved using 7.1.1 so I cant open them in 6.0, but you may have them.

 

Kenny

Kenny

Message 10 of 14
(3,083 Views)