octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #48307] sinc loses precision for large argumen


From: Lachlan Andrew
Subject: [Octave-bug-tracker] [bug #48307] sinc loses precision for large arguments
Date: Mon, 27 Jun 2016 00:37:02 +0000 (UTC)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:43.0) Gecko/20100101 Firefox/43.0

Update of bug #48307 (project octave):

                  Status:                    None => Patch Submitted        

    _______________________________________________________

Follow-up Comment #6:

The attached patch should improve the accuracy for large arguments.  For
example,


sinc (1e10)


gives 0.

The downside is that it is about 40% slower for scalars or 20% slower for
large vectors.  I'm not sure how important that is.  It could be sped up
slightly for large vectors of small arguments by only doing the reduction
modulo 2 for large components.

I'd be inclined to have a separate sinc_robust to evaluate sinc accurately for
large arguments, and keep the default sinc as something that is fast for
typical arguments.

(file #37591)
    _______________________________________________________

Additional Item Attachment:

File name: bug_48307_sinc.cset            Size:0 KB


    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?48307>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]