github.com/govalues/money (go): Package money implements immutable monetary values in various currencies. It leverages the capabilities of decimal.Decimal for handling decimal floating-point numbers and combines them with a Currency to represent different currencies.  The range of monetary values supported refer to the Supported Ranges section of the decimal package description.  The package provides various arithmetic and comparison operations for monetary values, such as Add, Sub, Mul, FMA, Quo, and Rat. It also supports splitting an amount into equal parts and converting between different currencies using exchange rates.  The package allows for rounding monetary values using several methods, including Ceil, Floor, Trunc, and Round.  This example calculates the effective interest rate for a 10% nominal interest rate compounded monthly on a USD 10,000 balance.   In this example, a loan amortization table is generated for a loan with an initial amount of USD 12,000, an annual interest rate of 10%, and a repayment period of 1 year.   In this example, the sales tax amount is calculated for a product with a given price after tax, using a specified tax rate.
Keywords: currency|decimal|exchange-rate|financial|floating-point|general-decimal-arithmetic|go|golang|money