Actually, I added this function before I changed it to be BigDecimal (it was a float), and I changed it to BigDecimal as part of writing this function, which kind of negates the need for this function.  I'll just make it use the BigDecimal.