|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjunit.framework.Assert
junit.framework.TestCase
org.apache.commons.math.analysis.SplineInterpolatorTest
public class SplineInterpolatorTest
Test the SplineInterpolator.
Field Summary | |
---|---|
protected double |
coefficientTolerance
error tolerance for interpolating polynomial coefficients |
protected double |
interpolationTolerance
error tolerance for interpolated values -- high value is from sin test |
protected double |
knotTolerance
error tolerance for spline interpolator value at knot points |
Constructor Summary | |
---|---|
SplineInterpolatorTest(java.lang.String name)
|
Method Summary | |
---|---|
static junit.framework.Test |
suite()
|
void |
testIllegalArguments()
|
void |
testInterpolateLinear()
|
void |
testInterpolateLinearDegenerateThreeSegment()
|
void |
testInterpolateLinearDegenerateTwoSegment()
|
void |
testInterpolateSin()
|
protected void |
verifyConsistency(org.apache.commons.math.analysis.PolynomialSplineFunction f,
double[] x)
Verifies that interpolating polynomials satisfy consistency requirement: adjacent polynomials must agree through two derivatives at knot points |
protected void |
verifyInterpolation(org.apache.commons.math.analysis.UnivariateRealFunction f,
double[] x,
double[] y)
verifies that f(x[i]) = y[i] for i = 0..n-1 where n is common length. |
Methods inherited from class junit.framework.TestCase |
---|
countTestCases, createResult, getName, run, run, runBare, runTest, setName, setUp, tearDown, toString |
Methods inherited from class junit.framework.Assert |
---|
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected double knotTolerance
protected double coefficientTolerance
protected double interpolationTolerance
Constructor Detail |
---|
public SplineInterpolatorTest(java.lang.String name)
Method Detail |
---|
public static junit.framework.Test suite()
public void testInterpolateLinearDegenerateTwoSegment() throws java.lang.Exception
java.lang.Exception
public void testInterpolateLinearDegenerateThreeSegment() throws java.lang.Exception
java.lang.Exception
public void testInterpolateLinear() throws java.lang.Exception
java.lang.Exception
public void testInterpolateSin() throws java.lang.Exception
java.lang.Exception
public void testIllegalArguments() throws org.apache.commons.math.MathException
org.apache.commons.math.MathException
protected void verifyInterpolation(org.apache.commons.math.analysis.UnivariateRealFunction f, double[] x, double[] y) throws java.lang.Exception
java.lang.Exception
protected void verifyConsistency(org.apache.commons.math.analysis.PolynomialSplineFunction f, double[] x) throws java.lang.Exception
java.lang.Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |