rvl.util
Class NumAnal

java.lang.Object
  |
  +--rvl.util.NumAnal

public class NumAnal
extends java.lang.Object


Constructor Summary
NumAnal()
           
 
Method Summary
static double fHalfLine(double x)
          Utility fcn to do substitution x = (y - AA) / {BB + (y - AA)} to transform y in [AA,infty) or (-infty,AA] to x in [0,1).
static int getCallCount()
           
static double integral(java.lang.Class cls, java.lang.String fcn, double a, double b, double tol)
           
static double integral(java.lang.Class cls, java.lang.String fcn, double a, double b, double tol, boolean open)
           
static double integral(java.lang.Class cls, java.lang.String fcn, double a, double b, double tol, boolean open, double fa, double fb)
           
static double integral(java.lang.Object obj, java.lang.String fcn, double a, double b, double tol)
           
static double integral(java.lang.Object obj, java.lang.String fcn, double a, double b, double tol, boolean open)
           
static double integral(java.lang.Object obj, java.lang.String fcn, double a, double b, double tol, boolean open, double fa, double fb)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NumAnal

public NumAnal()
Method Detail

fHalfLine

public static double fHalfLine(double x)
Utility fcn to do substitution x = (y - AA) / {BB + (y - AA)} to transform y in [AA,infty) or (-infty,AA] to x in [0,1). This will be set up to be called by f().

integral

public static double integral(java.lang.Class cls,
                              java.lang.String fcn,
                              double a,
                              double b,
                              double tol)
Returns:
integral of the static function named fcn in Class cls from a to b. Uses adaptive Simpson's rule

integral

public static double integral(java.lang.Class cls,
                              java.lang.String fcn,
                              double a,
                              double b,
                              double tol,
                              boolean open)
Returns:
integral of the function named fcn in Object obj from a to b. Uses adaptive 3-point rule, open or closed depending on open

integral

public static double integral(java.lang.Object obj,
                              java.lang.String fcn,
                              double a,
                              double b,
                              double tol)
Returns:
integral of the function named fcn in Object obj from a to b. Uses adaptive Simpson's rule

integral

public static double integral(java.lang.Object obj,
                              java.lang.String fcn,
                              double a,
                              double b,
                              double tol,
                              boolean open)
Returns:
integral of the function named fcn in Object obj from a to b. Uses adaptive 3-point rule, open or closed depending on open

integral

public static double integral(java.lang.Object obj,
                              java.lang.String fcn,
                              double a,
                              double b,
                              double tol,
                              boolean open,
                              double fa,
                              double fb)
Returns:
integral of the function named fcn in Object obj from a to b. Uses adaptive open or closed 3-point rule depending on value of open. If open == false, this routine uses provided values of fa = f(a), fb = f(b) if they are proper. They are computed if equal to Double.NaN. The values of fa and fb are ignored when open == true.

One or both of the limits a and b may be infinite (Double.POSITIVE_INFINITY or Double.NEGATIVE_INFINITY); in such cases, the transformation y = (x - AA) / (BB + (x - AA) is applied to make it an integral on (0,1). When only one of the limits is infinite, AA is set to the finite endpoint and BB is made negative or positive as appropriate. When both limits are infinite, the current value of AA is used to break the integral into two regions (-infty,AA) and (AA,infty). Programmers may want to set AA or BB to suitable values to improve performance. When infinite limits are used, open is forced to be true.


integral

public static double integral(java.lang.Class cls,
                              java.lang.String fcn,
                              double a,
                              double b,
                              double tol,
                              boolean open,
                              double fa,
                              double fb)
Returns:
integral of the static function named fcn in Class cls from a to b. Uses adaptive open or closed 3-point rule depending on value of open. If open==false, this routine uses provided values of fa = f(a), fb = f(b) if they are proper. They are computed if equal to Double.NaN. The values of fa and fb are ignored when open==true.

getCallCount

public static int getCallCount()