# LabVIEW

cancel
Showing results for
Did you mean:

## Problem E7.3 (LabVIEW)

I've been trying to plot the ellipse with equation on Page 232 of Dr. Robert H. Bishop book but was unsuccessful. Anyone got a suggestion on this? Thanks in advance.
Message 1 of 12
(9,242 Views)

## Re: Problem E7.3 (LabVIEW)

Hi,

You can use the attached vi to plot an ellipse given its equation.

Regards,
Ankita A.
Applications Engineer
National Instruments
Message 2 of 12
(9,244 Views)

## Re: Problem E7.3 (LabVIEW)

Hi,

Thank you for responding to my problem. Actually the problem involve sin and cos function. I attached the problem here. Hope you could help. Thanks in advance.
Message 3 of 12
(9,246 Views)

## Re: Problem E7.3 (LabVIEW)

I have the same problem.

Briefly, the E7.3 problem is about plotting an ellipse using the equation:

r^2= A^2*B^2/(A^2*sin^2(ф)+B^2cos^2(ф))

where r, A and B are inputs.

Message 4 of 12
(8,663 Views)

Duplicated Post.

Serena M.

Message 5 of 12
(8,625 Views)

## Re: Problem E7.3 (LabVIEW)

Daigon,

Here's how I would approach the problem:

1. Create an array of values for 'phi' ranging from 0 to 2*pi.  You can use a For loop to do this, and the number of points in the array should depend on how smooth you want your graph to be.
2. With 'A' and 'B' as inputs, and the created 'phi' array as another input, calculate the value of 'R' from the equation provided.  I don't understand how 'R' is supposed to be an input.  Also, remember that you can use the math functions in LabVIEW in either scalars or arrays.  For example, you can multiply an array by a scalar with the 'Multiply' primitive.
3. Create 'X' and 'Y' arrays from the values of 'R' and 'phi', then bundle the 'X' and 'Y' arrays together to plot with and XY Graph.
You should be able to do all of this with loops and simple math in LabVIEW.  You shouldn't need to use a formula node to do this.  Let me know if this helps.

Chris M

Message 6 of 12
(8,603 Views)

## Re: Problem E7.3 (LabVIEW)

Hi CMal

From your explanation, I am still unable to solve the problem.

Would you be kind enough to help me solve the problem as I am really stuck.

Thank you very much.

Message 7 of 12
(8,259 Views)

Message 8 of 12
(8,222 Views)

## Re: Problem E7.3 (LabVIEW)

The cat,

Can you be more specific on which parts of my explanation you do not understand?  Are you having trouble creating a 1D array of 'phi' values, or is the problem with converting the 'R' values into 'x' and 'y' coordinates?  The more information you can give about what you have tried, the better.

Chris M

Message 9 of 12
(8,203 Views)

## Re: Problem E7.3 (LabVIEW)

Hi CMal

Yes I have trouble creating the 1D array of 'phi' values.

For the equation I have already done it with the fomula node

and plot it on a XY graph using the input A & B but the graph

is not an ellipse, instead it gives me a funny plot.

Message 10 of 12
(8,182 Views)