mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-24 01:31:46 +00:00
[wpiunits] Add Acceleration and MOI Units (#6495)
This commit is contained in:
committed by
GitHub
parent
dc4c63568a
commit
3e6c0d0b71
@@ -182,6 +182,27 @@ public final class Units {
|
||||
public static final Velocity<Velocity<Distance>> MetersPerSecondPerSecond =
|
||||
MetersPerSecond.per(Second);
|
||||
|
||||
/**
|
||||
* A unit of angular acceleration equivalent to accelerating at a rate of one {@link #Rotations
|
||||
* Rotation} per {@link #Second} every second.
|
||||
*/
|
||||
public static final Velocity<Velocity<Angle>> RotationsPerSecondPerSecond =
|
||||
RotationsPerSecond.per(Second);
|
||||
|
||||
/**
|
||||
* The standard SI unit of angular acceleration, equivalent to accelerating at a rate of one
|
||||
* {@link #Radians Radian} per {@link #Second} every second.
|
||||
*/
|
||||
public static final Velocity<Velocity<Angle>> RadiansPerSecondPerSecond =
|
||||
RadiansPerSecond.per(Second);
|
||||
|
||||
/**
|
||||
* A unit of angular acceleration equivalent to accelerating at a rate of one {@link #Degrees
|
||||
* Degree} per {@link #Second} every second.
|
||||
*/
|
||||
public static final Velocity<Velocity<Angle>> DegreesPerSecondPerSecond =
|
||||
DegreesPerSecond.per(Second);
|
||||
|
||||
/**
|
||||
* A unit of acceleration equivalent to the pull of gravity on an object at sea level on Earth.
|
||||
*/
|
||||
@@ -223,6 +244,11 @@ public final class Units {
|
||||
/** 1/16 of a {@link #Pound}. */
|
||||
public static final Mass Ounce = Ounces; // alias
|
||||
|
||||
// Moment of Inertia
|
||||
/** The base SI unit for moment of inertia. */
|
||||
public static final Mult<Mult<Mass, Distance>, Distance> KilogramSquareMeters =
|
||||
Kilograms.mult(Meters).mult(Meters);
|
||||
|
||||
// Unitless
|
||||
/** A dimensionless unit that performs no scaling whatsoever. */
|
||||
public static final Dimensionless Value = BaseUnits.Value;
|
||||
|
||||
Reference in New Issue
Block a user