public static float toFloat(final double d){
    	BigDecimal b = new BigDecimal(Double.toString(d));
    	return b.floatValue();
    }
public static float toFloat(final double d){
    	BigDecimal b = new BigDecimal(Double.toString(d));
    	return b.floatValue();
    }
public static float toFloat ( final double d ) { BigDecimal b = new BigDecimal ( Double . toString ( d ) ) ; return b . floatValue ( ) ; }
to double
@param d double value
@return double
to double