|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
ObjectFormattableObject
AbstractMathTransform
AbstractMathTransform1D
LogarithmicTransform1D
@Immutable public class LogarithmicTransform1D
A one dimensional, logarithmic transform. This transform is the inverse of
ExponentialTransform1D. Input values x are converted into
output values y using the following equation:
See any of the following providers for a list of programmatic parameters:
y = offset + logbase(x) = offset + ln(x)/ln(base)
ExponentialTransform1D,
LinearTransform1D,
Serialized Form
| referencing/geotk-referencing (download) | View source code for this class |
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class AbstractMathTransform |
|---|
AbstractMathTransform.Inverse |
| Field Summary | |
|---|---|
double |
base
The base of the logarithm. |
double |
offset
The offset to add to the logarithm. |
| Fields inherited from class FormattableObject |
|---|
EPSG, GEOTIFF, INTERNAL, OGC, SINGLE_LINE |
| Constructor Summary | |
|---|---|
protected |
LogarithmicTransform1D(double base,
double offset)
Constructs a new logarithmic transform. |
| Method Summary | |
|---|---|
protected int |
computeHashCode()
Computes a hash value for this transform. |
static MathTransform1D |
create(double base)
Constructs a new logarithmic transform without offset. |
static MathTransform1D |
create(double base,
double offset)
Constructs a new logarithmic transform which include the given offset after the logarithm. |
double |
derivative(double value)
Gets the derivative of this function at a value. |
boolean |
equals(Object object,
ComparisonMode mode)
Compares the specified object with this math transform for equality. |
ParameterDescriptorGroup |
getParameterDescriptors()
Returns the parameter descriptors for this math transform. |
ParameterValueGroup |
getParameterValues()
Returns the parameter values for this math transform. |
MathTransform1D |
inverse()
Creates the inverse transform of this object. |
double |
transform(double value)
Transforms the specified value. |
protected void |
transform(double[] srcPts,
int srcOff,
double[] dstPts,
int dstOff)
Transforms a single coordinate in a list of ordinal values. |
void |
transform(double[] srcPts,
int srcOff,
double[] dstPts,
int dstOff,
int numPts)
Transforms many coordinates in a list of ordinal values. |
void |
transform(double[] srcPts,
int srcOff,
float[] dstPts,
int dstOff,
int numPts)
Transforms many coordinates in a list of ordinal values. |
void |
transform(float[] srcPts,
int srcOff,
double[] dstPts,
int dstOff,
int numPts)
Transforms many coordinates in a list of ordinal values. |
void |
transform(float[] srcPts,
int srcOff,
float[] dstPts,
int dstOff,
int numPts)
Transforms many coordinates in a list of ordinal values. |
| Methods inherited from class AbstractMathTransform1D |
|---|
derivative, getSourceDimensions, getTargetDimensions |
| Methods inherited from class AbstractMathTransform |
|---|
createTransformedShape, derivative, ensureNonNull, equals, formatWKT, getName, hashCode, isIdentity, rollLongitude, transform, transform |
| Methods inherited from class FormattableObject |
|---|
getDefaultIndentation, print, setDefaultIndentation, toString, toWKT, toWKT, toWKT |
| Methods inherited from class Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface MathTransform |
|---|
isIdentity, toWKT, transform |
| Field Detail |
|---|
public final double base
public final double offset
Note:
The offset could be handled by a concatenation with LinearTransform1D
instead than an explicit field in this class. However the offset +
logbase(x) formula is extensively used as a transfer
function in grid coverages. Consequently we keep this explicit field for
performance reasons.
| Constructor Detail |
|---|
protected LogarithmicTransform1D(double base,
double offset)
base - The base of the logarithm (typically 10).offset - The offset to add to the logarithm.| Method Detail |
|---|
public static MathTransform1D create(double base)
base - The base of the logarithm (typically 10).
public static MathTransform1D create(double base,
double offset)
base - The base of the logarithm (typically 10).offset - The offset to add to the logarithm.
public ParameterDescriptorGroup getParameterDescriptors()
getParameterDescriptors in interface ParameterizedgetParameterDescriptors in class AbstractMathTransformnull.OperationMethod.getParameters()public ParameterValueGroup getParameterValues()
getParameterValues in interface ParameterizedgetParameterValues in class AbstractMathTransformSingleOperation.getParameterValues()public MathTransform1D inverse()
inverse in interface MathTransforminverse in interface MathTransform1Dinverse in class AbstractMathTransform1Dpublic double derivative(double value)
derivative in interface MathTransform1Dpublic double transform(double value)
transform in interface MathTransform1D
protected void transform(double[] srcPts,
int srcOff,
double[] dstPts,
int dstOff)
transform in class AbstractMathTransform1DsrcPts - The array containing the source point coordinates.srcOff - The offset to the point to be transformed in the source array.dstPts - the array into which the transformed point coordinate are returned.
May be the same than srcPts.dstOff - The offset to the location of the transformed point that is
stored in the destination array.
public void transform(double[] srcPts,
int srcOff,
double[] dstPts,
int dstOff,
int numPts)
transform in interface MathTransformtransform in class AbstractMathTransformsrcPts - The array containing the source point coordinates.srcOff - The offset to the first point to be transformed in the source array.dstPts - The array into which the transformed point coordinates are returned.
May be the same than srcPts.dstOff - The offset to the location of the first transformed point that is
stored in the destination array.numPts - The number of point objects to be transformed.
public void transform(float[] srcPts,
int srcOff,
float[] dstPts,
int dstOff,
int numPts)
transform in interface MathTransformtransform in class AbstractMathTransformsrcPts - The array containing the source point coordinates.srcOff - The offset to the first point to be transformed in the source array.dstPts - The array into which the transformed point coordinates are returned.
May be the same than srcPts.dstOff - The offset to the location of the first transformed point that is
stored in the destination array.numPts - The number of point objects to be transformed.
public void transform(double[] srcPts,
int srcOff,
float[] dstPts,
int dstOff,
int numPts)
transform in interface MathTransformtransform in class AbstractMathTransformsrcPts - The array containing the source point coordinates.srcOff - The offset to the first point to be transformed in the source array.dstPts - The array into which the transformed point coordinates are returned.dstOff - The offset to the location of the first transformed point that is
stored in the destination array.numPts - The number of point objects to be transformed.
public void transform(float[] srcPts,
int srcOff,
double[] dstPts,
int dstOff,
int numPts)
transform in interface MathTransformtransform in class AbstractMathTransformsrcPts - The array containing the source point coordinates.srcOff - The offset to the first point to be transformed in the source array.dstPts - The array into which the transformed point coordinates are returned.dstOff - The offset to the location of the first transformed point that is
stored in the destination array.numPts - The number of point objects to be transformed.protected int computeHashCode()
AbstractMathTransform.hashCode()
when first needed.
computeHashCode in class AbstractMathTransform
public boolean equals(Object object,
ComparisonMode mode)
equals in interface LenientComparableequals in class AbstractMathTransformobject - The object to compare with this transform.mode - The strictness level of the comparison. Default to STRICT.
true if the given object is a transform of the same class and if, given
identical source position, the transformed position would be the equals.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||