All Packages Class Hierarchy This Package Previous Next Index
Class com.micronova.math.SegmentedCurve
java.lang.Object
|
+----netscape.util.Vector
|
+----com.micronova.util.SortedVector
|
+----com.micronova.math.SegmentedCurve
- public abstract class SegmentedCurve
- extends SortedVector
- implements Curve
A SegmentedCurve is a curve that consists of multiple segments defined by an ordered sequence of boundary CurvePoints (e.g., a linearly interpolated curve).
An ordered sequence of N boundary CurvePoints {(x[0], y[0]), (x[1], y[1]), ..., (x[N-1], y[N-1])} (where x[0] < x[1] < ... < x[N-1])
defines (N+1) segments as follows:
- segment 0: (-infinity, x[0])
- segment k (k = 1, 2, ..., N-1): [x[k - 1], x[k])
- segment N: [x[N-1], +infinity)
- Version:
- 1.0
- Author:
- Makoto Nagata, MicroNova
- See Also:
- CurvePoint, SortedVector
-
SegmentedCurve()
-
-
getSegmentIndex(double)
- Returns the index of the segment to which a given value x belongs.
-
getValueInSegment(double, int)
- Defines the value for a given point x in index-th segment.
-
getValueOf(double)
- The value of this Curve.
SegmentedCurve
public SegmentedCurve()
getSegmentIndex
public int getSegmentIndex(double x)
- Returns the index of the segment to which a given value x belongs. It returns -1 if there is no boundary points.
getValueInSegment
public abstract double getValueInSegment(double x,
int index)
- Defines the value for a given point x in index-th segment. This is abstract.
getValueOf
public double getValueOf(double x)
- The value of this Curve.
All Packages Class Hierarchy This Package Previous Next Index