CFLib.org – Common Function Library Project

KilometersToNauticalMiles(kilometers)

Last updated February 25, 2002

author

Tom Nunamaker

Version: 1 | Requires: CF5 | Library: MathLib

Description:
Converts kilometers to nautical miles.

Return Values:
Returns a numerical value.

Example:

<CFSET km = 100>
<CFOUTPUT>
Given km = #km#<BR>
#km# kilometer(s) = #KilometersToNauticalMiles(km)# nautical miles. <br>
</CFOUTPUT>

Parameters:

Name Description Required
kilometers The number of kilometers to convert. Yes

Full UDF Source:

/**
 * Convert kilometers to nautical miles.
 * 
 * @param kilometers      The number of kilometers to convert. 
 * @return Returns a numerical value. 
 * @author Tom Nunamaker (tom@toshop.com) 
 * @version 1, February 24, 2002 
 */
function KilometersToNauticalMiles(kilometers) {
  // NOTE: 1852 meters has been adopted as the international nautical mile 6076.11549 feet)

  return kilometers / 1.852;
}

Search CFLib.org


Latest Additions

Raymond Camden added
QueryDeleteRows
November 04, 2017

Leigh added
nullPad
May 11, 2016

Raymond Camden added
stripHTML
May 10, 2016

Kevin Cotton added
date2ExcelDate
May 05, 2016

Raymond Camden added
CapFirst
April 25, 2016

Created by Raymond Camden / Design by Justin Johnson