Martin Rubey wrote:
> 
> I'd like to commit the attached patch.  It moves functionality to test
> approximate equality from elemnum.input to unittest.spad, which turns out tpo
> be a good thing, because there was a mistake in elemnum (epsilonrelative
> instead of epsilonRelative) that went unnoticed for many revisions, and made 
> us
> believe that numerics is better than it was.
> 

Looks OK.

> I also add a test for branch cuts that shows another feature of the new
> functionality: useful error messages.
> 
> Waldek, I test values of asin on a circle around the origin with radius 2.  Is
> this what you had in mind?
> 

I am not sure what you intend to test, but the test I have in mind
is like:

steps := 1000
h := %pi/steps
-- need to choose correct constant, 5.0 is just w wild guess
eps := 5.0/steps
valp := asin(2*exp(%i*h))
for i in 2..(steps-1) repeat
   valn := asin(2*exp(%i*h*i)
   norm(valn-valp) > eps => error "Jump detected"
   valp := valn

IIUC you test that numerical derivative agrees with symbolic one,
which is a different test -- given seqence of points x_n, your test
will detect jump between x_n and x_n+tdiff, but miss jumps between
x_n+tdiff and x_{n+1}.  The test I wrote above is designed to detect
jumps between x_n and x_{n+1}.
    

-- 
                              Waldek Hebisch
[EMAIL PROTECTED] 

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"FriCAS - computer algebra system" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/fricas-devel?hl=en
-~----------~----~----~----~------~----~------~--~---


Reply via email to