Created
December 24, 2016 17:44
-
-
Save takehaya/9f6085729829b54317bdbc8728c42b53 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class KalmanFilter { | |
private: | |
float angle;//カルマンフィルタにより算出された角度 - 2×1の状態ベクトルの一部 | |
float bias;//カルマンフィルタによって算出ジャイロバイアス - 2×1の状態ベクトルの一部 | |
float rate;//バイアスのレート | |
float P[2][2];//誤差共分散行列は、 - 2×2行列 | |
float Q_angle; | |
float Q_bias; | |
float R_measure; | |
public: | |
KalmanFilter(); | |
void setAngle(float newAngle); | |
float getAngle(float newAngle, float newRate, float dt); | |
void setQangle(float Q_angle); | |
void setQbias(float Q_bias); | |
void setRmeasure(float R_measure); | |
}; | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment