Represents a line.
Namespace: Extreme.Mathematics.Curves
Assembly: Extreme.Numerics (Extreme.Numerics)
Syntax
| Visual Basic (Declaration) |
|---|
Public NotInheritable Class Line _ Inherits Polynomial |
| C# |
|---|
public sealed class Line : Polynomial |
| C++ |
|---|
public ref class Line sealed : public Polynomial |
Methods
| Icon | Type | Description |
|---|---|---|
| Add(Double, LinearCombination) |
Adds a multiple of another LinearCombination to this instance.
| |
| Add(LinearCombination) |
Adds another LinearCombination to this instance.
| |
| Clone() |
Constructs an exact copy of this instance.
| |
| ComplexSlopeAt(DoubleComplex) |
Evaluates the slope or first derivative of a polynomial
for a DoubleComplex argument.
| |
| ComplexValueAt(DoubleComplex) |
Evaluates the polynomial for a DoubleComplex
argument.
| |
| Deflate(Double) |
Deflates a polynomial by dividing out a root.
| |
| Equals(Object) |
Overridden. Returns a value indicating whether this
instance is equal to a specified object.
| |
| Finalize() | ||
| FindComplexRoots() |
Gets the set of roots of the Polynomial.
| |
| FindRoots() |
Returns the X-coordinates of the point where this
Line crosses the X-axis. If the line is parallel
to the X-axis, the method returns an empty array.
| |
| GetCurveFitter() |
Returns a CurveFitter object that can be used to fit the curve to data.
| |
| GetDerivative() | ||
| GetHashCode() |
Overridden. Returns the hash code for this instance.
| |
| GetType() | Gets the Type of the current instance. | |
| Integral(Double, Double) |
Gets the definite integral of the curve between the
specified X-coordinates.
| |
| LeastSquaresFit(Double[](), Double[]()) |
Returns the Line that is the best least squares
fit through the given set of points.
| |
| MemberwiseClone() | Creates a shallow copy of the current Object. | |
| OnParameterChanged(Int32, Double) |
Called when a coefficient of the polynomial is changed.
| |
| OnParameterChanging(Int32, Double) |
Called before the value of a curve parameter is changed.
| |
| PassesBetween(Point, Point) |
Returns a value that indicates whether a line passes between two
points.
| |
| Reduce() |
Reduces the degree of a polynomial so that the leading coefficient is different
from zero.
| |
| Reduce(Double) |
Reduces the degree of a polynomial so that the leading coefficient is greater than
the specified tolerance.
| |
| SlopeAt(Double) |
Gets the slope of the curve at the specified
X-coordinate.
| |
| Subtract(LinearCombination) |
Subtracts another LinearCombination from this instance.
| |
| TangentAt(Double) |
Gets the tangent Line to the curve at the
specified X-coordinate.
| |
| ToString() |
Returns a string representation of this instance.
| |
| ValueAt(Double) |
Gets the Y-value of the curve at the specified
X-coordinate.
|
Constructors
| Icon | Type | Description |
|---|---|---|
| LineNew(Double, Double) |
Constructs a new Line with the specified value
at X-coordinate zero and slope.
| |
| LineNew(Point, Double) |
Constructs a new Line through a point with the
specified slope.
| |
| LineNew(Double, Double, Double) |
Constructs a new Line through a point with the
specified slope.
| |
| LineNew(Double, Double, Double, Double) |
Constructs a new Line through two points.
| |
| LineNew(Point, Point) |
Constructs a new Line through two points.
|
Properties
| Icon | Type | Description |
|---|---|---|
| Basis |
Gets the function basis for the polynomial.
| |
| Coefficient(Int32) |
Gets or sets the coefficient of the function with the specified
index.
| |
| Degree |
Gets the degree of the polynomial.
| |
| Item(Int32) |
Gets or sets the coefficient of the function with the specified
index.
| |
| Parameters |
Gets the collection of parameters that determine the shape of this
Curve.
| |
| Slope |
Gets or sets the slope of the line.
|
Remarks
Use a Line to describe a linear
relationship between two quantities. It has constant
SlopeAt(Double). Unless the slope is zero, it has
one root. It inherits from
Polynomial and provides specialized
implementation for most methods.
A line can be defined in many ways. The Line constructor is overloaded to reflect this.
A Line curve has two parameters: the Y-value where it crosses the Y-axis, and the slope of the line.
The ValueAt(Double) method returns the value of the curve at a specific point. SlopeAt(Double) returns the constant slope of the Line. Integral(Double, Double) evaluates the definite integral over a specified interval.
A Line curve is returned by the GetDerivative() method of the Quadratic class.