avarel / aljava Goto Github PK
View Code? Open in Web Editor NEWAlgebraic equation solver and expression simplifier in Java.
Home Page: https://github.com/Avarel/Aljava
Algebraic equation solver and expression simplifier in Java.
Home Page: https://github.com/Avarel/Aljava
I was trying to simplify the term [1.0 - [s_{0} - [1.0 - 0.0] / [2.10526]] * [2.10526]] / [2.10526 - 1.0] in Aljava.
As a result I am getting 60511419/95738581 * s0 + 100000/55263 ( 0.6320484215240249 s0 + 1.8095289796066083) instead of 1.90476449 s0 + 1.8095289796066083.
In general I experienced more of those bugs whenever the integers in the fractions are rather large.
Expression const_1_left = new Expression(10).div(new Expression(10));
Expression var = new Expression("s0");
Expression frac_0 = new Expression(210526).div(new Expression(100000));
Expression const_0 = new Expression(0).div(new Expression(10));
Expression const_1 = new Expression(10).div(new Expression(10));
Expression num = const_1.minus(const_0);
Expression frac = new Expression(210526).div(new Expression(100000));
Expression result_end = num.div(frac);
Expression result_im = var.minus(result_end);
Expression result_im2 = frac_0.times(result_im);
Expression result_num = const_1_left.minus(result_im2);
Expression denom_left = new Expression(210526).div(new Expression(100000));
Expression denom_right = new Expression(10).div(new Expression(10));
Expression denom = denom_left.minus(denom_right);
Expression result = result_num.div(denom);
System.out.println(result);
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.