[IoId("00000000-c0a1-4c02-9e71-8b1d3f5a6e20")] public sealed class ConicFunction : FunctionWithCaching
conic section curve represented by a 3-point degree=2 nurbs curve with a weighted centre point. The corners can be filleted.

Constructors

ConicFunction

#
public ConicFunction()
Create a default conic ease curve from (0,0) to (1,1).

ConicFunction

#
public ConicFunction(IReader reader)
reader (IReader)

ConicFunction

#
public ConicFunction(Point2d left, Point2d right, double u, double v, double r)
Create a new conic function.
left (Point2d)Left primary grip. Left of this the function is horizontal at this level.
right (Point2d)Right primary grip. Right of this the function is horizontal at this level.
u (double)Normalised interior x-coordinate (0 = left grip, 1 = right grip).
v (double)Normalised interior y-coordinate (0 = left level, 1 = right level).
r (double)Fillet radius as a length in function space (0 = sharp corners).

Properties

Corner0

#
public Point2d Corner0 { get; }
Gets the left primary grip. The function is horizontal at this level for all x ≤ Left.X.

Corner1

#
public Point2d Corner1 { get; }
Gets the right primary grip. The function is horizontal at this level for all x ≥ Right.X.

Derivative

public sealed override Function Derivative { get; }
Gets a function which is the derivative of this function. The returned function may be either analytic or approximate.
inherited fromFunctionWithCaching

FilletRadius

#
public double FilletRadius { get; }
Gets the requested fillet radius, a length in function space.

Integral

public sealed override Function Integral { get; }
Gets a function which is the indefinite integral of this function. The returned function may be analytic or approximate. Note that numeric approximation of indefinite integrals is a slow and not particularly high quality process.
inherited fromFunctionWithCaching

Interior

#
public Point2d Interior { get; }
Gets the absolute location of the interior control point the curve passes through.

InteriorU

#
public double InteriorU { get; }
Gets the normalised interior x-coordinate (0 = left grip, 1 = right grip).

InteriorV

#
public double InteriorV { get; }
Gets the normalised interior y-coordinate (0 = left level, 1 = right level).

IsBelow

#
public bool IsBelow { get; }
Gets whether the vertical-tangent corner is the right grip (as opposed to the left grip).

Nomen

public sealed override Nomen Nomen { get; }
Gets a description of this function.
inherited fromFunctionWithCaching
Function.Nomen

Notation

public override string Notation { get; }
Gets the notation for this function. Notation is aimed at humans and does not need to return a parseable string.
inherited fromFunctionWithCaching

Ui

#
public override FunctionUi Ui { get; }
Function.Ui

Methods

Asymptotes

public virtual Line[] Asymptotes()
Returns an array of *all* the non-vertical asymptotes for this function. This property may return both null and empty arrays, implying no asymptotes. Due to the nature of non-vertical asymptotes, there can only be a finite amount of them.
inherited fromFunction

AutoCoDomain

protected void AutoCoDomain(double x0, double x1, out double y0, out double y1, int samples = 100)
Compute the automatic codomain for a given domain.
inherited fromFunction
x0 (double)Domain start.
x1 (double)Domain end.
y0 (out double)Lowest value in codomain.
y1 (out double)Highest value in codomain.
samples (int = 100)Samples.

DomainEstimate

#
public override void DomainEstimate(out double x0, out double x1, out double y0, out double y1)
x0 (out double)
x1 (out double)
y0 (out double)
y1 (out double)

EmitDerivative

protected virtual Function EmitDerivative()
Override this method to provide an analytic derivative.
inherited fromFunctionWithCaching

EmitIntegral

protected virtual Function EmitIntegral()
Override this method to provide an analytic indefinite integral.
inherited fromFunctionWithCaching

Holes

public virtual Interval[] Holes(double x0, double x1)
Returns a collection of domains for which this function is not defined. This method may return null or an empty array, implying no undefined domains. This method may also return domains outside of the specified interval.
inherited fromFunction
x0 (double)Lower limit of query domain.
x1 (double)Upper limit of query domain.

Integrate

public virtual double Integrate(double x0, double x1)
Evaluate the definite integral between two parameters. Unless a function specifically implements an analytic integral, this value will be approximate. Note to implementer: if you provide an analytic integral via the Function.Integral property, that function will be used to compute an analytic result. There is typically no reason to override this method.
inherited fromFunction
x0 (double)Integral start.
x1 (double)Integral end.
Definite integral from x0 to x1.

MaxFillet

#
public static double MaxFillet(Point2d p0, Point2d p1, double u, double v)
The largest fillet radius (a function-space length) that keeps the corner fillet valid, i.e. its total x-footprint stays within the span width. Used to clamp the fillet grip.
p0 (Point2d)
p1 (Point2d)
u (double)
v (double)

Poles

public virtual Pole[] Poles(double x0, double x1)
Returns an array of all the poles (i.e. vertical asymptotes) within a domain. This method may return both null and empty arrays, implying no poles. Furthermore this method may choose to return poles which fall outside of the given domain.
inherited fromFunction
x0 (double)Lower limit of query domain.
x1 (double)Upper limit of query domain.

Store

#
public override void Store(IWriter writer)
writer (IWriter)

Y

#
public override double Y(double x)
x (double)
Function.Y

YYYY

public double[] YYYY(double[] x)
Evaluate a large amount of values. Functions may choose to use multiple threads to perform this calculation. This method should not throw, instead every failed evaluation will be represented by a NaN value.
inherited fromFunction
x (double[])Value to evaluate.
Evaluation results. Array will contain double.NaN entries for failed evaluations.