Page 1 of 1

User Def variables: error in maths function

Posted: Wed Mar 26, 2014 2:28 pm
by wibble44
Hi, Just upgraded to Analysis 8.05.0254, and I'm having issues with a user defined variable.

At first glance it looked similar to this one but I'm not sure it is.

I have a feed into analogue input 5 in DL1, and in analysis, I want to show an off/on result.

So, in my user defined variable I have "if ( VAR_0204 > 0.02 , 1, 0)". This used to work fine in previous versions, but after upgrade I now get [There was an error in the maths function "if ( VAR_0204 > 0.02 , 1, 0)"] pop up.

What am I doing wrong?

Thanks

Posted: Wed Mar 26, 2014 3:01 pm
by Bikey
I think you need to change the VAR_204 to "X". I'm not sure why this change was made to the software and why you can no longer reference other inputs in a custom equation for a variable as neither changes are helpful.

Posted: Wed Mar 26, 2014 3:05 pm
by wibble44
thanks Bikey, tried that but then get the same error message but referring to VAR_6001 rather than VAR_0204.

Doesn't quite make sense to me - if you change it to X, how would the user def variable know which external input variable you wanted to work with?

[EDIT] Aah - just spotted that you can set equations in the "set units" field in the external input variable. If I refer to "x" (or "X") in there for analogue input 5, I get the same maths error message, but referring to VAR_0204 as would be expected. So, still broken, but now I understand when to use the 'x'

Posted: Wed Mar 26, 2014 3:09 pm
by Bikey
sorry, was getting user variables mixed up with external inputs.
I have no answers on this one other than to check your syntax (does your actual equation have the extra spaces?).

Posted: Wed Mar 26, 2014 3:17 pm
by Support
Hi,

a possibility:

If you have set the list separator on your machine to something other than a comma you need to use this in the formulas - for example on a German machine you will need to use something like "if ( VAR_0204 > 0.02 ; 1; 0)"

This is something that has changed at some point, we used to force all our international customers to use commas and full stops!

Thanks,

Support (A)

Posted: Wed Mar 26, 2014 3:33 pm
by wibble44
Thanks - that doesn't seem to be it. Can't even blame ze germans.

If I use something as simple as x * 10 it still gives the error message.

Just tried uninstalling, reboot and re-installing. Same.

Posted: Wed Mar 26, 2014 3:42 pm
by wibble44
Just gone back to 8.5.175, all works fine.

Sumfink bust in 8.5.254 :(

Posted: Wed Mar 26, 2014 4:04 pm
by Support
I checked and it's definitely okay on the office machines :(

There is a new build going up early next week, maybe wait for that to be available and simply try that. If you are still getting an error, then we'll have to do some more detailed checking on your machine.

WBR, Support (A)

Posted: Wed Mar 26, 2014 4:05 pm
by wibble44
ok , will do. Thanks.