Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

monotone-chain-convex-hull

image-js130.1kMIT1.1.0TypeScript support: included

Monotone Chain Convex Hull algorithm

convex, hull

readme

monotone-chain-convex-hull

NPM version npm download

Monotone Chain Convex Hull algorithm.

Installation

$ npm install --save monotone-chain-convex-hull

Usage

import monotoneChainConvexHull from 'monotone-chain-convex-hull';

const result = monotoneChainConvexHull([
  [1, 1],
  [3, 0],
  [2, 1],
  [3, 2],
  [1, 2],
  [0, 2],
  [0, 0],
]);
// result is [[0, 0], [0, 2], [3, 2], [3, 0]]

API Documentation

License

MIT

changelog

Changelog

1.1.0 (2022-07-31)

Features

Bug Fixes

  • do not sort points in-place (33aa0d2)