Documentation of 'jsat.math.ContinuedFraction' Java class
ContinuedFraction
jsat.math

Class ContinuedFraction



  • public abstract class ContinuedFraction
    extends java.lang.Object
    This class provides a means to represent and evaluate continued fractions in a multitude of ways.
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method and Description
      double backwardNaive(int n, double... args)
      Approximates the continued fraction using a naive approximation
      abstract double getA(int pos, double... args)
      The a term of a continued fraction is the value that occurs as one of the numerators, an its depth starts at 1.
      abstract double getB(int pos, double... args)
      The b term of a continued fraction is the value that is added to the continuing fraction, its depth starts at 0.
      double lentz(double... args)
      Uses Thompson and Barnett's modified Lentz's algorithm create an approximation that should be accurate to full precision.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ContinuedFraction

        public ContinuedFraction()
    • Method Detail

      • getA

        public abstract double getA(int pos,
                                    double... args)
        The a term of a continued fraction is the value that occurs as one of the numerators, an its depth starts at 1.
        Parameters:
        pos - the depth of the continued fraction to evaluate at
        args - the values for the variables of the continued fraction
        Returns:
        the value that would be computed for the a coefficient at the specified depth of the fraction
      • getB

        public abstract double getB(int pos,
                                    double... args)
        The b term of a continued fraction is the value that is added to the continuing fraction, its depth starts at 0.
        Parameters:
        pos - the depth of the continued fraction to evaluate at
        args - the values for the variables of the continued fraction
        Returns:
        the value that would be computed for the b coefficient at the specified depth of the fraction
      • backwardNaive

        public double backwardNaive(int n,
                                    double... args)
        Approximates the continued fraction using a naive approximation
        Parameters:
        n - the number of iterations to perform
        args - the values to input for the variables of the continued fraction
        Returns:
        an approximation of the value of the continued fraciton
      • lentz

        public double lentz(double... args)
        Uses Thompson and Barnett's modified Lentz's algorithm create an approximation that should be accurate to full precision.
        Parameters:
        args - the numeric inputs to the continued fraction
        Returns:
        the approximate value of the continued fraction

DataMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.