LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

labview equation box quadratic equation

Hello to all tge members,
 
Currently, i'm on my intership and my intern includes programming using LabView 7.1. So, i just got to know this sofware last week. In order to programme, i need to get used to this software and of course, create some programs. I've done an exemple/exercice and i'm having a single error which bugs me so bad!
Well, it goes something like this:
 
I wanted to visualise a graph of an quadratic equation : y=ax²+bx+c
the a,b,c,and x are all variable. when i used the equation box, i entered this equation (y=a*x^2+b*x+c) with 4 inputs(a,b,c,x) and an output(y). I linked this box to the icon graph and lastly, i tried to execute it. Unfortunely, it appeared this error " y=a*x^2+b*x+c;#"  and it said, whole type necessary(it's a direct translation from french) something like that.
 
So please do help me please. Thank you in advanced!
 
Dhirah
Message 1 of 19
(7,245 Views)
Hi Dhirah,

you should try "x**2" (standard C syntax!) instead of "x^2"Smiley Wink You can also transform your formula into y=((a*x)+b)*x+c avoiding power functions.

And maybe try to use basic LabView functions instead of formula node right from the beginning, may make things easier later on...


Message Edited by GerdW on 04-01-2008 11:01 AM
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 19
(7,242 Views)

Hi Dhirah,

do you use the formula node? If yes x^2 is not possible, use pow(x, 2) instead of it.

Mike

0 Kudos
Message 3 of 19
(7,239 Views)
Hye MikeS81 and GerW,
 
Thank you so much for the help! I'm glad that you guys helped me out! It did work! So, look out for me in the near future, wil be asking lots of questions soon! 🙂
 
Dhirah
0 Kudos
Message 4 of 19
(7,230 Views)

How can  I can to solve this problem on My Block Panel .

Write a quadratic equation solver that will accept values for A,B, and C, defined by Ax^2+Bx+C=0 and then compute both quadratic solutions( one solution using the plus symbol, The other using the minus In the following e


 

0 Kudos
Message 5 of 19
(6,448 Views)

This has nothing to do with the existing 5 year old thread. I recommend to start a new thread for your question.


@kukin wrote:

How can  I can to solve this problem on My Block Panel .


 

There is no Block Panel, just a Block Diagram and a Front Panel.

 


@kukin wrote:

Write a quadratic equation solver that will accept values for A,B, and C, defined by Ax^2+Bx+C=0 and then compute both quadratic solutions( one solution using the plus symbol, The other using the minus In the following e 


You need three numeric controls: A, B, C

You need two numeric Indicators, one for each solution

In-between these terminals, you simply implement the equation as it can be found in any text book or even wikipedia.

 

Where exactly did you encounter any problems? What did you try so far?

 

 

 

0 Kudos
Message 6 of 19
(6,444 Views)

I would like to konw which math fuction I should use to solve my problem on block diagram I new using Labview

0 Kudos
Message 7 of 19
(6,441 Views)

How can I delete icon in block diagram

0 Kudos
Message 8 of 19
(6,432 Views)

@kukin wrote:

I would like to konw which math fuction I should use to solve my problem on block diagram I new using Labview


First you should start with a few introductory LabVIEW tutorials, then implement this equation.

 

The bulk of the required tools are in the numeric palette. Have you tried?

 

0 Kudos
Message 9 of 19
(6,432 Views)

How can I delete icon in block diagram

0 Kudos
Message 10 of 19
(6,429 Views)