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

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

[Octave-bug-tracker] [bug #42037] Missing function integral


From: Nicholas Jankowski
Subject: [Octave-bug-tracker] [bug #42037] Missing function integral
Date: Wed, 20 Sep 2017 12:27:11 -0400 (EDT)
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Firefox/52.0

Follow-up Comment #19, bug #42037 (project octave):

quadv has a default abstol of 1e-6 which matches matlab. so for compatibility
reasons I think quadv should stay as is.

Simply passing abstol = 1e-10 to that integral test has it pass, and best as I
can tell versus matlab 2017a this is compatible behavior. 

Also, the different error values for double and single are unique to quadgk
best as I can tell, and matches matlab quadgk default tolerances according to
the help. 

There is no specification of different tolerance limits based on class in the
help for integral. I had just kept that text there from quadgk, but integral
documentation simply states tha abstol default is 1e-10, and RelTol is 1e-6,
and "Single precision integrations may require larger tolerances."

My thoughts on the simplest thing to do that also maintains compatibility is
just to pass 1e-10 and 1e-6 down to the quad functions (throwing a reltol
unimplemented warning for quadv until that gets fixed), and remove the
'single' distinction in the help text.

The attached update_integral.diff patch (builds on the checked in version)
makes that change to default reltol and abstol and the help text. Also, added
tests for checking single vs double input and output to maintain
compatibility.  last, I switched the matrix-valued test from 1/sqrt(x) to
exp(x) to get rid of the singularity warnings during test. a couple minor
spacing fixes too.

Also changed my Octave editor setting from CRLF (default on windows) to LF. 


(file #41845)
    _______________________________________________________

Additional Item Attachment:

File name: update_integral.diff           Size:4 KB


    _______________________________________________________

Reply to this item at:

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

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




reply via email to

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