|
From: sfeam <eam...@gm...> - 2019-04-10 16:56:19
|
On Wednesday, 10 April 2019 18:11:19 Patrick Dupre wrote:
> Hello,
>
> I guess that it may be a good illustration of what I get.
> running under gnuplot
>
> I={0,1}
> set sample 1001
> sqrt_pi = sqrt (pi)
> sqrt_ln2 = sqrt (log(2))
> z_ (x, wL, wG) = (x + I * abs (wL)) / wG
> w_ (z, wG) = faddeeva (z) / wG / sqrt_pi
> w_prim (z, wG) = (-2 * z * w_ (z, wG) + 2 * I / pi / wG) / wG
> dd_Fadd (x, wL, wG) = (wGG = abs (wG) / sqrt_ln2, z = z_ (x, wL, wGG), -2 * (w_ (z, wGG) / wGG + z * w_prim (z, wGG)) / wGG)
> plot [-1000:1000] real (dd_Fadd (x, 270, 0.206))
> plot [-1000:1000] real (dd_Fadd (x, 270, 0.106))
Since I am not familiar with these functions, I do not know what to
look for or what to expect.
You say "the difference should never be zero even if it is close to 1e-10"
That indeed is what seems to result from plotting
abs( real (dd_Fadd (x, 270, 0.206)) - real (dd_Fadd (x, 270, 0.106)))
Have I misunderstood the description?
Ethan
> ===========================================================================
> Patrick DUPRÉ | | email: pd...@gm...
> Laboratoire interdisciplinaire Carnot de Bourgogne
> 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE
> Tel: +33 (0)380395988
> ===========================================================================
>
>
> Sent: Tuesday, April 09, 2019 at 10:04 PM
> From: "Ethan Merritt" <eam...@gm...>
> To: "Patrick Dupre" <pd...@gm...>
> Subject: Re: [Gnuplot-info] accuracy in calculation
> Your attachments did not make it through to me. Perhaps you could ask again and
> show the function code in-line with the mail?
>
> Ethan
>
> On Tue, Apr 9, 2019 at 11:36 AM Patrick Dupre <pd...@gm...> wrote:
> Hello,
>
> I have an issue when I take the difference between 2 functions (see attached
> files).
>
> On the first one, you have the 2 functions, and on the 2nd one you have
> the difference. which should never be zero even if it close to 1e-10
>
> How can I increase the precision of the calculation?
>
> I am using gnuplot 5.2
>
> Thank.
>
> ===========================================================================
> Patrick DUPRÉ | | email: pd...@gm...
> Laboratoire interdisciplinaire Carnot de Bourgogne
> 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE
> Tel: +33 (0)380395988
> ===========================================================================
>
> _______________________________________________
> gnuplot-info mailing list
> gnu...@li...
> Membership management via: https://lists.sourceforge.net/lists/listinfo/gnuplot-info
>
|