|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.lmu.ifi.dbs.elki.data.AbstractNumberVector<DoubleVector,Double> de.lmu.ifi.dbs.elki.data.DoubleVector de.lmu.ifi.dbs.elki.data.ParameterizationFunction
public class ParameterizationFunction
A parameterization function describes all lines in a d-dimensional feature space intersecting in one point p. A single line in d-dimensional space is uniquely determined by a translation vector p and (d-1) angles alpha_i belonging to the normal vector n.
Nested Class Summary | |
---|---|
static class |
ParameterizationFunction.ExtremumType
Available types for the global extremum. |
Field Summary | |
---|---|
private double[] |
alphaExtremum
Holds the alpha values of the global extremum. |
static double |
DELTA
A small number to handle numbers near 0 as 0. |
private ParameterizationFunction.ExtremumType |
extremumType
Holds the type of the global extremum. |
Fields inherited from class de.lmu.ifi.dbs.elki.data.AbstractNumberVector |
---|
ATTRIBUTE_SEPARATOR |
Constructor Summary | |
---|---|
ParameterizationFunction(double[] values)
Provides a new parameterization function describing all lines in a d-dimensional feature space intersecting in one point p. |
|
ParameterizationFunction(Double[] values)
Provides a new parameterization function describing all lines in a d-dimensional feature space intersecting in one point p. |
|
ParameterizationFunction(List<Double> values)
Provides a new parameterization function describing all lines in a d-dimensional feature space intersecting in one point p. |
|
ParameterizationFunction(Vector columnMatrix)
Provides a new parameterization function describing all lines in a d-dimensional feature space intersecting in one point p. |
Method Summary | |
---|---|
private double |
determineAlphaMax(int n,
double[] alpha_max,
HyperBoundingBox interval)
Determines the n-th alpha value where this function has a maximum in the specified interval. |
private double |
determineAlphaMin(int n,
double[] alpha_min,
HyperBoundingBox interval)
Determines the n-th alpha value where this function has a minimum in the specified interval. |
HyperBoundingBox |
determineAlphaMinMax(HyperBoundingBox interval)
Determines the alpha values where this function has a minumum and maximum value in the given interval. |
private void |
determineGlobalExtremum()
Determines the global extremum of this parameterization function. |
private void |
determineGlobalExtremumType()
Determines the type of the global extremum. |
private double |
extremum_alpha_n(int n,
double[] alpha)
Determines the value for alpha_n where this function has a (local) extremum. |
private ParameterizationFunction.ExtremumType |
extremumType(int n,
double[] alpha_extreme,
HyperBoundingBox interval)
Returns the type of the extremum at the specified alpha values. |
double |
function(double[] alpha)
Computes the function value at alpha . |
double[] |
getGlobalAlphaExtremum()
Returns the alpha values of the extremum point in interval [(0,...,0), (Pi,... |
double |
getGlobalExtremum()
Returns the global extremum of this function in interval [0,... |
ParameterizationFunction.ExtremumType |
getGlobalExtremumType()
Returns the type of the global extremum in interval [0,... |
DoubleVector |
newInstance(double[] values)
Returns a new NumberVector of N for the given values. |
DoubleVector |
newInstance(Double[] values)
Returns a new FeatureVector of V for the given values. |
DoubleVector |
newInstance(List<Double> values)
Returns a new FeatureVector of V for the given values. |
DoubleVector |
newInstance(Vector values)
Returns a new NumberVector of N for the given values. |
private double |
sinusProduct(int start,
int end,
double[] alpha)
Computes the product of all sinus values of the specified angles from start to end index. |
String |
toString()
Returns a string representation of the object. |
String |
toString(int offset)
Returns a string representation of the object with the specified offset. |
void |
writeToText(TextWriterStream out,
String label)
Write self to the given TextWriterStream |
Methods inherited from class de.lmu.ifi.dbs.elki.data.DoubleVector |
---|
doubleValue, fromByteBuffer, getByteSize, getColumnVector, getDimensionality, getRowVector, getValue, getValues, longValue, minus, multiplicate, negativeVector, nullVector, plus, scalarProduct, toByteBuffer |
Methods inherited from class de.lmu.ifi.dbs.elki.data.AbstractNumberVector |
---|
byteValue, equals, floatValue, getMax, getMin, hashCode, intValue, shortValue |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final double DELTA
private double[] alphaExtremum
private ParameterizationFunction.ExtremumType extremumType
Constructor Detail |
---|
public ParameterizationFunction(double[] values)
values
- the values of the point ppublic ParameterizationFunction(Double[] values)
values
- the values of the point ppublic ParameterizationFunction(List<Double> values)
values
- the values of the point ppublic ParameterizationFunction(Vector columnMatrix)
columnMatrix
- the values of the point pMethod Detail |
---|
public double function(double[] alpha)
alpha
.
alpha
- the values of the d-1 angles
public HyperBoundingBox determineAlphaMinMax(HyperBoundingBox interval)
interval
- the hyper bounding box defining the interval
private ParameterizationFunction.ExtremumType extremumType(int n, double[] alpha_extreme, HyperBoundingBox interval)
n
- the index until the alpha values are computedalpha_extreme
- the already computed alpha valuesinterval
- the hyper bounding box defining the interval in which the
extremum occurs
private double determineAlphaMin(int n, double[] alpha_min, HyperBoundingBox interval)
n
- the index of the alpha value to be determinedalpha_min
- the already computed alpha valuesinterval
- the hyper bounding box defining the interval
private double determineAlphaMax(int n, double[] alpha_max, HyperBoundingBox interval)
n
- the index of the alpha value to be determinedalpha_max
- the already computed alpha valuesinterval
- the hyper bounding box defining the interval
public double[] getGlobalAlphaExtremum()
public double getGlobalExtremum()
public ParameterizationFunction.ExtremumType getGlobalExtremumType()
public String toString()
toString
in interface FeatureVector<DoubleVector,Double>
toString
in class DoubleVector
public String toString(int offset)
offset
- the offset of the string representation
private double sinusProduct(int start, int end, double[] alpha)
start
- the index to startend
- the index to endalpha
- the array of angles
private void determineGlobalExtremum()
private void determineGlobalExtremumType()
private double extremum_alpha_n(int n, double[] alpha)
n
- the index of the anglealpha
- the already determined alpha_values for the extremum
public void writeToText(TextWriterStream out, String label)
TextWriteable
TextWriterStream
writeToText
in interface TextWriteable
out
- Output writerlabel
- Labelpublic DoubleVector newInstance(double[] values)
NumberVector
newInstance
in interface NumberVector<DoubleVector,Double>
newInstance
in class DoubleVector
values
- the values of the NumberVector
public DoubleVector newInstance(Vector values)
NumberVector
newInstance
in interface NumberVector<DoubleVector,Double>
newInstance
in class DoubleVector
values
- the values of the NumberVector
public DoubleVector newInstance(Double[] values)
FeatureVector
newInstance
in interface FeatureVector<DoubleVector,Double>
newInstance
in class DoubleVector
values
- the values of the featureVector
public DoubleVector newInstance(List<Double> values)
FeatureVector
newInstance
in interface FeatureVector<DoubleVector,Double>
newInstance
in class DoubleVector
values
- the values of the featureVector
|
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |