mirror of
https://github.com/nasa/trick.git
synced 2025-06-16 14:18:28 +00:00
Trick View: update to handle udunits #262
Updated unit symbols to match those in udunits.
This commit is contained in:
@ -23,12 +23,12 @@ public enum UnitType {
|
||||
|
||||
Angle(new ArrayList<Unit>() {{
|
||||
add(new Unit("radians", "rad", false, 0.0, 1.0));
|
||||
add(new Unit("pico-radians", "pr", false, 0.0, 1.0 * PICO));
|
||||
add(new Unit("nano-radians", "nr", false, 0.0, 1.0 * NANO));
|
||||
add(new Unit("micro-radians", "ur", false, 0.0, 1.0 * MICRO));
|
||||
add(new Unit("milli-radians", "mr", false, 0.0, 1.0 * MILLI));
|
||||
add(new Unit("centi-radians", "cr", false, 0.0, 1.0 * CENTI));
|
||||
add(new Unit("deci-radians", "dr", false, 0.0, 1.0 * DECI));
|
||||
add(new Unit("pico-radians", "prad", false, 0.0, 1.0 * PICO));
|
||||
add(new Unit("nano-radians", "nrad", false, 0.0, 1.0 * NANO));
|
||||
add(new Unit("micro-radians", "urad", false, 0.0, 1.0 * MICRO));
|
||||
add(new Unit("milli-radians", "mrad", false, 0.0, 1.0 * MILLI));
|
||||
add(new Unit("centi-radians", "crad", false, 0.0, 1.0 * CENTI));
|
||||
add(new Unit("deci-radians", "drad", false, 0.0, 1.0 * DECI));
|
||||
add(new Unit("degrees", "degree", false, 0.0, 0.0174532925199433));
|
||||
add(new Unit("arc-seconds", "arcsecond", false, 0.0, 4.848136811095362e-06));
|
||||
add(new Unit("arc-minutes", "arcminute", false, 0.0, 0.000290888208666));
|
||||
@ -36,7 +36,7 @@ public enum UnitType {
|
||||
}}),
|
||||
|
||||
Current(new ArrayList<Unit>() {{
|
||||
add(new Unit("amperes", "amp", true, 0.0, 1.0));
|
||||
add(new Unit("amperes", "A", true, 0.0, 1.0));
|
||||
}}),
|
||||
|
||||
Distance(new ArrayList<Unit>() {{
|
||||
@ -106,7 +106,7 @@ public enum UnitType {
|
||||
add(new Unit("seconds", "s", true, 0.0, 1.0));
|
||||
add(new Unit("minutes", "min", false, 0.0, 60.0));
|
||||
add(new Unit("hours", "hr", false, 0.0, 3600.0));
|
||||
add(new Unit("days", "day", false, 0.0, 86400.0));
|
||||
add(new Unit("days", "d", false, 0.0, 86400.0));
|
||||
}}),
|
||||
|
||||
Unitless(new ArrayList<Unit>() {{
|
||||
@ -142,7 +142,7 @@ public enum UnitType {
|
||||
/** SI unit prefixes */
|
||||
private final Unit[] prefixes = {
|
||||
new Unit("pico-", "p", false, 0.0, PICO),
|
||||
new Unit("nana-", "n", false, 0.0, NANO),
|
||||
new Unit("nano-", "n", false, 0.0, NANO),
|
||||
new Unit("micro-", "u", false, 0.0, MICRO),
|
||||
new Unit("milli-", "m", false, 0.0, MILLI),
|
||||
new Unit("centi-", "c", false, 0.0, CENTI),
|
||||
|
Reference in New Issue
Block a user