switched Java code to use MagnitudeBandHelper