Use unicode characters in docs equations (#3487)

javac and javadoc needed the encoding set to UTF-8.
This commit is contained in:
Tyler Veness
2021-07-29 22:42:43 -07:00
committed by GitHub
parent 85748f2e6f
commit 3838cc4ec4
42 changed files with 216 additions and 170 deletions

View File

@@ -64,6 +64,7 @@ public final class Discretization {
/**
* Discretizes the given continuous A and Q matrices.
*
* @param <States> Nat representing the number of states.
* @param contA Continuous system matrix.
* @param contQ Continuous process noise covariance matrix.
* @param dtSeconds Discretization timestep.
@@ -128,11 +129,11 @@ public final class Discretization {
Matrix<States, States> lastTerm = Q.copy();
double lastCoeff = dtSeconds;
// A^T^n
// Aᵀⁿ
Matrix<States, States> Atn = contA.transpose();
Matrix<States, States> phi12 = lastTerm.times(lastCoeff);
// i = 6 i.e. 6th order should be enough precision
// i = 6 i.e. 5th order should be enough precision
for (int i = 2; i < 6; ++i) {
lastTerm = contA.times(-1).times(lastTerm).plus(Q.times(Atn));
lastCoeff *= dtSeconds / ((double) i);

View File

@@ -18,7 +18,7 @@ public final class LinearSystemId {
/**
* Create a state-space model of an elevator system. The states of the system are [position,
* velocity]^T, inputs are [voltage], and outputs are [position].
* velocity], inputs are [voltage], and outputs are [position].
*
* @param motor The motor (or gearbox) attached to the arm.
* @param massKg The mass of the elevator carriage, in kilograms.
@@ -72,7 +72,7 @@ public final class LinearSystemId {
/**
* Create a state-space model of a differential drive drivetrain. In this model, the states are
* [v_left, v_right]^T, inputs are [V_left, V_right]^T and outputs are [v_left, v_right]^T.
* [v_left, v_right], inputs are [V_left, V_right] and outputs are [v_left, v_right].
*
* @param motor the gearbox representing the motors driving the drivetrain.
* @param massKg the mass of the robot.
@@ -157,7 +157,7 @@ public final class LinearSystemId {
/**
* Identify a position system from it's kV (volts/(unit/sec)) and kA (volts/(unit/sec^2). These
* constants cam be found using frc-characterization. The states of the system are [position,
* velocity]^T, inputs are [voltage], and outputs are [position].
* velocity], inputs are [voltage], and outputs are [position].
*
* <p>The distance unit you choose MUST be an SI unit (i.e. meters or radians). You can use the
* {@link edu.wpi.first.math.util.Units} class for converting between unit types.
@@ -181,8 +181,8 @@ public final class LinearSystemId {
* Identify a standard differential drive drivetrain, given the drivetrain's kV and kA in both
* linear (volts/(meter/sec) and volts/(meter/sec^2)) and angular (volts/(meter/sec) and
* volts/(meter/sec^2)) cases. This can be found using frc-characterization. The states of the
* system are [left velocity, right velocity]^T, inputs are [left voltage, right voltage]^T, and
* outputs are [left velocity, right velocity]^T.
* system are [left velocity, right velocity], inputs are [left voltage, right voltage], and
* outputs are [left velocity, right velocity].
*
* @param kVLinear The linear velocity gain, volts per (meter per second).
* @param kALinear The linear acceleration gain, volts per (meter per second squared).
@@ -211,8 +211,8 @@ public final class LinearSystemId {
* Identify a standard differential drive drivetrain, given the drivetrain's kV and kA in both
* linear (volts/(meter/sec) and volts/(meter/sec^2)) and angular (volts/(radian/sec) and
* volts/(radian/sec^2)) cases. This can be found using frc-characterization. The states of the
* system are [left velocity, right velocity]^T, inputs are [left voltage, right voltage]^T, and
* outputs are [left velocity, right velocity]^T.
* system are [left velocity, right velocity], inputs are [left voltage, right voltage], and
* outputs are [left velocity, right velocity].
*
* @param kVLinear The linear velocity gain, volts per (meter per second).
* @param kALinear The linear acceleration gain, volts per (meter per second squared).