https://github.com/semibran/euclidean
Calculate the Euclidean distance between two points
https://github.com/semibran/euclidean
distance euclidean geometry math
Last synced: 11 months ago
JSON representation
Calculate the Euclidean distance between two points
- Host: GitHub
- URL: https://github.com/semibran/euclidean
- Owner: semibran
- License: mit
- Created: 2017-07-01T23:15:37.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2017-07-01T23:16:21.000Z (almost 9 years ago)
- Last Synced: 2025-06-05T22:03:41.742Z (about 1 year ago)
- Topics: distance, euclidean, geometry, math
- Language: JavaScript
- Size: 1.95 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: license
Awesome Lists containing this project
README
# euclidean
> Calculate the [Euclidean distance](https://en.wikipedia.org/wiki/Euclidean_distance) between two points

This module exposes the function `distance(a, b)`, which determines the Euclidean distance between points `a` and `b`.
```js
> const distance = require('euclidean')
> distance([0, 0], [2, 2])
3
```
[](https://www.npmjs.com/package/euclidean)
## see also
- [`semibran/manhattan`](https://github.com/semibran/manhattan) - calculate Manhattan distance
- [`semibran/chebyshev`](https://github.com/semibran/chebyshev) - calculate Chebyshev distance
- [`semibran/vector`](https://github.com/semibran/vector) - more vector math
## license
[MIT](https://opensource.org/licenses/MIT) © [Brandon Semilla](https://git.io/semibran)