List of utility methods to do Ceil
double | ceil(double value, int scale) Ceil. double power = Math.pow(10, scale); return Math.ceil(value * power) / power; |
int | ceil(double Var1) ceil return (int) (Var1 + 0.9999D); |
int | ceil(double x) Rounds up a double to an int int xi = (int) x; return x > xi ? xi + 1 : xi; |
int | ceil(double x) A fast implementation of Math#ceil(double) . return BIG_ENOUGH_INT - (int) (BIG_ENOUGH_FLOOR - x); |
double | ceil(double x, double y) Truncate x up to the nearest y. return y * Math.ceil((x + .00001) / y);
|
double[] | ceil(double[] array) Rounds up each element of a given double array. double[] out = new double[array.length]; for (int i = 0; i < array.length; i++) out[i] = Math.ceil(array[i]); return out; |
int | ceil(final double num) ceil final int floor = (int) num; return floor == num ? floor : floor + (int) (~Double.doubleToRawLongBits(num) >>> 63); |
int | ceil(final double num) Round up given number. final int ceil = (int) num; return (ceil == num) ? ceil : ((num > 0) ? (ceil + 1) : ceil); |
int | ceil(float f) ceil return floor(f) + 1;
|
int | ceil(float f) Returns the first integer that is larger than the given float. int i = (int) f; if (i < f) i++; return i; |