ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Formula node

Solved!
Go to solution

Dear ,

 

I would like to use formula node to build a function that does the following:

y=16 + (x and1)*16 + log2[(x and1)*(2x-65535)+(65535-x)]

In Exel is quite straight forward as in the attachment.

any help how to translate it into Labview Formula node?

 

 

=16+MOD(C6;1)*16-LOG(65536-C6+MOD(C6;1)*(2*C6-65535);2)=16+MOD(C6;1)*16-LOG(65536-C6+MOD(C6;1)*(2*C6-65535);2)

0 Kudos
Message 1 of 5
(4,049 Views)

Hi malkowki,

 

check.png

Like this?

 

Is "AND 1" the same as "MOD 1"? (My Excel doesn't know about MOD()…)

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 2 of 5
(4,016 Views)

@malkowki wrote:

 

=16+MOD(C6;1)*16-LOG(65536-C6+MOD(C6;1)*(2*C6-65535);2)=16+MOD(C6;1)*16-LOG(65536-C6+MOD(C6;1)*(2*C6-65535);2)


You can copy that almost directly to the formula node like this:

formula_65532.png

 

off-topic:

Gerd, die Excel-Funktion MOD(;) entspricht in der deutschen Version der Funktion REST(Zahl;Divisor)

rest.PNG

0 Kudos
Message 3 of 5
(3,985 Views)
Solution
Accepted by malkowki

I the mean time I have found the solution just using the formula expression table from :

https://www.ni.com/docs/en-US/bundle/labview/page/formula-node-and-expression-node-functions.html

 

solution.PNG

Thanks for your answers

0 Kudos
Message 4 of 5
(3,964 Views)

Why would you do a "Mod 1"? That'd be the same as "Round towards -inf".

/Y

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 5 of 5
(3,961 Views)