gnu-octave / symbolic

A Symbolic Package for Octave using SymPy
https://octave.sourceforge.io/symbolic/
GNU General Public License v3.0
151 stars 36 forks source link

bernoulli failing tests in sympy dev (1.12) #1217

Closed cbm755 closed 1 year ago

cbm755 commented 2 years ago
octave:6> test @sym/bernoulli
***** test
 m = sym([0 1; 8 888889]);
 A = bernoulli (m);
 B = [1 -sym(1)/2; -sym(1)/30 0];
 assert (isequal (A, B))
!!!!! test failed
assert (isequal (A, B)) failed
octave:7> test @double/bernoulli
***** test
 m = [0 1; 2 4];
 n = sym(m);
 A = bernoulli (m);
 B = double (bernoulli (n));
 assert (isequal (A, B));
!!!!! test failed
assert (isequal (A, B)) failed
octave:8> 
cbm755 commented 1 year ago

I assembled some homework:

I haven't yet done all this homework: I think I'm onboard but it may be an uncomfortable ride for a while! For example, right now SymPy has changed but mpmath has not so bernoulli(sym(1)) is 1/2 and bernoulli(1) is -0.5...