List of utility methods to do KMH Convert
double | kmh2ms(double kmh) Translate km/h to m/s. return kmh / 3.6;
|
Double | kmhToKnots(Double kmh) Converts kilometers per hour to knots. return kmh == null ? null : new BigDecimal(kmh).multiply(KMH_TO_KNOTS).doubleValue(); |
Double | kmhToMps(Double kmh) Converts kilometers per hour to meter per seconds. if (kmh == null) { return null; return kmh * 0.277777778; |
long | kmhToMs(long kmh) Convert kilometers/hour into meters/second. return (long) (kmh / 3.6); |
Double | knotsToKmh(Double knots) Converts knots to kilometers per hour. if (knots == null) { return null; BigDecimal retour = new BigDecimal(knots); retour = retour.divide(KMH_TO_KNOTS, 2, BigDecimal.ROUND_FLOOR); return retour.doubleValue(); |
int | kntsToKmh(int knots) knts To Kmh return (int) Math.round(knots * 1.852); |
float | msToKmh(final float ms) Converts a speed given in meter per second to kilometer per hour. return ms * MS_TO_KMH;
|
int | msToKmh(float ms) Ms to kmh int. return (int) (ms * 3.6d); |