compare-oriented-cell
This module defines an ordering on oriented cells. It is similar to compare-cell
, except that it considers cells which are oriented clockwise/counter clockwise to be distinct.
Example
var compare = //Create 3 trianglesvar a = 0 1 2var b = 1 2 0var c = 1 0 2 //Triangle a and b are equivalent up to an even permutationconsole //Triangle a and c are different as they not oriented the sameconsole
Install
npm i compare-oriented-cell
API
require('compare-oriented-cell')(a, b)
Compares two oriented cells.
a, b
are lists of integers
Returns +/-1
if a
and b
are different, 0
otherwise
License
(c) 2015 Mikola Lysenko. MIT License