public class ProfileDataStatistics
extends java.lang.Object
Computes statistical properties of profile data.
Define the weighted, central summation Sn(μ) as
Sn(μ) = Σk(k - μ)nfk
where {fk} is the set of discrete samples for a projection view (that is, the
discrete function representing the projection).
Then the quantities provided by this class are typically some ratio of the
Sn(μ) for a combination of parameters (n,μ). For example,
the nth central moment moment, denoted <(x - μ)n>,
is defined as
<(x - μ)n> = Sn(μ)/S0(0)
Note that the units of the moments will be in terms of samples (see below). For example,
the value returned by
the method getCenter(ProfileData.Angle)
is the index location of the center of mass.
Note further that although the indices are integer valued, the statistic values in units of samples
need not be.
NOTE:
- The quantities provided by this class are for discrete system. When considering these systems
as approximations for continuous systems (sampled data systems) then we must "unnormalized"
the results by the sampling interval h. For example, to convert
<(x - μ)n> to the continuous approximation the value
must be multiplied by hn.
- The above conversions are not provided by methods in this class. There are, however,
methods for computing the sampling length h for the various axes and actuator positions.
The rationale for not providing this service at present is the profile data sets might not
contain the axis positions, as these are version-sensitive data. Thus, such methods have the
potential for returning erroneous results.
- Higher-order moments are highly sensitive to signal noise.
- Strongly peaked distributions create numerically unstable computations. In general, for accurate
numerical results the distribution should have a standard deviation σ > 2. Standard
deviations smaller than this value imply that the sampling interval is too large.
Constructor and Description |
---|
ProfileDataStatistics(ProfileData pdoData)
Create a new
ProfileDataStatistics object and attach it to
the given profile data set. |
Modifier and Type | Method and Description |
---|---|
double |
compAveActuatorStepSize()
Compute and return the average step size between actuator positions for the
entire sample projection sample set.
|
double |
compAveAxisStepSize(ProfileData.Angle view)
Compute and return the average step size between axis sample positions for the
given projection view.
|
double |
compStdDev(ProfileData.Angle view)
Return the (normalized) standard deviation σ of the given projection.
|
double |
computeCentralMoment(int intOrder,
ProfileData.Angle view)
Compute and return the indicated central moment for the given projection data.
|
double |
computeMoment(int intOrder,
ProfileData.Angle view)
Compute and return the indicated moment for the given projection data.
|
double |
computeWeightedSum(int intOrder,
double dblCntr,
ProfileData.Angle view)
Compute and return the weighted central summation Sn(μ)
which is defined
Sn(μ) = Σk(k - μ)nfk |
double |
getActuatorOffset()
Return the initial actuator position, that is
the actuator location x0 of the first sample.
|
double |
getAxisOffset(ProfileData.Angle view)
Return the initial axis position for the given projection angle, that is
the axis location x0 of the first sample.
|
double |
getCenter(ProfileData.Angle view)
Return the (normalized) center of mass (i.e., the first moment) for the given projection.
|
double |
getMass(ProfileData.Angle view)
Return the total mass (i.e., the first integral, or zeroth moment)
of the given projection.
|
public ProfileDataStatistics(ProfileData pdoData)
ProfileDataStatistics
object and attach it to
the given profile data set.public double getMass(ProfileData.Angle view)
Return the total mass (i.e., the first integral, or zeroth moment) of the given projection.
NOTE:
- The returned value is for a discrete function and must be treated as a "normalized"
quantity when considering sampled data from a continuous system. To convert to the
continuous approximation the returned value must be multiplied
by h where h is the sampling interval.
view
- projection datapublic double getCenter(ProfileData.Angle view)
Return the (normalized) center of mass (i.e., the first moment) for the given projection.
NOTE:
- The returned value is for a discrete function and must be treated as a "normalized"
quantity when considering sampled data from a continuous system. To convert to the
continuous approximation for <x> the returned value must be multiplied
by h where h is the sampling interval.
- To convert to the center of the projection axis indicated by view,
the returned value must be multiply by h then offset by x0, the
left-hand axis end-point.
view
- projection datapublic double getActuatorOffset()
public double getAxisOffset(ProfileData.Angle view)
public double compAveActuatorStepSize()
Compute and return the average step size between actuator positions for the
entire sample projection sample set.
This value is given by
(xN-1 - x0)/(N - 1)
where N is the number of sample points and {xk} are the
actuator positions.
NOTE:
- The above result is the same as computing the steps size
hk = xk - xk-1 between
each sample then averaging the set.
public double compAveAxisStepSize(ProfileData.Angle view)
Compute and return the average step size between axis sample positions for the
given projection view.
This value is given by
(xN-1 - x0)/(N - 1)
where N is the number of sample points and {xk} are the
axis positions.
NOTE:
- The above result is the same as computing the steps size
hk = xk - xk-1 between
each sample then averaging the set.
public double compStdDev(ProfileData.Angle view)
Return the (normalized) standard deviation σ of the given projection.
The standard
deviation is defined as
σ = <(x - μ)2>½
NOTE:
- The returned value is for a discrete function and must be treated as a "normalized"
quantity when considering sampled data from a continuous system. To convert to the
continuous approximation for σ the returned value
must be multiplied
by h where h is the sampling interval.
- Because of signal noise and numerical rounding it is possible to compute a value
for <(x - μ)2> which is less than zero. Such an occurrence
indicates either that sampling interval h is too large, or that the signal-to-noise
ratio is too small to permit meaningful results. A zero value is returned in this
situation.
view
- project data to analyzepublic double computeMoment(int intOrder, ProfileData.Angle view)
Compute and return the indicated moment for the given projection data.
The value of the returned moment <xn> is defined as
<xn> = Sn(0)/S0(0)
NOTE:
- The returned value is for a discrete function and must be treated as a "normalized"
quantity when considering sampled data from a continuous system. To convert to the
continuous approximation for <xn> the returned value must be multiplied
by hn where h is the sampling interval.
intOrder
- moment orderview
- project data to analyzepublic double computeCentralMoment(int intOrder, ProfileData.Angle view)
Compute and return the indicated central moment for the given projection data.
The value of the returned moment <(x - μ)n> is defined as
<(x - μ)n> = Sn(μ)/S0(0)
NOTE:
- The returned value is for a discrete function and must be treated as a "normalized"
quantity when considering sampled data from a continuous system. To convert to the
continuous approximation for <(x - μ)n> the returned value
must be multiplied
by hn where h is the sampling interval.
intOrder
- moment orderview
- project data to analyzepublic double computeWeightedSum(int intOrder, double dblCntr, ProfileData.Angle view)
Compute and return the weighted central summation Sn(μ)
which is defined
Sn(μ) = Σk(k - μ)nfk
intOrder
- order of the summation weight (i.e., n)dblCntr
- center of the summation weight (i.e., μ)view
- projection view angle (i.e., the set {fk})