- colour.geometry.ellipse_coefficients_canonical_form(coefficients: ArrayLike) NDArrayFloat #
Return the canonical form ellipse coefficients from given general form ellipse coefficients.
The general form ellipse coefficients are the coefficients of the implicit second-order polynomial/quadratic curve expressed as follows:
\(F\left(x, y\right)\) = ax^2 + bxy + cy^2 + dx + ey + f = 0`
with an ellipse-specific constraint such as \(b^2 -4ac < 0\) and where \(a, b, c, d, e, f\) are coefficients of the ellipse and \(F\left(x, y\right)\) are coordinates of points lying on it.
coefficients (ArrayLike) – General form ellipse coefficients.
Canonical form ellipse coefficients.
- Return type:
>>> coefficients = np.array([2.5, -3.0, 2.5, -1.0, -1.0, -3.5]) >>> ellipse_coefficients_canonical_form(coefficients) array([ 0.5, 0.5, 2. , 1. , 45. ])