Class MonicPolynomial

java.lang.Object
org.drip.function.definition.R1ToR1
org.drip.function.r1tor1.MonicPolynomial

public class MonicPolynomial
extends R1ToR1
MonicPolynomial implements the Multi-root R1 to R1 Monic Polynomial.

Author:
Lakshmi Krishnamurthy
  • Constructor Details

    • MonicPolynomial

      public MonicPolynomial​(double[] rootArray) throws java.lang.Exception
      MonicPolynomial constructor
      Parameters:
      rootArray - The Array of Roots
      Throws:
      java.lang.Exception - Thrown if the Inputs are invalid
  • Method Details

    • rootArray

      public double[] rootArray()
      Retrieve the Array of Roots
      Returns:
      The Array of Roots
    • evaluate

      public double evaluate​(double x) throws java.lang.Exception
      Description copied from class: R1ToR1
      Evaluate for the given variate
      Specified by:
      evaluate in class R1ToR1
      Parameters:
      x - Variate
      Returns:
      Returns the calculated value
      Throws:
      java.lang.Exception - Thrown if evaluation cannot be done
    • logGammaProduct

      public double logGammaProduct​(int a, int b, R1ToR1 logGammaEstimator) throws java.lang.Exception
      Compute the Log Product over [a, a + 1, ..., b] of the Monic Polynomial
      Parameters:
      a - a
      b - b
      logGammaEstimator - Log Gamma Estimator
      Returns:
      The Log Product over [a, a + 1, ..., b] of the Monic Polynomial
      Throws:
      java.lang.Exception - Thrown if the Inputs are Invalid