jiggzson / nerdamer

a symbolic math expression evaluator for javascript
http://www.nerdamer.com
MIT License
517 stars 82 forks source link

93222357 is OK, 93222358 is broken why? #495

Closed blueken closed 5 years ago

blueken commented 5 years ago
var solve1 = nerdamer('(93222357/131836323)*(-2*y+549964829/38888386)=10').solveFor('y')

console.log('===>', solve1[0].toString());

output: ===> -183321609/2416844668563868 . GREAT!

var solve1 = nerdamer('(93222358/131836323)*(-2*y+549964829/38888386)=10').solveFor('y')
console.log('===>', solve1[0].toString());

output: nerdamer.core.js:227 Uncaught E {name: "InvalidVariableNameError", message: " is not a valid variable name", stack: "InvalidVariableNameError: is not a valid variable…rs~main.9b6ee5566f68ff5d4346.bundle.js:117748:26)"}

WHY?

blueken commented 5 years ago

Maybe, It has no solve result when the number changed to 93222358

jiggzson commented 5 years ago

@blueken, I'll take a look at this anyway. I wonder if it's somewhat related to #491. I'm moving this to #322.

blueken commented 5 years ago

@blueken, I'll take a look at this anyway. I wonder if it's somewhat related to #491. I'm moving this to #322.

ok, thank you @jiggzson

jiggzson commented 3 years ago

Fix as of ... (not sure when). But tested in 1.1.10