@Test
public void testNearestPowerOfTwo() {

    assertEquals( 9, MathUtils.previousPowerOfTwo( 511 ) );
    assertEquals( 9, MathUtils.previousPowerOfTwo( 512 ) );
    assertEquals( 10, MathUtils.previousPowerOfTwo( 513 ) );
}