MathLib.Conic()

MathLib.Conic is MathLib's implementation of conics. In Mathlib a conic is the set of solution of the following equation ($x,y,z$ are projective coordinates). $\left(\begin{array}{ccc}x& y& z\end{array}\right)\left(\begin{array}{ccc}a& b& d\\ b& c& e\\ d& e& f\end{array}\right)\left(\begin{array}{c}x\\ y\\ z\end{array}\right)=0$ or written out $a{x}^{2}+bxy+c{y}^{2}+2dx+2ey+{f}^{2}=0$ You construct a conic by giving the constructor the parameters in form of a matrix:  var conic = new MathLib.Conic([[a, b, d], [b, c, e], [d, e, f]]);  If the conic is degenerated you should provide a second argument, containing the matrix of the dual conic.

Properties

.constructor
The function MathLib.Conic
.dual
The dual matrix.
.primal
The primal matrix.
.type
The string "conic"

Methods

.draw()
Draws the Conic.
.eccentricity()
Calculates the eccentricity of a conic.
.isDegenerated()
Checks if a conic is degenerated.
.isEqual()
Checks if a conic is equal to an other conic.
.latusRectum()
Calculates the latus rectum of a conic.
.linearEccentricity()
Calculates the linear eccentricity of a conic.
.meet()
Calculates the two meeting points of a conic and a line or the four meeting points with an other conic.
.normalize()
Calculates the normal form of a conic.
.splitDegenerated()
Splits a degenerated conic into two lines.

Static methods

.throughFivePoints()
Calculates a conic through five given points.