mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-07-01 03:22:07 +08:00
d8f56b30b5
* ban all of common & copy numpy_fast * add numpy_fast * these are okay * and ban controls * better name * Conversions * do utils, kalman * clean up * sorting * don't forget old-commit-hash: 8d961a12e5b033855f2abf5d8bd9c51374f74c6e
20 lines
383 B
Python
20 lines
383 B
Python
import numpy as np
|
|
|
|
class Conversions:
|
|
# Speed
|
|
MPH_TO_KPH = 1.609344
|
|
KPH_TO_MPH = 1. / MPH_TO_KPH
|
|
MS_TO_KPH = 3.6
|
|
KPH_TO_MS = 1. / MS_TO_KPH
|
|
MS_TO_MPH = MS_TO_KPH * KPH_TO_MPH
|
|
MPH_TO_MS = MPH_TO_KPH * KPH_TO_MS
|
|
MS_TO_KNOTS = 1.9438
|
|
KNOTS_TO_MS = 1. / MS_TO_KNOTS
|
|
|
|
# Angle
|
|
DEG_TO_RAD = np.pi / 180.
|
|
RAD_TO_DEG = 1. / DEG_TO_RAD
|
|
|
|
# Mass
|
|
LB_TO_KG = 0.453592
|