Tag Archives: Math

Simple logarithm implementation in PIC assembler

Most natural observations are exponentational/logarithmic in nature. I often do simple hardware using Microchip PIC processors (usually 12F or 16F families). Hardware doing some business in the home. One such example is my Christmas-tree-lightning-controller. Basically it only turns my electric … Continue reading

Posted in Microcontoller, Open Source, Personal, PIC | Tagged , , | 4 Comments

Squareroot (sqrt) with BigDecimal

Recently I was refactoring some code from using double to using BigDecimal and suddenly needed a square root method. I remembered years ago I was taught a simple “successive approximation” method; believe it was grammar school. I searched the net … Continue reading

Posted in Java | Tagged , | 2 Comments

Financial (monetary) computations using floating point arithmetic [in JAVA]

In this article, I will discuss some of the issues in doing financial calculations in JAVA. The issues are not related to JAVA only, but to any calculation done in a “computer language” using binary floating point arithmetic, including calculations … Continue reading

Posted in Java | Tagged , | Leave a comment