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: 

How can I get X when Y=0 on a XY LabVIEW graph?

Can anyone please tell me how to send the value of of (x ,0) to a numeric indicator in the front panel?
How can I get x and y componets inside a mathlab script, and computed values out the script,into the front panel?
Is it possible to manipulate x-y graphs; like cuting it or finding the line equation of a small selected portion?
 
0 Kudos
Message 1 of 9
(4,228 Views)
Graphs don't do math, but you can easily work on the underlying data with plain LabVIEW code (linear regression, fitting, selecting of a data subset bounded graph cursor positions, etc.) . How does your data look like?
Message 2 of 9
(4,216 Views)

Like altenbach said you shouldn't work on graph. I you want to cut zreen of graph and calculate the data of them you need to use image processing functions to get the data from the image.

Instaed of this you should work on numebrs directly taken from math script and then you can do what do you need like fit, find zeroes, ect.

bogdani

Message 3 of 9
(4,210 Views)

In order to create a graph, you had to have fed an array of data pairs into the graph indicator.  From that array, simple search for 0 in the Y column and get the index for that point.  Then use the index to get the X value.

Here is some info on line formulas in case you don't know (If you do then ignore).  The formula for a line is y=Mx+B, where M is the slope and B is the Y intercept (value of Y when X is zero).  If you take any two data pairs from the array, (X1,Y1) and (X2,Y2), you can get the slope (M) by the formula (Y2-Y1)/(X2-X1).  You can then get B by using one of the data points (X1,Y1) with the formula B=Y1-MX1.  Now you can get the value of X when Y=0 by the formula x= 0-B/M.

- tbob

Inventor of the WORM Global
Message 4 of 9
(4,188 Views)
Here is an Exel program I use to prossed data aquired using LabVIEW. The point is that I want to aquire and prosses data using only LabVIEW.I use a Keithley 2400 meter to do a sweep from about -20V to 80V and get a curve from a Langmuir probe. Through a GPIB  a  I control the Keithley with LabVIEW and dispay the graph. The data is send to a file where I can work on it with Exel, Matlab and Mathcad.
If I can find a way to do all in LabVIEW  the prosses of data aqusition would  be more efficient.
0 Kudos
Message 5 of 9
(4,176 Views)
You can use <a  href="http://zone.ni.com/devzone/conceptd.nsf/2d17d611efb58b22862567a9006ffe76/55181a206a523fd186256abe00626ea9?OpenDocument">"Peak Detector"</a>
Message 6 of 9
(4,172 Views)
Veteran tbob:
My problem is not math, my problem is telling LabVIEW to give me what I want. first I get a reading, lets say 2 collumns, current and voltage. Now from a graph where x is a voltage sweep(v) and y is the current(I) ; I need the maximum of the first derivate of the electron current to the probe. That number is called the plasma potential (Vp). Using (Vp-v) as X-axis and Ln(|I|) as Y axis, where Vp-v=0 I get the intercept (b) and e^b = saturation current(Ies). So there is my "Knee" (Vp,Ies). I can do this using other programs but I dont know how to tell LabVIEW to do this for me and no one has been able to tell me without using LabVIEW programing terms that I really dont understand. I am new to this program and I dont know much about it.  
0 Kudos
Message 7 of 9
(4,132 Views)


@Gaudier wrote:
I can do this using other programs but I dont know how to tell LabVIEW to do this for me and no one has been able to tell me without using LabVIEW programing terms that I really dont understand. I am new to this program and I dont know much about it.

Well, it is hard to describe a LabVIEW program without using "LabVIEW terms" 😉

This will be very difficult without some basic understanding of LabVIEW. You should do some tutorials or attend a basic LabVIEW course.

I have made a very simple demo that:

  1. graphs the raw data (I vs. V) on an xy graph.
  2. Lets you pick Vp using a yellow cursor
  3. graphs ln(abs(I)) vs. Vp-V on a second graph.
  4. Pick an x range on the second graph and it will do a linear regression of the data subset located between the two cursors.

Modify as needed.

Message 8 of 9
(4,117 Views)

I have so much to learn.

Thanks!

JR Gaudier PUPR Plasma Lab.

0 Kudos
Message 9 of 9
(4,087 Views)