The problem is caused by an operation (division) that would result in a recurring decimal.
The solution is to specify a scale when performing a division, for example:
BigDecimal one = new BigDecimal("1");
BigDecimal three = new BigDecimal("3");
BigDecimal oneDivThree = one.divide(three, 200, RoundingMode.HALF_UP);