org.android.activityminer.logic.features.calculators
Class VerticalHoricontalMagnitudeCalculator<T extends Enum<T> & Dimensions>

Package class diagram package VerticalHoricontalMagnitudeCalculator
java.lang.Object
  extended by org.android.activityminer.logic.features.calculators.VerticalHoricontalMagnitudeCalculator<T>
Type Parameters:
T - the enumeration type for the dimensions
All Implemented Interfaces:
PreparationCalculator<T>

public final class VerticalHoricontalMagnitudeCalculator<T extends Enum<T> & Dimensions>
extends Object
implements PreparationCalculator<T>

Implementation of an calculator to extract the vertical and horizontal magnitudes of acceleration by projection of the actual acceleration vector a to the global gravity direction g.


Field Summary
private  T dimAx
          the dimension for the x component of linear acceleration
private  T dimAy
          the dimension for the y component of linear acceleration
private  T dimAz
          the dimension for the z component of linear acceleration
private  T dimGx
          the dimension for the y component of gravity
private  T dimGy
          the dimension for the z component of gravity
private  T dimGz
          the dimension for the x component of gravity
private  T dimMagH
          the dimension for the magnitude of horizontal acceleration
private  T dimMagV
          the dimension for the magnitude of vertical acceleration
 
Constructor Summary
VerticalHoricontalMagnitudeCalculator(T dimAx, T dimAy, T dimAz, T dimGx, T dimGy, T dimGz, T dimMagH, T dimMagV)
          Constructor
 
Method Summary
 void prepareObservation(SensorObservation<T,Double> observation)
          The preparation method for observations
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dimAx

private final T extends Enum<T> & Dimensions dimAx
the dimension for the x component of linear acceleration


dimAy

private final T extends Enum<T> & Dimensions dimAy
the dimension for the y component of linear acceleration


dimAz

private final T extends Enum<T> & Dimensions dimAz
the dimension for the z component of linear acceleration


dimGx

private final T extends Enum<T> & Dimensions dimGx
the dimension for the y component of gravity


dimGy

private final T extends Enum<T> & Dimensions dimGy
the dimension for the z component of gravity


dimGz

private final T extends Enum<T> & Dimensions dimGz
the dimension for the x component of gravity


dimMagH

private final T extends Enum<T> & Dimensions dimMagH
the dimension for the magnitude of horizontal acceleration


dimMagV

private final T extends Enum<T> & Dimensions dimMagV
the dimension for the magnitude of vertical acceleration

Constructor Detail

VerticalHoricontalMagnitudeCalculator

public VerticalHoricontalMagnitudeCalculator(T dimAx,
                                             T dimAy,
                                             T dimAz,
                                             T dimGx,
                                             T dimGy,
                                             T dimGz,
                                             T dimMagH,
                                             T dimMagV)
Constructor

Parameters:
dimAx - the dimension for the x component of linear acceleration
dimAy - the dimension for the y component of linear acceleration
dimAz - the dimension for the z component of linear acceleration
dimGx - the dimension for the y component of gravity
dimGy - the dimension for the z component of gravity
dimGz - the dimension for the x component of gravity
dimMagH - the dimension for the magnitude of horizontal acceleration
dimMagV - the dimension for the magnitude of vertical acceleration
Method Detail

prepareObservation

public final void prepareObservation(SensorObservation<T,Double> observation)
Description copied from interface: PreparationCalculator
The preparation method for observations

Specified by:
prepareObservation in interface PreparationCalculator<T extends Enum<T> & Dimensions>
Parameters:
observation - the observation to prepare for feature extraction