|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sourceforge.jabm.util.MathUtil
public class MathUtil
Miscalleneous mathematical functions.
Field Summary | |
---|---|
static double |
DEFAULT_ERROR
|
Constructor Summary | |
---|---|
MathUtil()
|
Method Summary | |
---|---|
static boolean |
approxEqual(double x,
double y)
|
static boolean |
approxEqual(double x,
double y,
double error)
Returns true if the difference between x and y is less than error. |
static double |
diffSq(double x,
double y)
Calculate the squared difference of x and y. |
static long |
factorial(int n)
Deprecated. |
static double |
squared(double x)
Calculate the square of x. |
static double |
sum(double[] series)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final double DEFAULT_ERROR
Constructor Detail |
---|
public MathUtil()
Method Detail |
---|
public static double squared(double x)
public static double diffSq(double x, double y)
public static boolean approxEqual(double x, double y, double error)
public static boolean approxEqual(double x, double y)
public static double sum(double[] series)
public static long factorial(int n)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |