GithubHelp home page GithubHelp logo

fossifyorg / calculator Goto Github PK

View Code? Open in Web Editor NEW
89.0 89.0 13.0 81.55 MB

A calculator for quick simple calculations with a nice user interface and no ads

Home Page: https://www.fossify.org

License: GNU General Public License v3.0

Kotlin 99.21% Ruby 0.79%
android calculator foss kotlin open-source

calculator's People

Contributors

aga-c avatar albertopellitteri avatar artemmolotov avatar dalampira avatar dchid avatar en2sv avatar esensar avatar fricyo avatar funkymuse avatar inepsie avatar linerly avatar liquidvacuum-by avatar ltguillaume avatar milotype avatar naveensingh avatar nuclearphoenixx avatar ochagovdanil avatar oersen avatar rex07 avatar slavekb avatar smarquespt avatar softinterlingua avatar solokot avatar spkprs avatar tibbi avatar trubitsyn avatar txemaq avatar weblate avatar welaq avatar westindev-lbr avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

calculator's Issues

Preserve operation order

Checklist

  • I made sure that there are no existing issues - open or closed - to which I could contribute my information.
  • I have read the FAQ and my problem isn't listed.
  • I have taken the time to fill in all the required details. I understand that the feature request will be dismissed otherwise.
  • This issue contains only one feature request.
  • I have read and understood the contribution guidelines.

Is your feature request related to a problem? Please describe.
Calculator currently does operations in a sequence, what can be a bit misleading, because all system calculators on Android I've seen were preserving operations order.

Describe the solution you'd like
Instead of current way of input, which works like traditional digital calculators, it should rather work like stock Android calculators. It should allow to input the whole equation and then compute it, preserving operation order.

Describe alternatives you've considered
In SMT Tibor wanted this feature to be only in scientific calculator mode (to be done maybe someday). However, I don't think it's a good idea, since stock calculators have this in every mode, not just scientific.

Additional context
Currently implementing it will be fairly easy, because Calculator is built on exp4j library which preserves operation order. However, if we change the number data type (issue #6), it will need to be done differently. But doing it from the scratch shouldn't be very hard, it's just implementing the simple algorithms like Shunting Yard.

Accuracy loss due to limited data type

Checklist

  • I can reproduce the bug with the latest version.
  • I made sure that there are no existing issues - open or closed - to which I could contribute my information to.
  • I have read the FAQ and my problem isn't listed.
  • I have taken the time to fill in all the required details. I understand that the bug report will be dismissed otherwise.
  • This issue contains only one bug.
  • I have read and understood the contribution guidelines.

Describe the bug
App relies on exp4j to perform calculations, which is based on Double data type. It's a floating-point data type, which causes accuracy loss, especially with very long inputs.

I see two possible solutions:

  1. Stop relying on exp4j for calculations (especially that app doesn't utilize its most powerful feature - preserving operation order) and rewrite the app to use BigDecimal instead Double.
  2. Add validation to input, which would stop users from inputting numbers too large to be handled by Double type. However, it won't guarantee that user won't run in the same problem during calculations.

To Reproduce
Steps to reproduce the behavior:

  1. Open the app.
  2. Tap any digit (despite 0) circa 20 times.

Result: At some point, instead of the digit I input, 0 is added.

Another case:

  1. Open the app.
  2. Tap decimal separator and then 9 over 13 times.

Result: At some point, the integer part of the number starts incrementing by one with each new decimal digit.

Expected behavior
I should see the number I've typed.

Device info (please complete the following information):

  • Model: OnePlus 9 Pro
  • OS: Android 13
  • Version Simple Calculator 5.12.0

README.MD full suite wrong link in all projects

Checklist
[ ] I can reproduce the bug with the latest version.
[ x] I made sure that there are no existing issues - open or closed - to which I could contribute my information to.

Describe the bug
In all repos FossifyX is still linked in the readme and in the issue template too. Would recommend updating it to FossifyOrg

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.