LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

configurable calculator string?

Hi,
 
In my application some data is measured and for every sequence of the application,
I calculate all statistical parameters (max, min, avg) of all signals.
So I have a lot of mathematical values about my test.
e.g. math. value 1, math value 2, math value 3, ... math value n.
 
Then the different users (over different sites) of this application want to evaluate this
test in their specific way. This means that they all have the list of all mathematical
parameters to start from, but they want to configure their end-result themselves.
e.g.
result A = (math value 1 + math value 2) / math value 3
result B = math value 4 * 100 - math value 1
...
 
I want to make such an editor in the application, so that the users can build the strings
like I entered above. I don't want these calculator strings hard-coded in the app,
but the user must be able to configure them.
Then after the test, I have to calculate first the mathematical values, and then I can
parse the formula strings with the actual data. Then I get :
Result A : (4 + 6)/ 2
Result B : 84*100 - 4
 
Now I need a tool or a dll to calculate these expressions. Is something like this available?
 
At first I was looking if the formula node's string was configurable at run-time, but it isn't.
 
Thanks in advance,
T.
0 Kudos
Message 1 of 3
(2,776 Views)
Have a look at "Eval Formula node" and the tools in the "Analyze...Mathematics..Formula...Advanced Formula Parsing" palette. Check the LabVIEW help for details.
(Not available in LabVIEW Base, you need LabVIEW Full or higher)
0 Kudos
Message 2 of 3
(2,768 Views)
Hi,
 
I found out the eval formule node at the same time. thx anyway!!
 
It's perfect for what I need. 1 question though :
 
Is it possible to 'extend' the nummer it recognizes?
It seems that it doesn't know the :
min(a,b)   or max(a,b)  function.
which I really need.
 
thx !
0 Kudos
Message 3 of 3
(2,766 Views)