Page 1 of 1
ruby calculation error
Posted: Sun Jun 05, 2016 8:56 am
by tester
I'm getting strange calculation error in ruby schematic.
What I'm missing here?
Re: ruby calculation error
Posted: Sun Jun 05, 2016 9:14 am
by tulamide
Nothing. You're just working with single precision values from green, and output to green (which converts from Ruby's double precision back to single precision). If you need accuracy, stay in Ruby for both input data, multiplication factor and output data. (Enter "skuk2" as last line in the RubyEdit and look at the values in the info pane to see what I mean)
Re: ruby calculation error
Posted: Sun Jun 05, 2016 10:29 am
by tester
So this amount of error will not propagate and kill the statistics?
Because equations are made specifically for statistics.
Re: ruby calculation error
Posted: Sun Jun 05, 2016 11:18 am
by tulamide
With this exact structure (input once from green, output once to green) it won't propagate. But if you use the output on further calculations, it will. That's why I said, stay in Ruby. It is easy to load data directly into Ruby, and also to save it directly from Ruby. And visually presenting data can also be done from within Ruby.
But if you absolutely need to go to green, then Ruby and again green, just make sure to do the translations/conversions only once.
Re: ruby calculation error
Posted: Sun Jun 05, 2016 6:41 pm
by tester
Ok., thanks. I think in my case - rounding to 3rd place should fixe the problem. What I was worried were high output changes from small recalc differences, but maybe i't's not the case (structure of equations).