Class PolynomialInterpolatorTest
java.lang.Object
com.irurueta.numerical.interpolation.PolynomialInterpolatorTest
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final double
private static final double
private static final double
private static final double
private static final double
private static final int
private static final double
private static final double
private static final int
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static void
assertInterpolation
(int degree, int samples, double error) private static Polynomial
buildPolynomial
(int degree, double[] roots) (package private) void
(package private) void
(package private) void
(package private) void
(package private) void
(package private) void
(package private) void
(package private) void
(package private) void
(package private) void
(package private) void
(package private) void
(package private) void
-
Field Details
-
MIN_VALUE
private static final double MIN_VALUE- See Also:
-
MAX_VALUE
private static final double MAX_VALUE- See Also:
-
SAMPLES
private static final int SAMPLES- See Also:
-
INTERPOLATIONS
private static final int INTERPOLATIONS- See Also:
-
ABSOLUTE_ERROR_1
private static final double ABSOLUTE_ERROR_1- See Also:
-
ABSOLUTE_ERROR_2
private static final double ABSOLUTE_ERROR_2- See Also:
-
ABSOLUTE_ERROR_3
private static final double ABSOLUTE_ERROR_3- See Also:
-
ABSOLUTE_ERROR_4
private static final double ABSOLUTE_ERROR_4- See Also:
-
ABSOLUTE_ERROR_5
private static final double ABSOLUTE_ERROR_5- See Also:
-
-
Constructor Details
-
PolynomialInterpolatorTest
PolynomialInterpolatorTest()
-
-
Method Details
-
interpolate_whenFirstDegreePolynomial_returnsExpectedResult
@Test void interpolate_whenFirstDegreePolynomial_returnsExpectedResult() throws InterpolationException, com.irurueta.sorting.SortingException- Throws:
InterpolationException
com.irurueta.sorting.SortingException
-
interpolate_whenFirstDegreePolynomialMinimumSamples_returnsExpectedResult
@Test void interpolate_whenFirstDegreePolynomialMinimumSamples_returnsExpectedResult() throws InterpolationException, com.irurueta.sorting.SortingException- Throws:
InterpolationException
com.irurueta.sorting.SortingException
-
interpolate_whenSecondDegreePolynomial_returnsExpectedResult
@Test void interpolate_whenSecondDegreePolynomial_returnsExpectedResult() throws InterpolationException, com.irurueta.sorting.SortingException- Throws:
InterpolationException
com.irurueta.sorting.SortingException
-
interpolate_whenSecondDegreePolynomialMinimumSamples_returnsExpectedResult
@Test void interpolate_whenSecondDegreePolynomialMinimumSamples_returnsExpectedResult() throws InterpolationException, com.irurueta.sorting.SortingException- Throws:
InterpolationException
com.irurueta.sorting.SortingException
-
interpolate_whenThirdDegreePolynomial_returnsExpectedResult
@Test void interpolate_whenThirdDegreePolynomial_returnsExpectedResult() throws InterpolationException, com.irurueta.sorting.SortingException- Throws:
InterpolationException
com.irurueta.sorting.SortingException
-
interpolate_whenThirdDegreePolynomialMinimumSamples_returnsExpectedResult
@Test void interpolate_whenThirdDegreePolynomialMinimumSamples_returnsExpectedResult() throws InterpolationException, com.irurueta.sorting.SortingException- Throws:
InterpolationException
com.irurueta.sorting.SortingException
-
interpolate_whenFourthDegreePolynomial_returnsExpectedResult
@Test void interpolate_whenFourthDegreePolynomial_returnsExpectedResult() throws InterpolationException, com.irurueta.sorting.SortingException- Throws:
InterpolationException
com.irurueta.sorting.SortingException
-
interpolate_whenFourthDegreePolynomialMinimumSamples_returnsExpectedResult
@Test void interpolate_whenFourthDegreePolynomialMinimumSamples_returnsExpectedResult() throws InterpolationException, com.irurueta.sorting.SortingException- Throws:
InterpolationException
com.irurueta.sorting.SortingException
-
interpolate_whenFifthDegreePolynomialMinimumSamples_returnsExpectedResult
@Test void interpolate_whenFifthDegreePolynomialMinimumSamples_returnsExpectedResult() throws InterpolationException, com.irurueta.sorting.SortingException- Throws:
InterpolationException
com.irurueta.sorting.SortingException
-
interpolate_whenMismatchedLength_throwsIllegalArgumentException
@Test void interpolate_whenMismatchedLength_throwsIllegalArgumentException() -
interpolate_whenNotEnoughSamples_throwsIllegalArgumentException
@Test void interpolate_whenNotEnoughSamples_throwsIllegalArgumentException() -
interpolate_whenNotEnoughSamplesToTakeIntoAccount_throwsIllegalArgumentException
@Test void interpolate_whenNotEnoughSamplesToTakeIntoAccount_throwsIllegalArgumentException() -
interpolate_whenTooManyPointsToTakeIntoAccount_throwsIllegalArgumentException
@Test void interpolate_whenTooManyPointsToTakeIntoAccount_throwsIllegalArgumentException() -
assertInterpolation
private static void assertInterpolation(int degree, int samples, double error) throws InterpolationException, com.irurueta.sorting.SortingException - Throws:
InterpolationException
com.irurueta.sorting.SortingException
-
buildPolynomial
-