Class MicrosphereProjectionInterpolator

java.lang.Object
org.apache.commons.math4.analysis.interpolation.MicrosphereProjectionInterpolator
All Implemented Interfaces:
MultivariateInterpolator

public class MicrosphereProjectionInterpolator
extends java.lang.Object
implements MultivariateInterpolator
Interpolator that implements the algorithm described in William Dudziak's MS thesis.
Since:
3.6
  • Constructor Summary

    Constructors 
    Constructor Description
    MicrosphereProjectionInterpolator​(int dimension, int elements, double maxDarkFraction, double darkThreshold, double background, double exponent, boolean sharedSphere, double noInterpolationTolerance)
    Create a microsphere interpolator.
    MicrosphereProjectionInterpolator​(InterpolatingMicrosphere microsphere, double exponent, boolean sharedSphere, double noInterpolationTolerance)
    Create a microsphere interpolator.
  • Method Summary

    Modifier and Type Method Description
    MultivariateFunction interpolate​(double[][] xval, double[] yval)
    Computes an interpolating function for the data set.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • MicrosphereProjectionInterpolator

      public MicrosphereProjectionInterpolator​(int dimension, int elements, double maxDarkFraction, double darkThreshold, double background, double exponent, boolean sharedSphere, double noInterpolationTolerance)
      Create a microsphere interpolator.
      Parameters:
      dimension - Space dimension.
      elements - Number of surface elements of the microsphere.
      exponent - Exponent used in the power law that computes the
      maxDarkFraction - Maximum fraction of the facets that can be dark. If the fraction of "non-illuminated" facets is larger, no estimation of the value will be performed, and the background value will be returned instead.
      darkThreshold - Value of the illumination below which a facet is considered dark.
      background - Value returned when the maxDarkFraction threshold is exceeded.
      sharedSphere - Whether the sphere can be shared among the interpolating function instances. If true, the instances will share the same data, and thus will not be thread-safe.
      noInterpolationTolerance - When the distance between an interpolated point and one of the sample points is less than this value, no interpolation will be performed (the value of the sample will be returned).
      Throws:
      NotStrictlyPositiveException - if dimension <= 0 or elements <= 0.
      NotPositiveException - if exponent < 0.
      NotPositiveException - if darkThreshold < 0.
      OutOfRangeException - if maxDarkFraction does not belong to the interval [0, 1].
    • MicrosphereProjectionInterpolator

      public MicrosphereProjectionInterpolator​(InterpolatingMicrosphere microsphere, double exponent, boolean sharedSphere, double noInterpolationTolerance) throws NotPositiveException
      Create a microsphere interpolator.
      Parameters:
      microsphere - Microsphere.
      exponent - Exponent used in the power law that computes the weights (distance dimming factor) of the sample data.
      sharedSphere - Whether the sphere can be shared among the interpolating function instances. If true, the instances will share the same data, and thus will not be thread-safe.
      noInterpolationTolerance - When the distance between an interpolated point and one of the sample points is less than this value, no interpolation will be performed (the value of the sample will be returned).
      Throws:
      NotPositiveException - if exponent < 0.
  • Method Details