Re: Configurable FP precision (Re: accuracy in calculation)

Nikita Zlobin via gnuplot-info <[email protected]>
Newsgroups gmane.comp.graphics.gnuplot.user
Message-ID <20190413165456.709e6c0d@cook60020tmp>
On Sat, 13 Apr 2019 03:46:28 -0700 (PDT)
David Lang <[email protected]> wrote:

> unfortunantly the arduino doesn't support double precision floats (if
> you define something as double, it still uses single)
> 
> so to get better precision, you would hvae to stop using hardware
> supported data types and switch to a multi-precision software library
> or something like that.
> 
> David Lang

My proposal is not about to force some specific type. It is rather
about ability to make it configurable. Wether target platform supports
only single float or more precise choices are supported, it could be
configured by build system.

But anyway thanks for remark - i really thought, that double is default
type in gnuplot code. Can't remember is it so - but when i made
experiment, writing gnuplot plugin, performing calculations with
libqalculate engine, i needed to look into gnuplot code to understand
some things.

And by own experience with qalculate - multiple precision stuff is
really slow. Nearly year ago (as said above, but more) i tried to write
glue plugin for gnuplot, which allowes to use libqalculate as
calculation engine, instead of plain glibc/libm. Main workflow with it
is to preload symbolic expressions into plugin, so that it prepares
them, then just call them by their ID, with necessary arguments.
https://github.com/nick87720z/gnuplot-qalc-plugin

The precision is probably overkill, and initially it was created in
hope to be good addon for qalculate itself, which uses gnuplot for
plotting, but it rather prepares static data set, then runs gnuplot
with them - thus gnuplot has adequate interface reaction, but range is
predefined before rendering and can't be changed without new render.

With current performance i'm not sure it will make it in qalculate
itself, though might be found useful on some super-pc, dedicated for
something i would call Bigcalc (workplay after bigdata).


_______________________________________________
gnuplot-info mailing list
[email protected]
Membership management via: https://lists.sourceforge.net/lists/listinfo/gnuplot-info
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.