LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Using Matlab in Labview

Solved!
Go to solution

Hi there,

I can't get the Matlab function to work properly in LabVIEW.

I read this white-paper: http://www.ni.com/white-paper/3256/en/

However, in my environment it somehow does not work. If I try to recreate the example, I cannot define output variables; see the attached screen shot.

 

What I want to achieve in general is to get refprop (a fluid property database) working. It works fine in matlab but if I want to run it in Labview I get an error: Line 171, Column 14: unexpected char: '@'.

I do not know if the issues are related but it would be nice to be able to execute matlab code in labview at all.

Thanks,

Roland

0 Kudos
Message 1 of 4
(2,542 Views)
Solution
Accepted by topic author Roli_89

Hi Roli,

 

some notes:

1. I'm not a Matlab expert, but is that function called "linspace" instead of "linespace"?

2. Which version of RefProp are you using? I'm fine with the older RefProp 2.3 and it's integration in FluidProp…

3. There used to be an example VI you could use to call RefProp. Unfortunately NIST doesn't provide their old website anymore. Fortunately I have my own copy of that old code, see attachment.

Best regards,
GerdW


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

WOW thank you very much! I also found these examples online but they did not work and block diagram was password protected. I had to adjust the code due to different system decimal points. Thanks they work nicely. Can you may be tell me what function I have to use to calculate the vapour percentage from enthalpy and pressure.

0 Kudos
Message 3 of 4
(2,479 Views)

Hi Roli,

 

one experience I made with using RefProp: never change the decimal separator!

Always use the English point - there could be problems using the German comma…

Best regards,
GerdW


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