org.firstinspires.ftc.robotcore.external.navigation

## Class Acceleration

- java.lang.Object
- - org.firstinspires.ftc.robotcore.external.navigation.Acceleration

-     public class Acceleration
      extends java.lang.Object

  Instances of `Acceleration` represent the second derivative of `Position` over time. This is also to say that `Position` is a double integration of `Acceleration` with respect to time.
  See Also:
    `Velocity`, `Position`

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `long` | `acquisitionTime` the time on the System.nanoTime() clock at which the data was acquired.
    `static double` | `earthGravity` The (nominal) acceleration due to Earth's gravity The units are in m/s^2
    `DistanceUnit` | `unit` The distance units in which this acceleration is expressed.
    `double` | `xAccel`
    `double` | `yAccel`
    `double` | `zAccel`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `Acceleration()`
    `Acceleration(DistanceUnit unit, double xAccel, double yAccel, double zAccel, long acquisitionTime)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static Acceleration` | `fromGravity(double gx, double gy, double gz, long acquisitionTime)` Returns an acceleration constructed from measures in units of earth's gravity rather than explicit distance units.
    `java.lang.String` | `toString()`
    `Acceleration` | `toUnit(DistanceUnit distanceUnit)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### earthGravity

          public static final double earthGravity

      The (nominal) acceleration due to Earth's gravity The units are in m/s^2
      See Also:
        Constant Field Values

    - #### unit

          public DistanceUnit unit

      The distance units in which this acceleration is expressed. The time unit is always "per second per second".

    - #### xAccel

          public double xAccel

    - #### yAccel

          public double yAccel

    - #### zAccel

          public double zAccel

    - #### acquisitionTime

          public long acquisitionTime

      the time on the System.nanoTime() clock at which the data was acquired. If no timestamp is associated with this particular set of data, this value is zero.

  - ### Constructor Detail

    - #### Acceleration

          public Acceleration()

    - #### Acceleration

          public Acceleration(DistanceUnit unit,
                              double xAccel,
                              double yAccel,
                              double zAccel,
                              long acquisitionTime)

  - ### Method Detail

    - #### fromGravity

          public static Acceleration fromGravity(double gx,
                                                 double gy,
                                                 double gz,
                                                 long acquisitionTime)

      Returns an acceleration constructed from measures in units of earth's gravity rather than explicit distance units.

    - #### toUnit

          public Acceleration toUnit(DistanceUnit distanceUnit)

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`