LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Parse and evaluate parsed formulas involving arrays

Solved!
Go to solution

I wrote something a couple of years ago that was able to parse formulas like you're describing, including the ability to choose an index from an array input, but it's limited to scalar outputs. Not sure if it could be modified to support array outputs or not - I've never had a need for it. I highly doubt this is going to be even close to as fast as any of the compiled libraries you found, but it's written entirely in LabVIEW for whatever that's worth.

 

One caveat is you have to prefix all of your variable names with either dds_ or reg_ because I needed a way to distinguish variable names from operands (list here). I choose those two prefixes because this used to be part of a larger project, but you could edit the regex in the Equation String Parser.vi subVI to change it to whatever you want.

 

Saved in LV18 because it uses .vims

0 Kudos
Message 11 of 13
(282 Views)

 parse.png

0 Kudos
Message 12 of 13
(253 Views)

Probably too late, but I will put this out there anyway.

 

Here is LabVIEW library for muParser: https://www.vipm.io/package/lv_muparser/

 

Sounds like you could use muParser's Bulk Mode evaluation on your array data.

Porter_0-1697165274439.png

 

0 Kudos
Message 13 of 13
(197 Views)