|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcsheets.ext.assertion.MultiInterval
public class MultiInterval
A class representing (possibly) multiple intervals. This can be used to specify any combination of values to be included in an interval. The MultiInterval is built up by specifying normal intervals to be included or excluded from the MultiInterval.
| Constructor Summary | |
|---|---|
MultiInterval()
Default constructor. |
|
| Method Summary | |
|---|---|
static MultiInterval |
abs(MultiInterval mInterval)
Calculates the absolute value MultiInterval of a MultiInterval |
static MultiInterval |
add(MultiInterval term1,
MultiInterval term2)
Calculates the sum of two MultiIntervals |
static MultiInterval |
avg(List<MultiInterval> terms)
Calculates the average of a List of MultiIntervals |
MultiInterval |
clone()
Makes a copy of this MultiInterval intance |
boolean |
contains(double value)
Check if a value is contained in this MultiInterval. |
static MultiInterval |
cos(MultiInterval mInterval)
Calculates the cosine MultiInterval of a MultiInterval |
static MultiInterval |
div(MultiInterval numerator,
MultiInterval denominator)
Calculates the quotient of two MultiIntervals |
boolean |
equals(Object o)
Compares the specified MultiInterval with this MultiInterval for equality. |
void |
exclude(Interval interval)
Exclude a specific interval from this MultiInterval. |
static MultiInterval |
exp(MultiInterval exponent)
Calculates Eulers number e raised to a MultiInterval |
static MultiInterval |
fact(MultiInterval mInterval)
Calculates the factorial of a MultiInterval |
void |
include(Interval interval)
Add an interval to be included in this MultiInterval. |
Iterator<Interval> |
iterator()
Returns an iterator over the intervals in this MultiInterval in proper sequence. |
static MultiInterval |
ln(MultiInterval mInterval)
Calculates the natural logarithm of a MultiInterval |
static MultiInterval |
log10(MultiInterval mInterval)
Calculates the base 10 logarithm of a MultiInterval |
static MultiInterval |
mul(MultiInterval factor1,
MultiInterval factor2)
Calculates the product of two MultiIntervals |
static MultiInterval |
negate(MultiInterval term)
Calculates a negation av a MultiInterval |
static MultiInterval |
pow(MultiInterval base,
MultiInterval exponent)
Calculates the first MultiInterval raised to the power of the second MultiInterval |
static MultiInterval |
rand()
Returns a MultiInterval holding all possible values you get from the Math.random() method |
static MultiInterval |
sin(MultiInterval mInterval)
Calculates the sine MultiInterval of a MultiInterval |
static MultiInterval |
sqrt(MultiInterval mInterval)
Calculates the square root of a MultiInterval |
static MultiInterval |
sub(MultiInterval term1,
MultiInterval term2)
Calculates the difference of two MultiIntervals |
static MultiInterval |
sum(List<MultiInterval> terms)
Calculates the sum of a List of MultiIntervals |
static MultiInterval |
tan(MultiInterval mInterval)
Calculates the tangent MultiInterval of a MultiInterval |
static MultiInterval |
toInt(MultiInterval mInterval)
Calculates the MultiInterval you get if you convert all values from double to int |
String |
toString()
Returns a string representation of this MultiInterval. |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public MultiInterval()
exclude(),
all values except the ones excluded will be included in this interval.
| Method Detail |
|---|
public void include(Interval interval)
interval - An interval specifying values to be included in this MultiInterval.public void exclude(Interval interval)
interval - an interval specifying which values to exclude from this MultiInterval.public boolean contains(double value)
NOTE: Infinity and NaN is never reported to be included in a MultiInterval.
value - The value to check for.
true if the value has been specified to be included in this
MultiInterval, false otherwise.public static MultiInterval negate(MultiInterval term)
MultiInterval
term - is the MultiInterval to be negated
MultiInterval
public static MultiInterval add(MultiInterval term1,
MultiInterval term2)
MultiIntervals
term1 - is the first termterm2 - is the second term
MultiIntervals
public static MultiInterval sub(MultiInterval term1,
MultiInterval term2)
MultiIntervals
term1 - is the first termterm2 - is the second term
MultiIntervals
public static MultiInterval mul(MultiInterval factor1,
MultiInterval factor2)
MultiIntervals
factor1 - is the first factorfactor2 - is the second factor
MultiIntervals
public static MultiInterval div(MultiInterval numerator,
MultiInterval denominator)
throws MathException
MultiIntervals
numerator - is the numeratordenominator - is the denominator
MultiIntervals
MathException
public static MultiInterval pow(MultiInterval base,
MultiInterval exponent)
throws MathException
MultiInterval raised to the power of the second MultiInterval
base - is the first MultiIntervalexponent - is the second MultiInterval
MultiInterval raised to the power of the second MultiInterval
MathException - if the first MultiInterval contains values below zero and the second MultiInterval is not build of singel integer value Intervalspublic static MultiInterval cos(MultiInterval mInterval)
MultiInterval of a MultiInterval
mInterval - is the MultiInterval
MultiInterval of the MultiIntervalpublic static MultiInterval sin(MultiInterval mInterval)
MultiInterval of a MultiInterval
mInterval - is the MultiInterval
MultiInterval of the MultiIntervalpublic static MultiInterval tan(MultiInterval mInterval)
MultiInterval of a MultiInterval
mInterval - is the MultiInterval
MultiInterval of the MultiInterval
public static MultiInterval ln(MultiInterval mInterval)
throws MathException
MultiInterval
mInterval - is the MultiInterval
MultiInterval
MathException - if the MultiInterval contains values below zero
public static MultiInterval log10(MultiInterval mInterval)
throws MathException
MultiInterval
mInterval - is the MultiInterval
MultiInterval
MathException - if the MultiInterval contains values below zeropublic static MultiInterval exp(MultiInterval exponent)
MultiInterval
exponent - is the MultiInterval
MultiInterval
public static MultiInterval sqrt(MultiInterval mInterval)
throws MathException
MultiInterval
mInterval - is the MultiInterval
MultiInterval
MathException - if the MultiInterval contains values below zeropublic static MultiInterval toInt(MultiInterval mInterval)
MultiInterval you get if you convert all values from double to int
mInterval - is the MultiInterval
MultiInterval you get if you convert the values from double to intpublic static MultiInterval abs(MultiInterval mInterval)
MultiInterval of a MultiInterval
mInterval - is the MultiInterval
MultiInterval of the MultiIntervalpublic static MultiInterval rand()
MultiInterval holding all possible values you get from the Math.random() method
MultiInterval holding all possible values you get from the Math.random() mathod
public static MultiInterval fact(MultiInterval mInterval)
throws MathException
MultiInterval
mInterval - is the MultiInterval
MultiInterval
MathException - if the MultiInterval contains values below zeropublic static MultiInterval sum(List<MultiInterval> terms)
List of MultiIntervals
terms - is the terms to be summarized
MultiIntervalspublic static MultiInterval avg(List<MultiInterval> terms)
List of MultiIntervals
terms - is the terms
MultiIntervalspublic Iterator<Interval> iterator()
iterator in interface Iterable<Interval>public boolean equals(Object o)
equals in class Objecttrue if the two intervals represent the same ranges of values,
false otherwise.public MultiInterval clone()
MultiInterval intance
clone in class Objectpublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||