Pure Erlang implementation of decimal arithmetic
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
ebin
include
src
.gitignore Add xmath module Feb 24, 2011
README.md Added initial implementation Feb 24, 2011
rebar

README.md

erldecimal, a pure-Erlang implementation of decimal arithmetic

Introduction

Erlang has native big integer support and double-precision floating point support. For some scientific and financial applications, decimal precision is required.

Building

$ ./rebar compile
==> erldecimal (compile)
Compiled src/decimal.erl

Using

1> decimal:to_decimal("12")
{d,0,12,0}
2> decimal:to_list(decimal:mult(decimal:to_decimal("144"), decimal:to_decimal("0.1"))).
"14.4"