JP2013185898A - State estimation device - Google Patents

State estimation device Download PDF

Info

Publication number
JP2013185898A
JP2013185898A JP2012050297A JP2012050297A JP2013185898A JP 2013185898 A JP2013185898 A JP 2013185898A JP 2012050297 A JP2012050297 A JP 2012050297A JP 2012050297 A JP2012050297 A JP 2012050297A JP 2013185898 A JP2013185898 A JP 2013185898A
Authority
JP
Japan
Prior art keywords
vector
initial
state
value
posture
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2012050297A
Other languages
Japanese (ja)
Inventor
Ibuki Handa
伊吹 半田
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Yamaha Corp
Original Assignee
Yamaha Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Yamaha Corp filed Critical Yamaha Corp
Priority to JP2012050297A priority Critical patent/JP2013185898A/en
Publication of JP2013185898A publication Critical patent/JP2013185898A/en
Pending legal-status Critical Current

Links

Images

Abstract

PROBLEM TO BE SOLVED: To perform accurate state estimation by using nonlinear Kalman filters.SOLUTION: A state estimation device is embedded in a portable apparatus 1 including a plurality of sensors each for observing a system and outputting an observed value, a GPS unit 60 for outputting position information Ps, and a camera 110 for photographing an object Obj and outputting image information Img, and estimates a state of the system. The state estimation device includes: a Kalman filter operation unit 300 which includes one or more Kalman filters KF for updating a state vector x by using the state vector x including a state variable for estimating a posture μ of the portable apparatus 1 as an element and an observed value vector y having each observed value as the element; and an initial value generating unit 200 which calculates an initial value μof the posture μ of the portable apparatus 1 on the basis of the image information Img and the position information Ps, generates an initial vector INI having the initial value μas the element, and supplies this to the Kalman filter KF as an initial value of the state vector x.

Description

本発明は状態推定装置に関する。   The present invention relates to a state estimation device.

地磁気の向きや、物体の姿勢等を算出する場合、地磁気センサからの出力結果のみに基づいて算出するよりも、地磁気センサの他に加速度センサや角速度センサ等の異種の物理量を測定する複数のセンサの出力結果を統合して算出した方が、短時間で正確な値を求めることができる。   When calculating the direction of geomagnetism, the posture of an object, etc., multiple sensors that measure different physical quantities such as acceleration sensors and angular velocity sensors in addition to the geomagnetic sensor, rather than calculating only based on the output result from the geomagnetic sensor If the output results are integrated and calculated, an accurate value can be obtained in a short time.

異種の物理量を測定する複数のセンサの出力を統合し、動的システムの状態を推定する方法として、非線形カルマンフィルタを用いる方法が知られている。例えば、特許文献1には、3軸の角速度センサ及び3軸の加速度センサと非線形カルマンフィルタとを実装した姿勢角計測装置が開示されている。また、非特許文献1には、3軸角速度センサ、3軸加速度センサ、及び3軸地磁気センサからの出力信号を、拡張カルマンフィルタやアンセンテッド変換を用いたシグマポイントカルマンフィルタを用いて統合し、姿勢を推定する方法が開示されている。   A method using a nonlinear Kalman filter is known as a method for estimating the state of a dynamic system by integrating the outputs of a plurality of sensors that measure different physical quantities. For example, Patent Document 1 discloses a posture angle measurement device in which a triaxial angular velocity sensor, a triaxial acceleration sensor, and a nonlinear Kalman filter are mounted. In Non-Patent Document 1, output signals from a 3-axis angular velocity sensor, a 3-axis acceleration sensor, and a 3-axis geomagnetic sensor are integrated using an extended Kalman filter or a sigma point Kalman filter using unscented transformation, and the posture is integrated. An estimation method is disclosed.

一般的に、非線形カルマンフィルタは、動的システムの状態を表す複数の物理量の経時的な変化を推定する状態遷移モデルと、推定された動的システムの状態から、動的システムの有する複数のセンサが計測する値(観測値)を推定する観測モデルとを有する。そして、非線形カルマンフィルタは、推定された観測値と、複数のセンサが実際に測定する観測値との差分(観測残差)を用いて、動的システムの状態を表す複数の物理量の各々の推定値(状態変数)を要素とする状態ベクトルを推定し逐次更新することにより、状態ベクトルの各要素の示す値を、実際の物理量(真値)に近づける演算を行う。   In general, a nonlinear Kalman filter is composed of a state transition model that estimates changes over time in a plurality of physical quantities representing the state of a dynamic system, and a plurality of sensors that the dynamic system has based on the estimated state of the dynamic system. And an observation model for estimating a value to be measured (observed value). Then, the nonlinear Kalman filter uses the difference (observation residual) between the estimated observation value and the observation value actually measured by the plurality of sensors to estimate each of the plurality of physical quantities representing the state of the dynamic system. A state vector having (state variable) as an element is estimated and sequentially updated, so that the value indicated by each element of the state vector is approximated to an actual physical quantity (true value).

特開平9−5104号公報Japanese Patent Laid-Open No. 9-5104

Wolfgang Gunthner, “Enhancing Cognitive Assistance Systems with Inertial Measurement Units”, Springer, 2008Wolfgang Gunthner, “Enhancing Cognitive Assistance Systems with Inertial Measurement Units”, Springer, 2008

ところで、非線形カルマンフィルタは、状態ベクトルと、状態ベクトルに基づいて算出される観測残差とを用いて、状態ベクトルを逐次更新する演算であるため、状態ベクトルの初期値の各要素が真値から乖離した値に設定された場合、状態ベクトルの各要素が真値に近い値に収束するまでに長時間を要することがあり、更には、状態ベクトルの各要素が真値とは異なる不正確な値に収束することも起こり得る。この場合、非線形カルマンフィルタは、システムの状態を正確に推定することはできない。   By the way, since the nonlinear Kalman filter is an operation that sequentially updates the state vector using the state vector and the observation residual calculated based on the state vector, each element of the initial value of the state vector deviates from the true value. If the value is set to the specified value, it may take a long time for each element of the state vector to converge to a value close to the true value. Convergence can also occur. In this case, the nonlinear Kalman filter cannot accurately estimate the state of the system.

本発明は、上述した点に鑑みてなされたものであり、非線形カルマンフィルタを用いて正確な状態推定を行うことを解決課題とする。   The present invention has been made in view of the above-described points, and an object of the present invention is to perform accurate state estimation using a nonlinear Kalman filter.

上述した課題を解決するため、本発明に係る状態推定装置は、システムを観測して観測値を各々出力する複数のセンサと、位置情報を出力する位置情報出力部と、物体を撮影し画像情報を出力する画像取得部と、を備える機器に組み込まれ、前記システムの状態を推定する状態推定装置であって、前記システムの状態を推定する値である複数の状態変数を要素とする状態ベクトルと、前記観測値の各々を要素とする観測値ベクトルとを用いて、前記状態ベクトルを更新するカルマンフィルタを1以上備えるカルマンフィルタ演算部と、前記状態ベクトルの初期値である初期ベクトルを生成する初期値生成部と、を備え、前記複数の状態変数は、前記機器の姿勢を推定する状態変数を含み、前記初期値生成部は、1以上の物体を前記画像取得部が撮影した際に前記画像取得部が出力する前記画像情報と、前記位置情報出力部が出力する前記位置情報と、に基づいて、前記機器の姿勢を推定する状態変数の初期値である初期姿勢推定値を算出し、前記初期姿勢推定値を要素とする前記初期ベクトルを生成する、ことを特徴とする。   In order to solve the above-described problems, a state estimation apparatus according to the present invention includes a plurality of sensors that observe a system and output observation values, a position information output unit that outputs position information, and image information obtained by photographing an object. A state estimation device that estimates a state of the system, and is a state vector having a plurality of state variables as elements to estimate the state of the system; , Using an observation value vector having each of the observation values as an element, a Kalman filter operation unit including one or more Kalman filters for updating the state vector, and generating an initial value that is an initial value of the state vector And the plurality of state variables include state variables for estimating the posture of the device, and the initial value generation unit includes one or more objects as the image acquisition unit. Initial posture estimation, which is an initial value of a state variable for estimating the posture of the device, based on the image information output by the image acquisition unit when the image is taken and the position information output by the position information output unit A value is calculated, and the initial vector having the initial posture estimated value as an element is generated.

機器の姿勢は、当該機器の利用者の動作に依存するため、初期姿勢推定値を事前に定められた何らかの固定値とした場合には、初期姿勢推定値と、機器の真の姿勢とは大きく乖離する場合がある。
この発明によれば、画像情報と位置情報とに基づいて初期姿勢推定値を算出する。画像情報に基づいて、機器から見た物体の方向を算出することができる。従って、機器の位置を表す位置情報に基づいて、機器と物体との位置関係を算出できる場合、機器から見た物体の方向と、機器と物体との位置関係とに基づいて、機器の姿勢を算出することができる。これにより、機器の姿勢を推定する状態変数と、機器の真の姿勢とが大きく乖離することを防止することができ、状態推定装置がシステムの状態を正確に推定することが可能となる。
Since the posture of the device depends on the operation of the user of the device, if the initial posture estimated value is set to some predetermined fixed value, the initial posture estimated value and the true posture of the device are large. There may be a gap.
According to this invention, the initial posture estimated value is calculated based on the image information and the position information. Based on the image information, the direction of the object viewed from the device can be calculated. Therefore, when the positional relationship between the device and the object can be calculated based on the position information representing the position of the device, the orientation of the device is determined based on the direction of the object viewed from the device and the positional relationship between the device and the object. Can be calculated. As a result, it is possible to prevent the state variable for estimating the posture of the device from greatly deviating from the true posture of the device, and the state estimation device can accurately estimate the state of the system.

また、上述した状態推定装置において、前記カルマンフィルタ演算部は、並列に動作する所定数の前記カルマンフィルタを備え、前記初期値生成部は、前記画像取得部が、1の物体を撮影して前記画像情報を出力した場合に、前記画像情報に基づいて、前記機器に固定された3軸の座標系である機器座標系において、前記機器から見た前記1の物体の方向を表した第1方向ベクトルを算出する画像処理部と、前記位置情報に基づいて、地球上に固定された3軸の座標系である地上座標系において、前記機器から見た前記1の物体の方向を表した第2方向ベクトルを算出し、前記第1方向ベクトル及び前記第2方向ベクトルに基づいて、初期姿勢候補値を算出し、前記初期姿勢候補値を、前記第2方向ベクトルを回転軸として所定角度ずつ回転させることで、前記所定数の前記初期姿勢推定値を算出する初期姿勢算出部と、前記所定数の前記初期姿勢推定値の各々に対応する、前記所定数の前記初期ベクトルを生成し、これらを前記所定数の前記カルマンフィルタにそれぞれ供給する初期ベクトル生成部と、を備える、ことが好ましい。   Further, in the state estimation device described above, the Kalman filter calculation unit includes a predetermined number of the Kalman filters that operate in parallel, and the initial value generation unit includes the image information obtained by the image acquisition unit capturing a single object. In a device coordinate system, which is a three-axis coordinate system fixed to the device, based on the image information, a first direction vector representing the direction of the one object viewed from the device is A second direction vector representing the direction of the first object viewed from the device in a ground coordinate system, which is a three-axis coordinate system fixed on the earth, based on the image processing unit to be calculated and the position information; And calculating an initial posture candidate value based on the first direction vector and the second direction vector, and rotating the initial posture candidate value by a predetermined angle about the second direction vector as a rotation axis. Generating the predetermined number of the initial posture estimation values, and generating the predetermined number of the initial vectors corresponding to each of the predetermined number of the initial posture estimation values. It is preferable that an initial vector generation unit respectively supplied to the predetermined number of the Kalman filters.

この発明によれば、初期値生成部は、所定数の初期姿勢推定値を算出し、所定数の初期姿勢推定値の各々に対応して、所定数の初期ベクトルを生成する。そして、初期値生成部は、これらの所定数の初期ベクトルを、所定数のカルマンフィルタにそれぞれ供給する。
所定数の初期ベクトルは、互いに異なる値を示す。また、所定数の初期ベクトルの各々は、画像情報に基づいて定められる第1方向ベクトルと、位置情報に基づいて定められる第2方向ベクトルとを用いて算出される。従って、所定数の初期ベクトルの中には、各要素が、実際の物理量から大きく乖離しない値を有する初期ベクトルが含まれる。当該初期ベクトルが供給されるカルマンフィルタは、システムの状態を正確に推定することが可能である。これにより、本発明に係る状態推定装置は、システムの状態を正確に推定することが可能となる。
According to the present invention, the initial value generation unit calculates a predetermined number of initial posture estimation values, and generates a predetermined number of initial vectors corresponding to each of the predetermined number of initial posture estimation values. Then, the initial value generation unit supplies the predetermined number of initial vectors to the predetermined number of Kalman filters.
The predetermined number of initial vectors indicate different values. Each of the predetermined number of initial vectors is calculated using a first direction vector determined based on the image information and a second direction vector determined based on the position information. Therefore, the predetermined number of initial vectors includes initial vectors in which each element has a value that does not greatly deviate from the actual physical quantity. The Kalman filter supplied with the initial vector can accurately estimate the state of the system. Thereby, the state estimation apparatus according to the present invention can accurately estimate the state of the system.

また、上述した状態推定装置において、前記カルマンフィルタ演算部は、1つの前記カルマンフィルタを備え、前記初期値生成部は、前記画像取得部が、2つの物体を撮影して前記画像情報を出力した場合に、前記画像情報に基づいて、前記機器に固定された3軸の座標系である機器座標系において、前記機器から見た前記2つの物体の各々の方向を表した2つの第1方向ベクトルを算出する画像処理部と、前記位置情報に基づいて、地球上に固定された3軸の座標系である地上座標系において、前記機器から見た前記2つの物体の各々の方向を表した2つの第2方向ベクトルを算出し、前記2つの第1方向ベクトル及び前記2つの第2方向ベクトルに基づいて、前記初期姿勢推定値を算出する、初期姿勢算出部と、前記初期姿勢推定値を要素とする前記初期ベクトルを生成し、これを前記カルマンフィルタに供給する初期ベクトル生成部と、を備える、ことが好ましい。   In the state estimation device described above, the Kalman filter calculation unit includes one Kalman filter, and the initial value generation unit is configured when the image acquisition unit captures two objects and outputs the image information. Based on the image information, in a device coordinate system that is a three-axis coordinate system fixed to the device, two first direction vectors representing the directions of the two objects viewed from the device are calculated. And a second coordinate system representing the directions of the two objects viewed from the device in a ground coordinate system that is a three-axis coordinate system fixed on the earth based on the position information. An initial posture calculation unit that calculates a two-direction vector, calculates the initial posture estimation value based on the two first direction vectors and the two second direction vectors, and requires the initial posture estimation value. Generating the initial vector to which a and a initial vector generator to be supplied to the Kalman filter, it is preferable.

この発明によれば、2つの第1方向ベクトル及び2つの第2方向ベクトルに基づいて、初期姿勢推定値を算出するため、初期姿勢推定値は、機器の実際の姿勢を正確に表す値となる。従って、本発明に係る状態推定装置は、正確な状態推定を行うことが可能となる。   According to this invention, since the initial posture estimated value is calculated based on the two first direction vectors and the two second direction vectors, the initial posture estimated value is a value that accurately represents the actual posture of the device. . Therefore, the state estimation apparatus according to the present invention can perform accurate state estimation.

また、上述した状態推定装置は、時刻情報を出力する時刻出力部を備え、前記初期姿勢算出部は、前記位置情報と、前記時刻情報と、に基づいて、前記第2方向ベクトルを算出する、ことが好ましい。   Further, the state estimation device described above includes a time output unit that outputs time information, and the initial posture calculation unit calculates the second direction vector based on the position information and the time information. It is preferable.

この発明に係る物体は、例えば、太陽、月等の天体が該当する。天体は、位置情報と時刻情報とにより、地上座標系において機器から見た物体の方向を特定することができる。すなわち、位置情報と時刻情報とに基づいて算出される第2方向ベクトルは、機器から見た物体の方向を正確に表す。
状態推定装置は、このような第2方向ベクトルに基づいて初期姿勢推定値を算出するため、正確な状態推定を行うことが可能となる。
The object according to the present invention corresponds to celestial bodies such as the sun and the moon. The celestial body can specify the direction of the object viewed from the device in the ground coordinate system based on the position information and the time information. That is, the second direction vector calculated based on the position information and the time information accurately represents the direction of the object viewed from the device.
Since the state estimation device calculates the initial posture estimation value based on such a second direction vector, it is possible to perform accurate state estimation.

また、上述した状態推定装置において、前記物体は、前記地上座標系における座標が既知であり、前記初期姿勢算出部は、前記位置情報と、前記物体の前記地上座標系における座標とに基づいて、前記第2方向ベクトルを算出する、ことを特徴とすることが好ましい。   In the state estimation device described above, the object has known coordinates in the ground coordinate system, and the initial posture calculation unit is based on the position information and the coordinates of the object in the ground coordinate system. It is preferable that the second direction vector is calculated.

この発明に係る物体は、例えば、著名な建造物等のランドマークのうち、地上座標系における座標が既知のランドマークが該当する。地上座標系における座標が既知の物体は、当該座標と、機器の位置情報とに基づいて、機器から見た物体の方向を特定することができる。すなわち、位置情報と、物体の地上座標系における座標とに基づいて算出される第2方向ベクトルは、機器から見た物体の方向を正確に表す。
状態推定装置は、このような第2方向ベクトルに基づいて初期姿勢推定値を算出するため、正確な状態推定を行うことが可能となる。
The object according to the present invention corresponds to a landmark whose coordinates in the ground coordinate system are known among landmarks such as famous buildings. An object whose coordinates in the ground coordinate system are known can specify the direction of the object viewed from the device based on the coordinates and the position information of the device. That is, the second direction vector calculated based on the position information and the coordinates of the object in the ground coordinate system accurately represents the direction of the object viewed from the device.
Since the state estimation device calculates the initial posture estimation value based on such a second direction vector, it is possible to perform accurate state estimation.

本発明の実施形態に係る携帯機器の構成を示すブロック図である。It is a block diagram which shows the structure of the portable apparatus which concerns on embodiment of this invention. 携帯機器の外観を示す斜視図である。It is a perspective view which shows the external appearance of a portable apparatus. 状態推定装置の機能を表す機能ブロック図である。It is a functional block diagram showing the function of a state estimation apparatus. 携帯機器の姿勢と物体との関係を表す説明図である。It is explanatory drawing showing the relationship between the attitude | position of a portable apparatus, and an object. カルマンフィルタ演算部の機能を表す機能ブロック図である。It is a functional block diagram showing the function of a Kalman filter calculating part. 変形例1に係る初期値生成部の機能を表す機能ブロック図である。It is a functional block diagram showing the function of the initial value generation part which concerns on the modification 1. FIG. 変形例5に係る状態推定装置の機能を表す機能ブロック図である。It is a functional block diagram showing the function of the state estimation apparatus which concerns on the modification 5. 変形例6に係るカルマンフィルタ演算部の機能を表す機能ブロック図である。It is a functional block diagram showing the function of the Kalman filter operation part concerning the modification 6.

<A.実施形態>
本発明の実施の形態について図面を参照して説明する。
<A. Embodiment>
Embodiments of the present invention will be described with reference to the drawings.

[1. 機器構成及びソフトウェア構成について]
図1は、本発明の実施形態に係る携帯機器のブロック図であり、図2は携帯機器の外観を示す斜視図である。携帯機器1(機器)は、携帯機器1の姿勢変化に応じて、携帯機器1が備える画面に表示される地図などの画像を回転させることで、画像によって表されている方位を現実空間の方位に追従させる機能を備える。この機能は、各種センサの出力に基づいてカルマンフィルタの演算を行い、携帯機器1の姿勢や、携帯機器1から見た地磁気の向き等を推定することによって実現される。
[1. Device configuration and software configuration]
FIG. 1 is a block diagram of a portable device according to an embodiment of the present invention, and FIG. 2 is a perspective view showing an appearance of the portable device. The mobile device 1 (device) rotates the image such as a map displayed on the screen included in the mobile device 1 in accordance with the change in the posture of the mobile device 1, thereby changing the orientation represented by the image to the orientation in the real space. It has a function to follow. This function is realized by calculating the Kalman filter based on the outputs of various sensors and estimating the orientation of the mobile device 1 and the direction of geomagnetism viewed from the mobile device 1.

携帯機器1は、各種の構成要素とバスを介して接続され装置全体を制御するCPU10、CPU10の作業領域として機能するRAM(蓄積部)20、状態推定プログラム100等の各種プログラム及び各種設定情報を記憶したROM30、通信を実行する通信部40、画像を表示する表示部50、GPS衛星からの情報(具体的には、携帯機器1の緯度、経度についての情報)を取得してこれを出力するGPS部60、携帯機器1の外部に存在する物体Objを撮影して画像情報Imgを出力するカメラ110(画像取得部)、携帯機器1の利用者の各種入力に用いられる操作部120、及び、時刻情報Timeを出力する時計130(時刻出力部)を備える。
また、携帯機器1は、地磁気等の磁気を検出して磁気データqを出力する3次元磁気センサ70、加速度を検出して加速度データaを出力する3次元加速度センサ80、及び角速度を検出して角速度データgを出力する3次元角速度センサ90を備える。
なお、本実施形態は、各種プログラム及び各種設定情報をROM30に格納するが、各種プログラム及び各種設定情報のうちの一部または全部をRAM20に格納してもよい。
The portable device 1 is connected to various components via a bus and controls the entire apparatus, a RAM (storage unit) 20 that functions as a work area of the CPU 10, a state estimation program 100, and various programs and various setting information. The stored ROM 30, the communication unit 40 that executes communication, the display unit 50 that displays images, and information from GPS satellites (specifically, information about the latitude and longitude of the mobile device 1) are acquired and output. A GPS unit 60, a camera 110 (image acquisition unit) that captures an object Obj existing outside the mobile device 1 and outputs image information Img, an operation unit 120 used for various inputs of a user of the mobile device 1, and A clock 130 (time output unit) that outputs time information Time is provided.
The portable device 1 detects a magnetic field such as geomagnetism and outputs magnetic data q, a three-dimensional acceleration sensor 80 that detects acceleration and outputs acceleration data a, and detects an angular velocity. A three-dimensional angular velocity sensor 90 that outputs angular velocity data g is provided.
In the present embodiment, various programs and various setting information are stored in the ROM 30, but some or all of the various programs and various setting information may be stored in the RAM 20.

表示部50は、CPU10が状態推定プログラム100を実行することにより推定したシステムの状態に基づいて算出された地磁気の向きや携帯機器1の姿勢等を、矢印等の画像により表示する。なお、表示部50は、カメラ110が物体Objを撮影して物体Objの描かれた画像情報Imgを出力する場合に、当該画像情報Imgに基づいた画像を表示するものであってもよい。
GPS部60は、GPS衛星からの信号を受信して携帯機器1の位置情報Ps(緯度、経度)を出力する。すなわち、GPS部60は、携帯機器1の位置情報Psを取得し、これを出力する「位置情報出力部」として機能する。
操作部120は、携帯機器1の利用者が、カメラ110を用いた物体Objを撮影するための指示の入力に用いられる。
The display unit 50 displays the orientation of geomagnetism calculated based on the state of the system estimated by the CPU 10 executing the state estimation program 100, the posture of the portable device 1, and the like as images such as arrows. The display unit 50 may display an image based on the image information Img when the camera 110 captures the object Obj and outputs the image information Img on which the object Obj is drawn.
The GPS unit 60 receives a signal from a GPS satellite and outputs position information Ps (latitude, longitude) of the mobile device 1. That is, the GPS unit 60 functions as a “position information output unit” that acquires the position information Ps of the mobile device 1 and outputs the position information Ps.
The operation unit 120 is used by the user of the mobile device 1 to input an instruction for photographing the object Obj using the camera 110.

3次元磁気センサ70は、X軸磁気センサ71、Y軸磁気センサ72、及びZ軸磁気センサ73を備える。各センサは、MI素子(磁気インピーダンス素子)、MR素子(磁気抵抗効果素子)などを用いて構成することができる。磁気センサI/F74は、X軸磁気センサ71、Y軸磁気センサ72、及び、Z軸磁気センサ73からの出力信号をAD変換して磁気データqを出力する。この磁気データqは、x軸、y軸およびz軸の3成分によって表されるベクトルデータである。より具体的には、磁気データqは、携帯機器1に固定(厳密には、3次元磁気センサ70に固定)された3軸の直交座標系において、X軸磁気センサ71からの出力値がx軸成分として表され、Y軸磁気センサ72からの出力値がy軸成分として表され、Z軸磁気センサ73からの出力値がz軸成分として表されるベクトルデータである。
以下において、携帯機器1に固定された3軸の直交座標系を、「機器座標系Σ」と称する。なお、3次元磁気センサ70に固定された座標系、カメラ110に固定された座標系、3次元加速度センサ80に固定された座標系、及び、3次元角速度センサ90に固定された座標系は、厳密には、それぞれ異なる位置に原点を有するが、以下では、説明の便宜上、機器座標系Σと総称する場合がある。
The three-dimensional magnetic sensor 70 includes an X-axis magnetic sensor 71, a Y-axis magnetic sensor 72, and a Z-axis magnetic sensor 73. Each sensor can be configured using an MI element (magnetoimpedance element), an MR element (magnetoresistance effect element), or the like. The magnetic sensor I / F 74 performs AD conversion on output signals from the X-axis magnetic sensor 71, the Y-axis magnetic sensor 72, and the Z-axis magnetic sensor 73, and outputs magnetic data q. The magnetic data q is vector data represented by three components of the x axis, the y axis, and the z axis. More specifically, the magnetic data q is an output value from the X-axis magnetic sensor 71 in a three-axis orthogonal coordinate system fixed to the portable device 1 (strictly, fixed to the three-dimensional magnetic sensor 70). This is vector data expressed as an axis component, an output value from the Y-axis magnetic sensor 72 is expressed as a y-axis component, and an output value from the Z-axis magnetic sensor 73 is expressed as a z-axis component.
Hereinafter, the three-axis orthogonal coordinate system fixed to the mobile device 1 is referred to as “device coordinate system Σ S ”. The coordinate system fixed to the three-dimensional magnetic sensor 70, the coordinate system fixed to the camera 110, the coordinate system fixed to the three-dimensional acceleration sensor 80, and the coordinate system fixed to the three-dimensional angular velocity sensor 90 are: strictly speaking, it has an origin at different positions, respectively, in the following description, may be collectively referred to as device coordinate system sigma S.

ところで、3次元磁気センサ70が検出する磁気データqには、地磁気Bgが含まれる。
地磁気Bgは、磁極北に向かう水平成分と伏角方向の鉛直成分を有する磁界であり、地上のある一点に固定された3軸の直交座標系(以下、「地上座標系Σ」と称する)において、一定の向き及び大きさを有するベクトルBgとして表される。
ここで、ベクトルの符号の左上に示す添え字「G」は、当該ベクトルが地上座標系Σで表されたベクトルであることを意味する。なお、地上座標系Σの原点と、地上座標系Σが有する互いに直交する3軸の向きとは、どのように定めてもよい。本実施形態では、地上座標系Σを、y軸が磁極北を向き、z軸が鉛直上を向くように定める。
よって、機器座標系Σにおいて表した場合、地磁気Bgは、携帯機器1の姿勢μに連動して向きを変える、一定の大きさのベクトルBg(μ)として表される(なお、ベクトルの符号の左上に示す添え字「S」は、当該ベクトルが機器座標系Σで表されたベクトルであることを意味する)。従って、機器座標系Σにおいて地磁気Bgを表すベクトルBg(μ)に基づいて、携帯機器1の姿勢μを求めることができる。
一方、3次元磁気センサ70が搭載される携帯機器1は、着磁性を有する各種金属や、電気回路等、磁界を発生させる部品が備えられることが多い。このため、3次元磁気センサ70が出力するベクトルデータ(磁気データq)は、地磁気Bgを表すベクトルと、携帯機器1に搭載された部品が発する磁界(内部磁界Bi)を表すベクトルとを加算したベクトルとなる。従って、機器座標系Σにおける地磁気Bgを表すベクトルBg(μ)を算出し、携帯機器1から見た地磁気Bgの向きを正確に求めるためには、機器座標系Σにおいて、3次元磁気センサが出力する磁気データqの示す座標から、携帯機器1の部品が発する内部磁界Biを表すベクトルBiを減算する補正処理が必要となる。
このように、検出対象である地磁気Bgの正確な向きを特定するために、補正処理において、3次元磁気センサ70から出力される磁気データqから取り除かれる内部磁界Biを表すベクトルBiを、3次元磁気センサ70のオフセットと呼ぶ。
Incidentally, the magnetic data q detected by the three-dimensional magnetic sensor 70 includes geomagnetism Bg.
The geomagnetism Bg is a magnetic field having a horizontal component toward the magnetic pole north and a vertical component in the dip direction, and in a three-axis orthogonal coordinate system (hereinafter referred to as “ground coordinate system Σ G ”) fixed at a certain point on the ground. , it expressed as a vector G Bg having a constant direction and magnitude.
Here, letter "G" subscript indicates the upper left of the sign of the vector means that the vector is a vector expressed in ground coordinate system sigma G. Note that the origin of the ground coordinate system sigma G, and the three axes of the orientation orthogonal to each other with the ground coordinate system sigma G, it may be how determined. In the present embodiment, the ground coordinate system sigma G, oriented magnetic poles north y-axis, z-axis defined as facing upward vertical.
Thus, when expressed in the device coordinate system sigma S, geomagnetism Bg changes the direction in conjunction with the portable device 1 posture mu, expressed as a constant magnitude of the vector S Bg (mu) (Note that the vector accompanied shown in the upper left of a code letter "S", the vector means that the vector represented by the device coordinate system sigma S). Therefore, based on the vector S Bg (mu) representing the geomagnetism Bg in the device coordinate system sigma S, it can be determined orientation of the portable device 1 mu.
On the other hand, the portable device 1 on which the three-dimensional magnetic sensor 70 is mounted is often provided with components that generate a magnetic field, such as various magnetized metals and electric circuits. Therefore, the vector data (magnetic data q) output from the three-dimensional magnetic sensor 70 is obtained by adding a vector representing the geomagnetism Bg and a vector representing the magnetic field (internal magnetic field Bi) generated by the component mounted on the mobile device 1. It becomes a vector. Therefore, to calculate a vector S Bg (mu) representing the geomagnetism Bg in equipment coordinate system sigma S, in order to obtain the geomagnetism Bg direction as viewed from the portable device 1 correctly, the device coordinate system sigma S, 3-dimensional magnetic A correction process for subtracting the vector S Bi representing the internal magnetic field Bi generated by the component of the portable device 1 from the coordinates indicated by the magnetic data q output from the sensor is required.
In this way, in order to specify the correct orientation of the geomagnetism Bg that is the detection target, the vector S Bi representing the internal magnetic field Bi that is removed from the magnetic data q output from the three-dimensional magnetic sensor 70 in the correction process is represented by 3 This is called an offset of the dimensional magnetic sensor 70.

3次元加速度センサ80は、X軸加速度センサ81、Y軸加速度センサ82、及びZ軸加速度センサ83を備える。各センサは、ピエゾ抵抗型、静電容量型、熱検知型などのような検知方式であってもよい。加速度センサI/F84は、各センサからの出力信号をAD変換して加速度データaを出力する。この加速度データaは、機器座標系Σ(厳密には、3次元加速度センサ80に固定された座標系)における慣性力と重力との合力を、x軸、y軸及びz軸の3成分を有するベクトルとして示すデータである。従って、携帯機器1が静止状態または等速直線運動状態にあれば、加速度データaは、機器座標系Σにおいて重力加速度の大きさと方向とを示すベクトルデータとなる。 The three-dimensional acceleration sensor 80 includes an X-axis acceleration sensor 81, a Y-axis acceleration sensor 82, and a Z-axis acceleration sensor 83. Each sensor may be a detection method such as a piezoresistive type, a capacitance type, or a heat detection type. The acceleration sensor I / F 84 AD-converts output signals from each sensor and outputs acceleration data a. This acceleration data a is obtained from the resultant force of inertial force and gravity in the device coordinate system Σ S (strictly, the coordinate system fixed to the three-dimensional acceleration sensor 80), and the three components of the x-axis, y-axis, and z-axis. It is data shown as a vector having. Accordingly, the portable device 1 if stationary or constant velocity linear motion state, the acceleration data a is a vector data indicating the magnitude and direction of gravitational acceleration in the device coordinate system sigma S.

3次元角速度センサ90は、X軸角速度センサ91、Y軸角速度センサ92、及びZ軸角速度センサ93を備える。角速度センサI/F94は、各センサからの出力信号をAD変換して角速度データgを出力する。角速度データgは、機器座標系Σ(厳密には、3次元角速度センサ90に固定された座標系)の各軸の回りの角速度を示すベクトルデータである。 The three-dimensional angular velocity sensor 90 includes an X-axis angular velocity sensor 91, a Y-axis angular velocity sensor 92, and a Z-axis angular velocity sensor 93. The angular velocity sensor I / F 94 AD-converts output signals from the sensors and outputs angular velocity data g. The angular velocity data g is vector data indicating the angular velocity around each axis of the device coordinate system Σ S (strictly, the coordinate system fixed to the three-dimensional angular velocity sensor 90).

CPU10は、ROM30に格納されている状態推定プログラム100を実行することによって、携帯機器1の姿勢や3次元磁気センサ70のオフセット等のシステムの状態を表す複数の物理量を推定する。すなわち、携帯機器1は、CPU10が状態推定プログラム100を実行することにより、状態推定装置として機能する。   The CPU 10 estimates a plurality of physical quantities representing the system state such as the attitude of the mobile device 1 and the offset of the three-dimensional magnetic sensor 70 by executing the state estimation program 100 stored in the ROM 30. That is, the portable device 1 functions as a state estimation device when the CPU 10 executes the state estimation program 100.

図3は、状態推定装置のうち、CPU10が状態推定プログラム100を実行することにより実現される機能を表す、機能ブロック図である。
図3に示すように、状態推定装置は、互いに異なる複数の初期ベクトルINIを出力する初期値生成部200、並列に動作する複数のカルマンフィルタを用いて並列的に非線形カルマンフィルタの演算を実行し複数の状態ベクトルxを出力するカルマンフィルタ演算部300、カルマンフィルタ演算部300が出力する複数の状態ベクトルxから1つの状態ベクトルxを選択してこれを出力する出力情報制御部400、及び、出力情報制御部400が出力する1つの状態ベクトルxに基づいて出力情報を生成する出力情報生成部500を備える。
FIG. 3 is a functional block diagram showing functions realized by the CPU 10 executing the state estimation program 100 in the state estimation device.
As shown in FIG. 3, the state estimation apparatus executes an operation of a nonlinear Kalman filter in parallel using an initial value generation unit 200 that outputs a plurality of different initial vectors INI and a plurality of Kalman filters that operate in parallel. A Kalman filter operation unit 300 that outputs a state vector x, an output information control unit 400 that selects and outputs one state vector x from a plurality of state vectors x output by the Kalman filter operation unit 300, and an output information control unit 400 Is provided with an output information generation unit 500 that generates output information based on one state vector x output from the.

本実施形態において、カルマンフィルタ部300は、4個のカルマンフィルタKFを備える。各々のカルマンフィルタKFは、非線形カルマンフィルタの演算を行う。
詳細は後述するが、非線形カルマンフィルタの演算とは、状態推定装置が推定するシステムの状態を表すベクトルである状態ベクトルxと、状態推定装置が備えるセンサからの出力値を要素とするベクトルである観測値ベクトルyと、を用いて算出される観測残差zに基づいて、状態ベクトルxを周期的に更新することにより、システムの状態を推定する演算である。なお、状態ベクトルxは、初期ベクトルINIを初期値とする。
以下では、説明の便宜上、4個のカルマンフィルタKFを区別する場合、4個のカルマンフィルタのそれぞれを、KF[1]、KF[2]、KF[3]、KF[4]と表記する。また、4個のカルマンフィルタの中で、第m番目(mは、1≦m≦4を満たす自然数)のカルマンフィルタを、KF[m]と表記する場合がある。
4個のカルマンフィルタKFの各々は、非線カルマンフィルタの演算を実行することで算出される状態ベクトルxと、観測残差zとを出力する。
In the present embodiment, the Kalman filter unit 300 includes four Kalman filters KF. Each Kalman filter KF performs a nonlinear Kalman filter operation.
Although the details will be described later, the calculation of the nonlinear Kalman filter is an observation that is a vector having as elements the state vector x that represents the state of the system estimated by the state estimation device and the output value from the sensor provided in the state estimation device. This is an operation for estimating the state of the system by periodically updating the state vector x based on the observation residual z calculated using the value vector y. The state vector x has an initial vector INI as an initial value.
Hereinafter, for the sake of convenience of explanation, when the four Kalman filters KF are distinguished, each of the four Kalman filters is represented as KF [1], KF [2], KF [3], and KF [4]. Of the four Kalman filters, the m-th (m is a natural number satisfying 1 ≦ m ≦ 4) Kalman filter may be expressed as KF [m].
Each of the four Kalman filters KF outputs a state vector x calculated by executing a nonlinear Kalman filter operation and an observation residual z.

ここで、状態ベクトルxとは、複数の状態変数を要素とするベクトルである。状態ベクトルxの要素である複数の状態変数の各々は、それぞれ、非線形カルマンフィルタが推定するシステムの状態を示す物理量を表す。
本実施形態は、状態ベクトルxの要素(状態変数)として、携帯機器1の姿勢μ、地磁気の強さr、地磁気の伏角φ、携帯機器1の角速度ω、3次元角速度センサ90のオフセット推定値gOFF、及び、3次元磁気センサ70のオフセット推定値qOFFを採用し、これらを非線形カルマンフィルタの演算における推定の対象とする。
時刻T=kにおける状態ベクトルxは、以下の式(1)で表される。各状態変数の右下に付された添え字「k」は、当該状態変数が時刻T=kにおける値であることを表す。なお、以下では、各種変数、ベクトル、行列の右下に添え字「k」を付すことで、当該変数、ベクトル、行列等が時刻T=kにおける値であることを示す場合がある。

Figure 2013185898
Here, the state vector x is a vector having a plurality of state variables as elements. Each of the plurality of state variables that are elements of the state vector x represents a physical quantity indicating the state of the system estimated by the nonlinear Kalman filter.
In this embodiment, as the elements (state variables) of the state vector x, the attitude μ of the mobile device 1, the geomagnetic strength r, the geomagnetic dip angle φ, the angular velocity ω of the mobile device 1, and the offset estimation value of the three-dimensional angular velocity sensor 90. g OFF and the estimated offset value q OFF of the three-dimensional magnetic sensor 70 are adopted, and these are used as estimation targets in the nonlinear Kalman filter calculation.
The state vector x k at time T = k is expressed by the following equation (1). The subscript “k” attached to the lower right of each state variable indicates that the state variable is a value at time T = k. In the following description, the subscript “k” may be added to the lower right of various variables, vectors, and matrices to indicate that the variables, vectors, matrices, etc. are values at time T = k.
Figure 2013185898

ここで、地磁気の強さrはスカラーであり、地磁気の伏角φはスカラーであり、角速度ωは3次元ベクトルであり、3次元角速度センサ90のオフセット推定値gOFFは3次元ベクトルであり、3次元磁気センサ70のオフセット推定値qOFFは3次元ベクトルである。
また、姿勢μは、クォータニオンを用いて表現される。クォータニオンとは、物体の姿勢(回転状態)を表す4次元数である。例えば、機器座標系Σの各軸と、地上座標系Σの各軸とが一致する姿勢μを「基準姿勢」と定義し、基準姿勢をμ=(0、0、0、1)と表現する。このとき、携帯機器1の任意の姿勢μは、単位ベクトルρを回転軸とし、単位ベクトルρの示す方向から見て、基準姿勢を角度ψだけ反時計回りに回転した姿勢として表現できる。当該姿勢μは、クォータニオンを用いて、式(2)で表される。

Figure 2013185898
Here, the geomagnetism strength r is a scalar, the geomagnetic dip angle φ is a scalar, the angular velocity ω is a three-dimensional vector, the offset estimated value g OFF of the three-dimensional angular velocity sensor 90 is a three-dimensional vector, 3 The estimated offset value q OFF of the three-dimensional magnetic sensor 70 is a three-dimensional vector.
In addition, the posture μ is expressed using quaternions. A quaternion is a four-dimensional number that represents the posture (rotation state) of an object. For example, a posture μ in which each axis of the device coordinate system Σ S and each axis of the ground coordinate system Σ G coincide is defined as a “reference posture”, and the reference posture is μ = (0, 0, 0, 1). Express. At this time, an arbitrary posture μ of the mobile device 1 can be expressed as a posture rotated counterclockwise by an angle ψ when viewed from the direction indicated by the unit vector ρ with the unit vector ρ as a rotation axis. The posture μ is expressed by Equation (2) using a quaternion.
Figure 2013185898

また、観測値ベクトルyとは、3次元磁気センサ70から出力される磁気データq、3次元加速度センサ80から出力される加速度データa、及び、3次元角速度センサ90から出力される角速度データgを要素とするベクトルである。時刻T=kにおける観測値ベクトルyは式(3)で与えられる。

Figure 2013185898
The observed value vector y includes magnetic data q output from the three-dimensional magnetic sensor 70, acceleration data a output from the three-dimensional acceleration sensor 80, and angular velocity data g output from the three-dimensional angular velocity sensor 90. It is a vector as an element. Observation value vector y k at time T = k is given by equation (3).
Figure 2013185898

各々のカルマンフィルタKFは、非線形カルマンフィルタの演算を実行し、当該カルマンフィルタKFが有する状態ベクトルxの各要素が真値に近づくように状態ベクトルxを周期的に更新することで、システムの状態を表す複数の物理量を推定する。
ここで、「真値」とは、状態ベクトルxの各要素に対応する実際の物理量を表す値である。また、以下では、状態ベクトルxの各要素を真値としたベクトルを、「状態ベクトルの真値」と称する。なお、非線形カルマンフィルタの演算の詳細については、後述する。
説明の便宜上、以下では、第m番目のカルマンフィルタKF[m]が有する状態ベクトルxに、符号[m]を付す場合がある。また、当該第m番目のカルマンフィルタKF[m]が非線形カルマンフィルタの演算で用いる各種行列、ベクトル等についても、符号[m]を付して表現する場合がある。
なお、詳細は後述するが、本実施形態では、各々のカルマンフィルタKFが更新する状態ベクトルxとは、厳密には、更新後の状態ベクトルx である。
Each Kalman filter KF executes a nonlinear Kalman filter operation and periodically updates the state vector x so that each element of the state vector x of the Kalman filter KF has a true value, thereby representing a plurality of system states. Estimate the physical quantity of.
Here, the “true value” is a value representing an actual physical quantity corresponding to each element of the state vector x k . Hereinafter, a vector in which each element of the state vector x k is a true value is referred to as a “true value of the state vector”. Details of the operation of the nonlinear Kalman filter will be described later.
For convenience of explanation, in the following description, the code [m] may be attached to the state vector x k of the mth Kalman filter KF [m]. Further, various matrices, vectors, and the like used by the m-th Kalman filter KF [m] in the calculation of the nonlinear Kalman filter may be expressed with the symbol [m].
Although details will be described later, in this embodiment, the state vector x k updated by each Kalman filter KF is strictly the updated state vector x + k .

初期値生成部200は、ROM30に格納された設定情報(具体的には、後述する情報Pobj、位置情報と地磁気の強さ及び伏角とを対応づけた情報、等)、GPS部60が出力する位置情報Ps、カメラ110が出力する画像情報Img等に基づいて、互いに異なる4個の初期ベクトルINI[1]〜INI[4]を生成し、これらを出力する。
4個の初期ベクトルINI[1]〜INI[4]は、それぞれ、4個のカルマンフィルタKF[1]〜KF[4]に供給され、各カルマンフィルタKFが非線形カルマンフィルタの演算を実行する際に使用する状態ベクトルxの初期値として採用される。すなわち、初期ベクトルINI[m]は、状態ベクトルxの初期値、つまり時刻T=0における状態ベクトルxである。
The initial value generation unit 200 outputs setting information stored in the ROM 30 (specifically, information Pobj described later, information in which position information is associated with geomagnetic strength and inclination), and the GPS unit 60 outputs the setting information. Based on the position information Ps, the image information Img output from the camera 110, and the like, four different initial vectors INI [1] to INI [4] are generated and output.
The four initial vectors INI [1] to INI [4] are supplied to the four Kalman filters KF [1] to KF [4], respectively, and are used when each Kalman filter KF executes the operation of the nonlinear Kalman filter. Adopted as the initial value of the state vector x. That is, the initial vector INI [m] is the initial value of the state vector x k , that is, the state vector x 0 at time T = 0.

第m番目のカルマンフィルタKF[m]に供給される初期ベクトルINI[m]は、携帯機器1の姿勢μ[m]の初期値μ[m](初期姿勢推定値)、地磁気の強さr[m]の初期値r[m]、地磁気の伏角φ[m]の初期値φ[m]、携帯機器1の角速度ω[m]の初期値ω[m]、3次元角速度センサ90のオフセット推定値gOFF[m]の初期値gOFF,0[m]、及び3次元磁気センサ70のオフセット推定値qOFF[m]の初期値qOFF,0[m]を要素として含む。この初期ベクトルINI[m]は、以下の式(4)により示される。
なお、初期ベクトルINI[m]の各要素の生成方法については、後述する。

Figure 2013185898
The initial vector INI [m] supplied to the m-th Kalman filter KF [m] is an initial value μ 0 [m] (initial posture estimated value) of the posture μ [m] of the mobile device 1, and the geomagnetism strength r. Initial value r 0 [m] of [m], initial value φ 0 [m] of geomagnetic dip angle φ [m], initial value ω 0 [m] of angular velocity ω [m] of portable device 1, three-dimensional angular velocity sensor The initial value g OFF, 0 [m] of the 90 estimated offset value g OFF [m] and the initial value q OFF, 0 [m] of the estimated offset value q OFF [m] of the three-dimensional magnetic sensor 70 are included as elements. . This initial vector INI [m] is expressed by the following equation (4).
A method for generating each element of the initial vector INI [m] will be described later.
Figure 2013185898

初期値生成部200は、画像処理部210、初期姿勢算出部220、及び、初期ベクトル生成部230を備える。
画像処理部210は、カメラ110の出力する画像情報Imgに基づいて、携帯機器1から見た物体Objの方向を機器座標系Σにおいて表した第1方向ベクトルαを算出する。初期姿勢算出部220は、GPS部60が出力する位置情報Ps、ROM30に格納された情報Pobj、及び、画像処理部210の出力する第1方向ベクトルαに基づいて、姿勢μの初期値μ[1]〜μ[4](初期姿勢推定値)を算出する。初期ベクトル生成部230は、初期姿勢算出部220が算出する姿勢μの初期値μ[1]〜μ[4]と、ROM30に格納された設定情報(具体的には、位置情報と地磁気の強さ及び伏角とを対応づけた情報)と、に基づいて、初期ベクトルINI[1]〜INI[4]を算出する。
The initial value generation unit 200 includes an image processing unit 210, an initial posture calculation unit 220, and an initial vector generation unit 230.
The image processing unit 210, based on image information Img output from the camera 110, and calculates the first direction vector α representing the direction of the object Obj viewed from the portable device 1 in the device coordinate system sigma S. The initial posture calculation unit 220 is based on the position information Ps output from the GPS unit 60, the information Pobj stored in the ROM 30, and the first direction vector α output from the image processing unit 210, and the initial value μ 0 of the posture μ. [1] to μ 0 [4] (initial posture estimated value) are calculated. The initial vector generation unit 230 includes initial values μ 0 [1] to μ 0 [4] of the posture μ calculated by the initial posture calculation unit 220 and setting information (specifically, position information and geomagnetism) stored in the ROM 30. The initial vectors INI [1] to INI [4] are calculated on the basis of the information obtained by associating the strength and the dip angle with each other.

出力情報制御部400は、4個のカルマンフィルタKF[1]〜KF[4]からの出力値に基づいて、4個のカルマンフィルタKF[1]〜KF[4]の中で、推定精度が最も高いカルマンフィルタKF[Sel]を選択する。そして出力情報制御部400は、選択したカルマンフィルタKF[Sel]が出力する状態ベクトルx[Sel]を、出力情報生成部500に対して供給する。 The output information control unit 400 has the highest estimation accuracy among the four Kalman filters KF [1] to KF [4] based on the output values from the four Kalman filters KF [1] to KF [4]. Select the Kalman filter KF [Sel]. Then, the output information control unit 400 supplies the output information generation unit 500 with the state vector x k [Sel] output from the selected Kalman filter KF [Sel].

なお、カルマンフィルタKFの推定精度とは、カルマンフィルタKFがシステムの状態をどの程度正確に推定しているかについて表す指標であり、具体的には、状態ベクトルxの示す値と状態ベクトルの真値との誤差の大きさに基づいた値(誤差評価値)である。そして、カルマンフィルタKFの推定精度が高い状態とは、状態ベクトルxの示す値と状態ベクトルの真値との誤差が小さい(つまり、誤差評価値が小さい)状態のことを意味する。
状態ベクトルxの示す値と状態ベクトルの真値との誤差が小さい場合(つまり、状態ベクトルxの各要素が真値に近い正確な値を示す場合)、当該状態ベクトルxを有するカルマンフィルタKFは、システムを正確に推定していると看做すことができる。
The estimation accuracy of the Kalman filter KF is an index representing how accurately the Kalman filter KF estimates the state of the system. Specifically, the value indicated by the state vector x k and the true value of the state vector This is a value (error evaluation value) based on the magnitude of the error. Then, the estimation accuracy of the Kalman filter KF is the high state, the error between the true value of the values and the state vector indicating the state vector x k is small (i.e., smaller error evaluation value) means that the state.
When the error between the value indicated by the state vector x k and the true value of the state vector is small (that is, when each element of the state vector x k indicates an accurate value close to the true value), the Kalman filter having the state vector x k KF can be regarded as accurately estimating the system.

出力情報制御部400は、4個のピークモニタPM[1]〜PM[4]、比較部410、及び、選択部420を備える。
第m番目のピークモニタPM[m]は、以下の式(5)に示すように、第m番目のカルマンフィルタKF[m]が出力する観測残差z[m]を、時刻T=k−τから時刻T=kまでの所定期間モニターし、当該期間における観測残差z[m]のノルムの最大値を、誤差評価値MAX[m]として出力する。

Figure 2013185898
The output information control unit 400 includes four peak monitors PM [1] to PM [4], a comparison unit 410, and a selection unit 420.
As shown in the following equation (5), the mth peak monitor PM [m] uses the observation residual z k [m] output from the mth Kalman filter KF [m] as time T = k−. Monitoring is performed for a predetermined period from τ 0 to time T = k, and the maximum value of the norm of the observation residual z k [m] in the period is output as the error evaluation value MAX z k [m].
Figure 2013185898

なお、本実施形態では、一定期間における観測残差z[m]のノルムの最大値を誤差評価値MAX[m]として採用するが、本発明はこのような形態に限定されるものではなく、観測残差z[m]を構成する複数の要素のうち、一部の要素から構成されるベクトルのノルムの所定期間における最大値を誤差評価値として採用してもよい。
詳細は後述するが、本実施形態に係る観測残差z[m]は、磁気データqに対応する要素、加速度データaに対応する要素、及び、角速度データgに対応する要素により構成されるベクトルである(式(52)参照)。この場合、ピークモニタPM[m]は、例えば、観測残差z[m]を構成する要素のうち、磁気データqに対応する要素について所定期間モニターし、当該要素のノルムの最大値を誤差評価値MAX[m]として採用してもよい。
In the present embodiment, the maximum value of the norm of the observation residual z k [m] in a certain period is adopted as the error evaluation value MAX z k [m]. However, the present invention is limited to such a form. Instead, the maximum value in a predetermined period of the norm of a vector composed of some of the plurality of elements constituting the observation residual z k [m] may be adopted as the error evaluation value.
Although details will be described later, the observation residual z k [m] according to the present embodiment is configured by an element corresponding to the magnetic data q, an element corresponding to the acceleration data a, and an element corresponding to the angular velocity data g. Vector (see equation (52)). In this case, the peak monitor PM [m] monitors, for example, elements corresponding to the magnetic data q among elements constituting the observation residual z k [m] for a predetermined period, and sets the maximum norm of the element as an error. it may be used as the evaluation value MAX z k [m].

比較部410は、4個のピークモニタPM[1]〜PM[4]がそれぞれ出力する誤差評価値MAX[1]〜MAX[4]のうち、最小となる誤差評価値MAX[Sel]に対応するカルマンフィルタKF[Sel]を示す選択値Selを出力する(但し、Selは、1≦Sel≦4を満たす自然数)。
前述のとおり、観測残差zは、状態ベクトルxと観測値ベクトルyとを用いて算出される値であり、観測残差zに基づいて、状態ベクトルxの示す値と状態ベクトルの真値との誤差の大きさを表すことができる。しかし、観測値ベクトルyの各要素が示す値は、ノイズ(例えば、各種センサの測定誤差)が重畳した値であり、時刻の経過と共に変動する値である。従って、観測残差zの各要素が示す値も、時刻の経過と共に変動する、ノイズが重畳した値である。
そこで、本実施形態に係る比較部410は、観測残差z[m]を所定期間モニターし、所定期間における観測残差z[m]のノルムの最大値を誤差評価値MAX[m]として採用し、誤差評価値MAX[m]を用いて、状態ベクトルxの示す値と状態ベクトルの真値との誤差の大きさを評価する。これにより、本実施形態に係る比較部410は、ノイズの影響を低減させて、状態ベクトルxの示す値と状態ベクトルの真値との誤差の大きさを正確に評価することができる。
The comparison unit 410 has a minimum error evaluation value MAX z among the error evaluation values MAX z k [1] to MAX z k [4] output by the four peak monitors PM [1] to PM [4]. The selected value Sel indicating the Kalman filter KF [Sel] corresponding to k [Sel] is output (where Sel is a natural number satisfying 1 ≦ Sel ≦ 4).
As described above, the observation residual z is a value calculated using the state vector x and the observation value vector y. Based on the observation residual z, the value indicated by the state vector x, the true value of the state vector, The magnitude of the error can be expressed. However, the value indicated by each element of the observed value vector y is a value on which noise (for example, measurement errors of various sensors) is superimposed, and is a value that varies with the passage of time. Therefore, the value indicated by each element of the observation residual z is also a value superimposed with noise that varies with the passage of time.
Therefore, the comparison unit 410 according to the present embodiment monitors the observation residual z k [m] for a predetermined period, and determines the maximum norm of the observation residual z k [m] in the predetermined period as the error evaluation value MAX z k [ m], and the error evaluation value MAX z k [m] is used to evaluate the magnitude of the error between the value indicated by the state vector x k and the true value of the state vector. Thus, comparing unit 410 according to this embodiment, by reducing the effect of noise, the magnitude of the error between the true value of the values and the state vector indicating the state vector x k can be accurately evaluated.

選択部420は、比較部410が出力する選択値Selに基づいて、カルマンフィルタKF[1]〜KF[4]が出力する状態ベクトルx[1]〜x[4]から、状態ベクトルx[Sel]を選択し、これを出力情報生成部500に対して供給する。 Selecting unit 420, based on the selection value Sel the comparison unit 410 outputs, from the Kalman filter KF [1] the state vector x k [1] ~KF to [4] is output ~x k [4], the state vector x k [Sel] is selected and supplied to the output information generation unit 500.

出力情報生成部500は、出力情報制御部400が出力する状態ベクトルx[Sel]に基づいて、地磁気Bgの向きや、携帯機器1の姿勢等の出力情報を算出する。 The output information generation unit 500 calculates output information such as the orientation of the geomagnetism Bg and the attitude of the mobile device 1 based on the state vector x k [Sel] output from the output information control unit 400.

[2. 初期ベクトルの生成]
上述のとおり、各カルマンフィルタKFが実行する非線形カルマンフィルタの演算とは、状態ベクトルxを、観測残差zに基づいて更新する演算である。より具体的には、非線形カルマンフィルタの演算とは、時刻T=k−1における状態ベクトルxk−1と、時刻T=kにおける観測値ベクトルyとに基づいて算出される観測残差zを用いて、時刻T=kにおける状態ベクトルxを推定する演算である。すなわち、時刻T=kにおける状態ベクトルxは、時刻T=k−1における状態ベクトルxk−1に基づいて算出される。換言すれば、状態ベクトルxは、初期状態(時刻T=0)から時刻T=k−1に至る全ての状態ベクトルx〜xk−1に基づいて算出される。
非線形カルマンフィルタの演算において、状態ベクトルxの各要素が、真値から乖離した値に更新された場合、その後、状態ベクトルxの各要素が真値に近い値に収束するまでに長時間を要することがあり、更には、状態ベクトルxの各要素が真値とは異なる不正確な値に収束することがある。この場合、状態推定装置はシステムの状態を正確に推定することはできない。従って、状態推定装置がシステムの状態を正確且つ迅速に推定するためには、状態ベクトルxの初期値(状態ベクトルx)である初期ベクトルINIの各要素を、真値に近い正確な値に設定することが望ましい。
そこで、本実施形態に係る初期値生成部200は、初期ベクトルINI[1]〜INI[4]のうち少なくとも1つの初期ベクトルINIの各要素が、真値に近い正確な値となるように、初期ベクトルINI[1]〜INI[4]を生成する。これにより、4個のカルマンフィルタKF[1]〜KF[4]のうち少なくとも1つのカルマンフィルタKFにより、システムの状態を正確に推定することが可能となる。
以下では、初期値生成部200における初期ベクトルINI[1]〜INI[4]の生成について詳述する。
[2. Initial vector generation]
As described above, the calculation of the nonlinear Kalman filter executed by each Kalman filter KF is an operation of updating the state vector x based on the observation residual z. More specifically, the calculation of the nonlinear Kalman filter is an observation residual z k calculated based on the state vector x k−1 at time T = k −1 and the observation value vector y k at time T = k. Is used to estimate the state vector x k at time T = k. That is, the state vector x k at time T = k is calculated based on the state vector x k−1 at time T = k−1. In other words, the state vector x k is calculated based on the initial state (time T = 0) at time T = all of the state vector x leading to k-1 0 ~x k-1 .
In the calculation of the nonlinear Kalman filter, when each element of the state vector x k is updated to a value deviating from the true value, it takes a long time until each element of the state vector x k converges to a value close to the true value. In addition, each element of the state vector x k may converge to an inaccurate value different from the true value. In this case, the state estimation device cannot accurately estimate the state of the system. Therefore, in order for the state estimation device to accurately and quickly estimate the state of the system, each element of the initial vector INI, which is the initial value of the state vector x k (state vector x 0 ), is an accurate value close to the true value. It is desirable to set to.
Therefore, the initial value generation unit 200 according to the present embodiment is configured so that each element of at least one initial vector INI out of the initial vectors INI [1] to INI [4] has an accurate value close to a true value. Initial vectors INI [1] to INI [4] are generated. As a result, the state of the system can be accurately estimated by at least one Kalman filter KF among the four Kalman filters KF [1] to KF [4].
Hereinafter, generation of initial vectors INI [1] to INI [4] in the initial value generation unit 200 will be described in detail.

[2.1. 姿勢の初期値について]
まず、初期ベクトルINI[m]のうち、携帯機器1の姿勢μ[m]の初期値μ[m]について検討する。
携帯機器1の姿勢μは、当該携帯機器1の利用者による携帯機器1の所持の仕方に依存して決定される。従って、仮に、姿勢μ[m]の初期値μ[m]を、事前に定められた1つの固定値(例えば、μ[m]=[0,0,0,1](基準姿勢))に定める場合、初期値μ[m]は真の姿勢(真値)から最大で180度ずれることになる。初期値μ[m]が真の姿勢(真値)から大きく乖離し、初期ベクトルINI[m]がシステムの状態を正確に表さない場合、状態推定装置はシステムの状態を正確に推定することはできない。
そこで、本実施形態では、画像情報Imgと位置情報Psとを用いることで、初期値μ[1]〜μ[4]のうち少なくとも1つの初期値μが真値に近い正確な値となるように、初期値μ[1]〜μ[4](初期姿勢推定値)を生成する。
以下において、初期値μ[1]〜μ[4]の生成方法を具体的に説明する。
[2.1. Initial posture values]
First, the initial value μ 0 [m] of the attitude μ [m] of the mobile device 1 in the initial vector INI [m] is examined.
The posture μ of the mobile device 1 is determined depending on how the user of the mobile device 1 holds the mobile device 1. Accordingly, suppose that the initial value μ 0 [m] of the posture μ [m] is set to one fixed value (for example, μ 0 [m] = [ 0 , 0 , 0 , 1] (reference posture)). ), The initial value μ 0 [m] is shifted from the true posture (true value) by 180 degrees at the maximum. When the initial value μ 0 [m] deviates greatly from the true posture (true value) and the initial vector INI [m] does not accurately represent the system state, the state estimation device accurately estimates the system state. It is not possible.
Therefore, in this embodiment, by using the image information Img and the position information Ps, the initial value μ 0 [1] ~μ 0 [ 4] at least one exact value close initial value mu 0 is the true value of the The initial values μ 0 [1] to μ 0 [4] (initial posture estimated values) are generated so that
Hereinafter, detailed explanation of the method of generating the initial value μ 0 [1] ~μ 0 [ 4].

まず、画像処理部210は、カメラ110が物体Objを撮影した際に出力する画像情報Imgに基づいて、第1方向ベクトルαを算出する。
ここで、第1方向ベクトルαとは、機器座標系Σにおいて、携帯機器1(厳密には、カメラ110)から見た物体Objの方向を表す3次元の単位ベクトルである。以下では、第1方向ベクトルαの算出方法の詳細について説明する。
First, the image processing unit 210 calculates the first direction vector α based on the image information Img output when the camera 110 captures the object Obj.
Here, the first direction vector alpha, in the device coordinate system sigma S, the portable device 1 (strictly speaking, the camera 110) is a three-dimensional unit vector representing the direction of the object Obj viewed from. Below, the detail of the calculation method of the 1st direction vector (alpha) is demonstrated.

カメラ110は、例えば、1以上のレンズと、当該1以上のレンズの光軸に垂直な平面である受光平面上にマトリックス状(またはハニカム状)に配列された複数のイメージセンサとを備える。カメラ110は、物体Objが発した光線(または、物体Objが反射した光線)を、レンズを通過させることで、受光平面上の一部の領域に集光させる。次に、カメラ110は、受光平面上の各々の位置の明るさを、複数のイメージセンサを用いて検出する。そして、カメラ110は、複数のイメージセンサの出力値に基づいて画像を構成するとともに、当該画像における物体Objの位置(2次元座標)である画像情報Imgを生成する。
本実施形態において、画像情報Imgの生成は、カメラ110にて行われるが、図3に示す画像処理部210にて行われてもよい。なお、表示部50は、物体Objの映された画像を表示することができる(図2参照)。従って、携帯機器1の利用者が操作部120介して、画像に映された物体Objを指定することで、画像情報Imgを生成してもよい。
The camera 110 includes, for example, one or more lenses and a plurality of image sensors arranged in a matrix (or honeycomb) on a light receiving plane that is a plane perpendicular to the optical axis of the one or more lenses. The camera 110 focuses the light beam emitted by the object Obj (or the light beam reflected by the object Obj) on a partial area on the light receiving plane by passing through the lens. Next, the camera 110 detects the brightness of each position on the light receiving plane using a plurality of image sensors. The camera 110 composes an image based on the output values of the plurality of image sensors, and generates image information Img that is the position (two-dimensional coordinates) of the object Obj in the image.
In the present embodiment, the generation of the image information Img is performed by the camera 110, but may be performed by the image processing unit 210 illustrated in FIG. In addition, the display part 50 can display the image in which the object Obj was reflected (refer FIG. 2). Accordingly, the user of the mobile device 1 may generate the image information Img by specifying the object Obj shown in the image via the operation unit 120.

ここで、簡単のために凸レンズを例に挙げて、レンズを通過する光の動きについて説明する。
レンズの一般的な性質として、レンズの中心を通過する光は、レンズの通過後もその方向を変えずに直進する。また、レンズの焦点を通過する光は、レンズを通過後に、レンズの光軸と平行な光となる。他方、レンズの光軸に平行な光は、レンズを通過後に、レンズの焦点を通過する。このようなレンズの光学的性質を利用することで、点光源の発する光をレンズにより1点(像点)に集光させた場合の結像位置に基づいて、レンズから見た当該光の入射方向を算出することができる。
より具体的には、理想的な凸レンズにおいて、レンズの中心を通る光の経路を表す直線と受光平面との交点が像点となるため、レンズの中心を像点から表したベクトルと、当該光の入射方向を表すベクトルとは、平行となる。また、画像情報Imgは、受光平面上の像点の位置であるので、画像情報Imgに基づいて、レンズの中心を像点から表したベクトルを求めることもできる。よって、画像情報Imgに基づいて、当該光の入射方向を求めることが可能となる。
また、レンズの収差を考慮する場合、或いは、カメラ110が複数のレンズを備える場合であっても、受光平面上の像点の位置と、レンズに入射する光の入射方向とは、1対1に対応する。従って、仮に、レンズの中心を像点から表したベクトルと、当該光の入射方向とを表すベクトルとが、平行とならない場合であっても、ROM30或いはRAM20上に、受光平面上の像点の位置(画像情報Img)と、レンズに入射する光の入射方向とを、対応付けて記憶したルックアップテーブルを設けることにより、画像情報Imgに基づいて、レンズの中心から見た当該光の入射方向とを表すベクトルを求めることが可能となる。
なお、画像情報Imgは、受光平面上の像点の位置の他に、レンズの中心と受光平面との間の距離を含むものであってもよい。受光平面上の像点の位置の他に、受光平面とレンズとの距離を画像情報Imgに含ませることで、受光平面をレンズから遠ざける場合或いは近づける場合であっても、画像情報Imgに基づいて、レンズから見た光の入射方向を算出することが可能となる。
このように、物体Objをカメラ110で撮影した際に出力される画像情報Imgに基づいて、カメラ110から見た物体Objの方向を算出することができる。なお、レンズの光軸は、機器座標系Σにおいて一定の方向を向く。従って、画像処理部210は、画像情報Imgに基づいて、携帯機器1から見た物体Objの方向、すなわち、機器座標系Σにおいて表した第1方向ベクトルαを算出することができる。
Here, for the sake of simplicity, taking a convex lens as an example, the movement of light passing through the lens will be described.
As a general property of a lens, light passing through the center of the lens travels straight without changing its direction after passing through the lens. The light passing through the focal point of the lens becomes light parallel to the optical axis of the lens after passing through the lens. On the other hand, light parallel to the optical axis of the lens passes through the focal point of the lens after passing through the lens. By utilizing the optical properties of such a lens, the incident light seen from the lens is incident on the basis of the imaging position when the light emitted from the point light source is condensed at one point (image point) by the lens. The direction can be calculated.
More specifically, in an ideal convex lens, the intersection of the light receiving plane and the straight line representing the path of light passing through the center of the lens is the image point, so the vector representing the center of the lens from the image point and the light The vector representing the incident direction is parallel. Further, since the image information Img is the position of the image point on the light receiving plane, a vector representing the center of the lens from the image point can be obtained based on the image information Img. Therefore, the incident direction of the light can be obtained based on the image information Img.
Further, even when the lens aberration is taken into account, or even when the camera 110 includes a plurality of lenses, the position of the image point on the light receiving plane and the incident direction of light incident on the lens are 1: 1. Corresponding to Therefore, even if the vector representing the center of the lens from the image point and the vector representing the incident direction of the light are not parallel, the image point on the light receiving plane is stored on the ROM 30 or RAM 20. By providing a lookup table that stores the position (image information Img) and the incident direction of light incident on the lens in association with each other, the incident direction of the light viewed from the center of the lens based on the image information Img It is possible to obtain a vector representing.
Note that the image information Img may include the distance between the center of the lens and the light receiving plane in addition to the position of the image point on the light receiving plane. In addition to the position of the image point on the light receiving plane, the distance between the light receiving plane and the lens is included in the image information Img, so that even if the light receiving plane is moved away from or closer to the lens, it is based on the image information Img. The incident direction of light viewed from the lens can be calculated.
In this manner, the direction of the object Obj viewed from the camera 110 can be calculated based on the image information Img output when the object Obj is captured by the camera 110. The optical axis of the lens faces a fixed direction in the instrument coordinate system sigma S. Accordingly, the image processing unit 210, based on image information Img, direction of the object Obj viewed from the portable device 1, i.e., it is possible to calculate the first direction vector α expressed in device coordinates sigma S.

図3に示すように、初期姿勢算出部220は、撮影対象情報取得部221と、姿勢計算部222とを備える。撮影対象情報取得部221は、GPS部60が出力する位置情報Psと、地上座標系Σにおける物体Objの座標と、に基づいて第2方向ベクトルβを算出する。姿勢計算部222は、第1方向ベクトルα及び第2方向ベクトルβに基づいて、携帯機器1の姿勢μの初期値μ[1]〜μ[4]を算出する。
ここで、第2方向ベクトルβとは、地上座標系Σにおいて、携帯機器1から見た物体Objの方向を表す3次元の単位ベクトルである。
As shown in FIG. 3, the initial posture calculation unit 220 includes a shooting target information acquisition unit 221 and a posture calculation unit 222. Photographing object information acquisition unit 221 calculates the position information Ps of GPS unit 60 outputs the coordinates of the object Obj of the ground coordinate system sigma G, the second direction vector β based on. The posture calculation unit 222 calculates initial values μ 0 [1] to μ 0 [4] of the posture μ of the mobile device 1 based on the first direction vector α and the second direction vector β.
Here, the second direction vector beta, in ground coordinate system sigma G, a three-dimensional unit vector representing the direction of the object Obj viewed from the portable device 1.

なお、本実施形態では、物体Objは、地上座標系Σにおける座標が既知のランドマークである。ここで、ランドマークとは、日本各地(或いは世界各地)に存在する建造物、日本各地(或いは世界各地)に存在する地形等である。なお、ランドマークは、建造物等に備え付けられた光源であってもよい。
ROM30には、物体Objの候補となり得る複数のランドマークの各々についての情報Pobjを記憶したルックアップテーブルLUT1が格納される。ここで、情報Pobjの具体的な内容は、各ランドマークの位置を特定するための、経度、緯度、高度等の情報である。なお、情報Pobjは、各ランドマークの形状に関する情報を含んでもよい。また、本実施形態は、情報Pobjを、ROM30に格納されたルックアップテーブルLUT1に記憶するが、情報Pobjを、携帯機器1の外部から通信部40を介して都度取得し、これをRAM20に格納してもよい。
撮影対象情報取得部221は、ルックアップテーブルLUT1を参照して、カメラ110が撮影した物体Objについての情報Pobjを取得する。そして、撮影対象情報取得部221は、情報Pobjに基づいて、地上座標系Σにおける当該物体Objの座標を算出するとともに、携帯機器1の位置情報Psに基づいて、地上座標系Σにおける携帯機器1の座標を算出する。その後、撮影対象情報取得部221は、地上座標系Σにおける当該物体Objの座標から、地上座標系Σにおける携帯機器1の座標を減算することにより、第2方向ベクトルβを算出する。
なお、本実施形態において、位置情報Psには、携帯機器1の緯度及び経度が含まれるが、位置情報Psが、携帯機器1の高度を含むものであってもよい。この場合、第2方向ベクトルβをより正確に算出することが可能となる。
In the present embodiment, the object Obj is coordinates in ground coordinate system sigma G is a known landmark. Here, the landmark is a building that exists in various parts of Japan (or around the world), or a landform that exists in various parts of Japan (or around the world). The landmark may be a light source provided in a building or the like.
The ROM 30 stores a lookup table LUT1 that stores information Pobj about each of a plurality of landmarks that can be candidates for the object Obj. Here, the specific content of the information Pobj is information such as longitude, latitude, and altitude for specifying the position of each landmark. Note that the information Pobj may include information regarding the shape of each landmark. In this embodiment, the information Pobj is stored in the lookup table LUT1 stored in the ROM 30, but the information Pobj is acquired from the outside of the portable device 1 via the communication unit 40 every time and stored in the RAM 20. May be.
The imaging target information acquisition unit 221 refers to the lookup table LUT1 and acquires information Pobj about the object Obj captured by the camera 110. The imaging target information acquiring unit 221, based on the information Pobj, calculates the coordinates of the object Obj of the ground coordinate system sigma G, based on the position information Ps of the portable device 1, a mobile in the ground coordinate system sigma G The coordinates of the device 1 are calculated. Thereafter, photographing object information acquiring unit 221, from the coordinates of the object Obj of the ground coordinate system sigma G, by subtracting the coordinates of the portable device 1 in the ground coordinate system sigma G, to calculate the second direction vector beta.
In the present embodiment, the position information Ps includes the latitude and longitude of the mobile device 1, but the position information Ps may include the altitude of the mobile device 1. In this case, the second direction vector β can be calculated more accurately.

本実施形態では、携帯機器1の利用者が、複数のランドマークから、実際にカメラ110が撮影する物体Objを選択する。
但し、本発明はこのような態様に限定されるものではなく、撮影対象情報取得部221が、位置情報Psと情報Pobjとに基づいて、実際にカメラ110が撮影した物体Objを特定してもよい。
また、CPU10が状態推定プログラム100を実行する際、CPU10は、位置情報Psと情報Pobjとに基づいて、複数のランドマークの中から携帯機器1の利用者が撮影可能な物体Obj(例えば、携帯機器1の近傍に存在するランドマーク)を選択し、当該物体Objを撮影するように促すメッセージを、表示部50に表示してもよい。この場合、CPU10は、位置情報Psと情報Pobjとに基づいて、利用者から見た物体Objの方角を算出し、これを表示部50に表示するものであってもよい。
In the present embodiment, the user of the mobile device 1 selects an object Obj actually captured by the camera 110 from a plurality of landmarks.
However, the present invention is not limited to such an embodiment, and the imaging target information acquisition unit 221 may identify the object Obj actually captured by the camera 110 based on the position information Ps and the information Pobj. Good.
Further, when the CPU 10 executes the state estimation program 100, the CPU 10 is based on the position information Ps and the information Pobj, and the object Obj (for example, a portable object) that can be photographed by the user of the portable device 1 from a plurality of landmarks. A message that prompts the user to select a landmark present in the vicinity of the device 1 and shoot the object Obj may be displayed on the display unit 50. In this case, the CPU 10 may calculate the direction of the object Obj viewed from the user based on the position information Ps and the information Pobj and display it on the display unit 50.

次に、姿勢計算部222は、第1方向ベクトルα及び第2方向ベクトルβに基づいて、携帯機器1の姿勢μの初期値μ[1]〜μ[4]を算出する。
以下では、第1方向ベクトルα及び第2方向ベクトルβに基づいて、初期値μ[1]〜μ[4]を生成する方法について、具体的に説明する。
Next, the posture calculation unit 222 calculates initial values μ 0 [1] to μ 0 [4] of the posture μ of the mobile device 1 based on the first direction vector α and the second direction vector β.
Hereinafter, a method for generating the initial values μ 0 [1] to μ 0 [4] based on the first direction vector α and the second direction vector β will be specifically described.

段落[0032]において記したとおり、物体の任意の姿勢は、単位ベクトルρを回転軸として、基準姿勢を角度ψだけ回転した姿勢として表現できる。また、単位ベクトルρを回転軸とし、単位ベクトルρの示す方向から見て角度ψだけ反時計回りに回転させる3行3列の回転行列R(ρ,ψ)は、以下の式(6)で表される(ロドリゲスの公式)。従って、物体の任意の姿勢は、クォータニオンの代わりに、回転行列R(ρ,ψ)を用いて表現することもできる。ここで、式(6)に現れる[ρ×]は3行3列の行列であり、単位ベクトルρを式(7)で表した場合、[ρ×]は式(8)により表される。
なお、携帯機器1の姿勢が基準姿勢であるとき、機器座標系Σと地上座標系Σとが一致する一方、携帯機器1の姿勢が回転行列R(ρ,ψ)で表される場合には、機器座標系Σと地上座標系Σとの関係も、回転行列R(ρ,ψ)により表現される。具体的には、携帯機器1の姿勢を回転行列R(ρ,ψ)で表した場合、回転行列R(ρ,ψ)は、地上座標系Σのx軸、y軸、及びz軸を機器座標系Σから表した3つの単位ベクトルを、それぞれ、第1列、第2列、第3列に並べた行列となる。

Figure 2013185898
As described in paragraph [0032], an arbitrary posture of the object can be expressed as a posture rotated by an angle ψ with the unit vector ρ as a rotation axis. Further, a rotation matrix R (ρ, ψ) of 3 rows and 3 columns that is rotated counterclockwise by an angle ψ when viewed from the direction indicated by the unit vector ρ, with the unit vector ρ as a rotation axis is expressed by the following equation (6) Expressed (Rodriguez's formula). Therefore, an arbitrary posture of the object can be expressed by using the rotation matrix R (ρ, ψ) instead of the quaternion. Here, [ρ ×] appearing in Equation (6) is a 3 × 3 matrix, and when the unit vector ρ is expressed by Equation (7), [ρ ×] is expressed by Equation (8).
When the posture of the mobile device 1 is the reference posture, the device coordinate system Σ S and the ground coordinate system Σ G coincide with each other, while the posture of the mobile device 1 is represented by a rotation matrix R (ρ, ψ). the relationship between the device coordinate system sigma S and ground coordinate system sigma G is also represented by the rotation matrix R (ρ, ψ). Specifically, if representing the orientation of the portable device 1 in the rotation matrix R (ρ, ψ), the rotation matrix R (ρ, ψ) is, x-axis of the ground coordinate system sigma G, y-axis, and z-axis the three unit vectors expressed from the device coordinate system sigma S, respectively, first column, second column, a matrix arranged in the third column.
Figure 2013185898

以下では、携帯機器1の姿勢を回転行列により表現する場合、「姿勢A」等のように符号「A」を用いる。
ここで、式(9)に示すような、単位ベクトルρを回転軸として基準姿勢を単位ベクトルρの示す方向から見て反時計回りに角度ψだけ回転する回転行列R(ρ,ψ)によって表現される姿勢を、姿勢A(初期姿勢候補値)とする。そして、携帯機器1の姿勢がAのときに、第1方向ベクトルα及び第2方向ベクトルβが算出されたと仮定する。
この場合、単位ベクトルρは、第1方向ベクトルα及び第2方向ベクトルβを用いて、式(10)で表される。また、角度ψは、第1方向ベクトルα及び第2方向ベクトルβを用いて、式(11)で表される。

Figure 2013185898
In the following, when the posture of the mobile device 1 is expressed by a rotation matrix, the symbol “A” is used like “posture A”.
Here, as shown in Expression (9), a rotation matrix R (ρ C , C) that rotates the reference posture counterclockwise by an angle ψ C when viewed from the direction indicated by the unit vector ρ C with the unit vector ρ C as a rotation axis. Let the posture represented by (ψ C ) be the posture A C (initial posture candidate value). Then, it is assumed that the orientation of the mobile device 1 when the A C, the first direction vector α and the second direction vector β is calculated.
In this case, the unit vector ρ C is expressed by Expression (10) using the first direction vector α and the second direction vector β. The angle [psi C, using the first direction vector α and the second direction vector beta, represented by the formula (11).
Figure 2013185898

上述のとおり、回転行列R(ρ,ψ)は、機器座標系Σにおいて、地上座標系Σの3軸を表す3つの単位ベクトルを各列に並べた行列である。従って、回転行列R(ρ,ψ)は、地上座標系Σにおいて表現された任意の3次元ベクトルを、機器座標系Σにおいて表現するための座標変換行列という性質も有する。
よって、以下の式(12)に示すように、地上座標系Σにおいて表した第2方向ベクトルβを、回転行列R(ρ,ψ)によって変換することにより、携帯機器1から見た物体Objの方向、すなわち、機器座標系Σにおいて表した第1方向ベクトルαを算出することができる。

Figure 2013185898
As described above, the rotation matrix R (ρ, ψ) is in the device coordinate system sigma S, the three unit vectors representing the three-axis terrestrial coordinate system sigma G is a matrix arranged in each column. Therefore, the rotation matrix R (ρ, ψ) may have any three-dimensional vector expressed in ground coordinate system sigma G, also property of the coordinate transformation matrix for representing the device coordinate system sigma S.
Therefore, as shown in the following equation (12), the second direction vector β expressed in ground coordinate system sigma G, by converting the rotation matrix R ([rho, [psi), the object viewed from the portable device 1 Obj direction, i.e., it is possible to calculate the first direction vector α expressed in device coordinates sigma S.
Figure 2013185898

ところで、第1方向ベクトルα及び第2方向ベクトルβが算出された場合であっても、携帯機器1の姿勢を一意に特定することはできない。すなわち、式(9)〜式(11)により、第1方向ベクトルα及び第2方向ベクトルβに基づいて姿勢Aを算出しても、当該姿勢Aは、携帯機器1の姿勢を正確に表さない可能性が高い。
図4(A)は、携帯機器1と物体Objとの位置関係を表す概念図である。なお、図4(A)では、便宜上、地上座標系Σの原点と、機器座標系Σ(機器座標系ΣS1、機器座標系ΣS2)の原点とが一致するように、地上座標系Σ及び機器座標系Σが設けられる場合を想定する。
図4(A)に示すように、携帯機器1の姿勢がAC1である場合に、携帯機器1と物体Objとを結ぶ直線AXを軸として、当該機器を任意の角度θだけ回転させた姿勢をAC2とする。このとき、姿勢AC1の携帯機器1に固定された機器座標系ΣS1から見た物体Objの方向と、姿勢AC2の携帯機器1に固定された機器座標系ΣS2から見た物体Objの方向とは、一致する。すなわち、携帯機器1の姿勢がAC1である場合に算出される第1方向ベクトルαと、携帯機器1の姿勢がAC2である場合に算出される第1方向ベクトルαとは、等しい。
また、第2方向ベクトルβは、地上座標系Σにおいて表されるベクトルである。よって、携帯機器1の姿勢が変化しても、携帯機器1の位置(位置情報Ps)が変化しない限りは、第2方向ベクトルβは一定である。すなわち、携帯機器1の姿勢がAC1である場合に算出される第2方向ベクトルβと、携帯機器1の姿勢がAC2である場合に算出される第2方向ベクトルβとは、等しい。
この場合、仮に、第1方向ベクトルα及び第2方向ベクトルβに基づいて姿勢AC1が算出された場合であっても、携帯機器1の真の姿勢は姿勢AC2かもしれない。すなわち、携帯機器1の姿勢がAC1のときに式(12)が成立すれば、携帯機器1の姿勢がAC2のときにも式(12)が成立する。
By the way, even if the first direction vector α and the second direction vector β are calculated, the posture of the mobile device 1 cannot be uniquely specified. That is, the equation (9) to (11), and calculate the position A C based on the first direction vector α and the second direction vector beta, the posture A C is exactly the attitude of the mobile device 1 There is a high possibility of not expressing.
FIG. 4A is a conceptual diagram illustrating the positional relationship between the mobile device 1 and the object Obj. In FIG. 4 (A), the convenience, as the origin of the ground coordinate system sigma G, and the origin of the instrument coordinate system sigma S (instrument coordinate system sigma S1, instrument coordinate system sigma S2) coincide, ground coordinate system Assume that Σ G and device coordinate system Σ S are provided.
As shown in FIG. 4 (A), when the orientation of the mobile device 1 is A C1, as an axis a line AX connecting the portable device 1 and the object Obj, rotated the device by an arbitrary angle θ attitude Is AC2 . At this time, the direction of the object Obj viewed from the device coordinate system sigma S1 fixed to the portable device 1 in position A C1, from the device coordinate system sigma S2 fixed to the portable device 1 in position A C2 of the object Obj viewed The direction matches. That is, the first direction vector α calculated when the attitude of the mobile device 1 is A C1 and the first direction vector α calculated when the attitude of the mobile device 1 is A C2 are equal.
Further, the second direction vector beta, is a vector represented in ground coordinate system sigma G. Therefore, even if the attitude of the mobile device 1 changes, the second direction vector β is constant as long as the position of the mobile device 1 (position information Ps) does not change. That is, the second direction vector β calculated when the attitude of the mobile device 1 is A C1 and the second direction vector β calculated when the attitude of the mobile device 1 is A C2 are equal.
In this case, even if the posture A C1 is calculated based on the first direction vector α and the second direction vector β, the true posture of the mobile device 1 may be the posture AC2 . That is, the posture of the mobile device 1 when satisfied Equation (12) when the A C1, also expression when the portable device 1 of the posture A C2 (12) is satisfied.

ここで、図4(B)に示すように、第2方向ベクトルβ(直線AX)を軸として任意の角度θだけ回転させる回転行列R(β,θ)を用いて姿勢Aの携帯機器1を回転させることを検討する。
上述のとおり、携帯機器1の姿勢がAのときに式(12)が成立する場合、姿勢Aの携帯機器1を回転行列R(β,θ)により回転させた場合にも式(12)が成立する。すなわち、式(12)が成立する場合には、以下の式(13)も同時に成立する。
ここで、式(14)に示すように、姿勢Aの携帯機器1を回転行列R(β,θ)により回転させた姿勢を「A」とする。この場合、式(15)に示すように、姿勢Aは、第1方向ベクトルα及び第2方向ベクトルβが算出された場合の、携帯機器1の姿勢の一般解を表す。

Figure 2013185898
Here, as shown in FIG. 4 (B), the portable device 1 in the second direction vector beta (linear AX) rotation matrix rotated by an arbitrary angle theta as the axis R (β, θ) using the attitude A C Consider rotating the.
As described above, when the posture of the mobile device 1 is satisfied Equation (12) when the A C, even when rotated by the posture A C rotation matrix R of the portable device 1 (beta, theta) formula (12 ) Holds. That is, when Expression (12) holds, the following Expression (13) also holds simultaneously.
Here, as shown in equation (14), the portable device 1 in position A C rotation matrix R (beta, theta) a posture is rotated by a "A". In this case, as shown in Expression (15), the posture A represents a general solution of the posture of the mobile device 1 when the first direction vector α and the second direction vector β are calculated.
Figure 2013185898

本実施形態に係る姿勢計算部222は、図4(B)に示すように、直線AX(第2方向ベクトルβ)を軸として、姿勢Aを(π/2)ずつ回転させることにより、姿勢A[1]〜A[4]を生成する。具体的には、式(16)に示すように、角度θを「0」に設定したときの姿勢をA[1]とする。姿勢A[1]と、姿勢Aとは等しい。次に、式(17)〜式(19)に示すように、角度θを、「π/2」、「π」、「(3π)/2」にそれぞれ設定して、3つの姿勢A[2]、A[3]、A[4]を生成する。
そして、姿勢計算部222は、行列で表された姿勢A[1]〜A[4]を、クォータニオンに変換することで、初期値μ[1]〜μ[4]を生成する。

Figure 2013185898
As shown in FIG. 4B, the posture calculation unit 222 according to the present embodiment rotates the posture AC by (π / 2) about the straight line AX (second direction vector β) as a posture. A [1] to A [4] are generated. Specifically, as shown in Expression (16), the posture when the angle θ is set to “0” is A [1]. A posture A [1], equal to the position A C. Next, as shown in Expression (17) to Expression (19), the angle θ is set to “π / 2”, “π”, and “(3π) / 2”, respectively, and the three postures A [2 ], A [3], A [4].
Then, the posture calculation unit 222, a posture A [1] ~A [4] expressed by a matrix, by converting the quaternion, to generate an initial value μ 0 [1] ~μ 0 [ 4].
Figure 2013185898

なお、3行3列の行列で表される姿勢Aから、クォータニオンで表される姿勢μへの変換は、公知の方法を適宜用いて行えば良い。
ここで、携帯機器1が姿勢μである場合に、地上座標系Σにおいて表現されたベクトルを、機器座標系Σで表現するための座標変換を行う行列B(μ)は、以下の式(20)で表すことができる。行列Aは、行列B(μ)の逆行列であるので、行列Aの各成分と行列B(μ)の逆行列の各成分とを比較することで、クォータニオンを用いて表される姿勢μの各要素を計算してもよい。また、例えば、以下の公知文献に記載された方法を用いて、行列Aから姿勢μを算出することもできる。
Malcolm D. Shuster and Gregory A. Natanson, “Quaternion Computation from a Geometric Point of View", The Journal of the Astronautical Sciences, Vol. 41, No. 4, October-December 1993, pp. 545-556.

Figure 2013185898
Note that the conversion from the posture A represented by the matrix of 3 rows and 3 columns to the posture μ represented by the quaternion may be performed using a known method as appropriate.
Here, when the portable device 1 is attitude mu, a vector expressed in ground coordinate system sigma G, matrix B for performing coordinate transformation for representing by the device coordinate system Σ S (μ) has the following formula (20). Since the matrix A is an inverse matrix of the matrix B (μ), by comparing each component of the matrix A and each component of the inverse matrix of the matrix B (μ), the posture μ represented by the quaternion is expressed. Each element may be calculated. Further, for example, the posture μ can be calculated from the matrix A by using a method described in the following publicly known document.
Malcolm D. Shuster and Gregory A. Natanson, “Quaternion Computation from a Geometric Point of View”, The Journal of the Astronautical Sciences, Vol. 41, No. 4, October-December 1993, pp. 545-556.
Figure 2013185898

以上のように、本実施形態に係る初期姿勢算出部220は、画像情報Imgと位置情報Psとを用いて、少なくとも1つが真値に近い値を示す初期値μ[1]〜μ[4]を生成することができる。 As described above, the initial posture calculation unit 220 according to the present embodiment uses the image information Img and the position information Ps, and at least one of the initial values μ 0 [1] to μ 0 [ 4] can be generated.

[2.2. 姿勢の初期値以外の値について]
地磁気の強さr[m]の初期値r[m]、及び地磁気の伏角φ[m]の初期値φ[m]は、例えば、GPS部60から供給される位置情報Psに基づいて生成することができる。これは、地球上の位置が特定できれば、その位置における地磁気の強さ及び伏角を知ることができるからである。具体的には、ROM30には、位置情報と地磁気の強さ及び伏角とを対応づけて記憶したルックアップテーブルLUT2が格納される。初期値生成部200は、ルックアップテーブルLUT2を参照して、位置情報Psに対応する地磁気の強さ及び伏角を、地磁気の強さr[m]の初期値r[m]及び地磁気の伏角φ[m]の初期値φ[m]として設定する。
[2.2. Regarding values other than the initial posture values]
The initial value r 0 [m] of the geomagnetic strength r [m] and the initial value φ 0 [m] of the geomagnetic depression angle φ [m] are based on, for example, the position information Ps supplied from the GPS unit 60. Can be generated. This is because if the position on the earth can be specified, the geomagnetic strength and the dip angle at that position can be known. Specifically, the ROM 30 stores a look-up table LUT2 that stores position information, geomagnetic strength, and dip angle in association with each other. The initial value generation unit 200 refers to the lookup table LUT2 and determines the geomagnetism strength and dip angle corresponding to the position information Ps, the initial value r 0 [m] of the geomagnetism strength r [m], and the geomagnetic dip angle. Set as the initial value φ 0 [m] of φ [m].

角速度ω[m]の初期値ω[m]は、例えば、携帯機器1が静止していることを仮定して、「0」に設定する。また、3次元角速度センサ90のオフセット推定値gOFF[m]の初期値gOFF,0[m]は、通常「0」近辺に調整されているため、「0」に設定する。 The initial value ω 0 [m] of the angular velocity ω [m] is set to “0” on the assumption that the mobile device 1 is stationary, for example. In addition, the initial value g OFF, 0 [m] of the offset estimated value g OFF [m] of the three-dimensional angular velocity sensor 90 is normally adjusted in the vicinity of “0”, so is set to “0”.

3次元磁気センサ70のオフセット推定値qOFF[m]の初期値qOFF,0[m]は、時刻T=0に3次元磁気センサ70から出力される磁気データq、地上座標系Σにおいて地磁気Bgを表したベクトルBg[m]、姿勢μ[m]の初期値μ[m]、及び、式(20)に示した行列B(μ)を用いて、以下に示す式(21)により算出される。なお、時刻T=0における地磁気Bgを地上座標系Σから表したベクトルBg[m]は、地磁気の強さr[m]の初期値r[m]と、地磁気の伏角φ[m]の初期値φ[m]とを用いて、以下の式(22)で表される。

Figure 2013185898
The initial value q OFF, 0 [m] of the estimated offset value q OFF [m] of the three-dimensional magnetic sensor 70 is the magnetic data q 0 output from the three-dimensional magnetic sensor 70 at time T = 0 , the ground coordinate system Σ G Using the vector G Bg [m] representing the geomagnetism Bg, the initial value μ 0 [m] of the posture μ [m], and the matrix B (μ) shown in the equation (20) ( 21). The time T = vector G Bg representing the geomagnetism Bg from the ground coordinate system sigma G at 0 [m] is the initial value r 0 [m] of the geomagnetic intensity r [m], geomagnetic dip phi [m ] Is represented by the following formula (22) using the initial value φ 0 [m].
Figure 2013185898

このように、初期値生成部200は、真値に近い値を示すものが少なくとも1個は含まれるように、互いに異なる4個の初期ベクトルINI[1]〜INI[4]を生成する。そして、カルマンフィルタ演算部300は、4個の初期ベクトルINI[1]〜INI[4]がそれぞれ供給される4個のカルマンフィルタKF[1]〜KF[4]を並列動作させる。
この場合、時刻T=0における状態ベクトルの真値に近い値を示す初期ベクトルINIが供給されて動作するカルマンフィルタKFは、システムの状態を正確に推定することが可能となる。
In this way, the initial value generation unit 200 generates four different initial vectors INI [1] to INI [4] so that at least one of the values that are close to the true value is included. Then, the Kalman filter operation unit 300 operates in parallel the four Kalman filters KF [1] to KF [4] to which the four initial vectors INI [1] to INI [4] are respectively supplied.
In this case, the Kalman filter KF which operates by being supplied with the initial vector INI indicating a value close to the true value of the state vector at time T = 0 can accurately estimate the state of the system.

[3. 非線形カルマンフィルタによる演算について]
次に、カルマンフィルタKFが行う非線形カルマンフィルタの演算について説明する。
[3. Calculation using nonlinear Kalman filter]
Next, the calculation of the nonlinear Kalman filter performed by the Kalman filter KF will be described.

一般的にカルマンフィルタは、動的システムの状態の経時的な変化を表す状態遷移モデルを用いて、ある時刻(時刻T=k−1)のシステムの状態を示す状態ベクトルx k−1から単位時間が経過した後(時刻T=k)の状態ベクトルxを推定する。この推定値を、推定状態ベクトルx と称する。
そして、カルマンフィルタは、各種センサからの出力を要素とする観測値ベクトルyと状態ベクトルxとの関係を表す観測モデルを用いて、推定状態ベクトルx から観測値ベクトルyを推定する。この推定値を、推定観測値ベクトルy と称する。
次に、カルマンフィルタは、推定観測値ベクトルy と、実際の観測値を要素とする観測値ベクトルyとの差分を観測残差zとして算出し、観測残差zに基づいてカルマンゲインKを算出する。さらに、カルマンフィルタは、観測残差z、カルマンゲインK、及び、推定状態ベクトルx を用いて、状態ベクトルx k−1を更新することにより、更新後の状態ベクトルx を算出する。
以上のような状態ベクトルxの更新を繰り返すカルマンフィルタの演算により、状態ベクトルxの各要素を実際の物理量を正確に表した値(真値)に近い正確な値へと近付ける。
In general, the Kalman filter uses a state transition model that represents a change in the state of a dynamic system over time, and a unit from a state vector x + k−1 that indicates the state of the system at a certain time (time T = k−1). The state vector x k after the elapse of time (time T = k) is estimated. This estimated value is referred to as an estimated state vector x k .
Then, the Kalman filter estimates the observation value vector y k from the estimated state vector x k using an observation model that represents the relationship between the observation value vector y k and the state vector x k whose elements are outputs from various sensors. . This estimated value is referred to as an estimated observation value vector y k .
Next, the Kalman filter estimated observed value vector y - and k, calculates the difference between the observed value vector y k to the actual observed value element as observed residuals z k, based on the observation residuals z k Kalman The gain Kk is calculated. Furthermore, the Kalman filter updates the state vector x + k after updating the state vector x + k−1 using the observation residual z k , the Kalman gain K k , and the estimated state vector x k. calculate.
By the Kalman filter operation that repeatedly updates the state vector x k as described above, each element of the state vector x k is brought close to an accurate value close to a value (true value) that accurately represents the actual physical quantity.

なお、詳細は後述するが、本実施形態ではカルマンフィルタとして、非線形カルマンフィルタであるシグマポイントカルマンフィルタを用いる。
シグマポイントカルマンフィルタは、まず、状態ベクトルx k−1の周囲に複数のシグマポイントχ k−1を設定し、これらの複数のシグマポイントχ k−1を状態遷移モデルに適用することで、単位時間経過後の複数のシグマポイントを推定する。この推定された複数のシグマポイントを、推定シグマポイントχ と称する。次に、シグマポイントカルマンフィルタは、複数の推定シグマポイントχ の平均を算出することにより、推定状態ベクトルx を求める。
従って、シグマポイントカルマンフィルタを用いてカルマンフィルタの演算を実行する場合、推定観測値ベクトルy は、厳密には、推定状態ベクトルx の周辺に存在する複数の推定シグマポイントχ に基づいて算出される。
Although details will be described later, in this embodiment, a sigma point Kalman filter which is a nonlinear Kalman filter is used as the Kalman filter.
The sigma point Kalman filter first sets a plurality of sigma points χ + k−1 around the state vector x + k−1 and applies the plurality of sigma points χ + k−1 to the state transition model. Estimate multiple sigma points after unit time. The plurality of estimated sigma points are referred to as estimated sigma points χ k . Next, the sigma point Kalman filter obtains an estimated state vector x - k by calculating an average of a plurality of estimated sigma points χ - k .
Therefore, when the Kalman filter operation is performed using the sigma point Kalman filter, the estimated observation value vector y k is strictly based on a plurality of estimated sigma points χ k existing around the estimated state vector x k. Is calculated.

本実施形態における、非線形カルマンフィルタの状態遷移モデルは以下に示す式(23)で与えられ、観測モデルは以下に示す式(24)で与えられる。なお、本実施形態では、式(23)に現れる状態方程式f、および、式(24)に現れる観測方程式hは、非線形の方程式である。

Figure 2013185898
In this embodiment, the state transition model of the nonlinear Kalman filter is given by the following equation (23), and the observation model is given by the following equation (24). In the present embodiment, the state equation f appearing in the equation (23) and the observation equation h appearing in the equation (24) are nonlinear equations.
Figure 2013185898

以下では、状態ベクトルxの次元を「dim(x)」と表し、観測値ベクトルyの次元を「dim(y)」と表す。本実施形態では、dim(x)=15であり、dim(y)=9である。また、式(23)に現れるプロセスノイズw及び式(24)に現れる観測ノイズuは「0」を中心とするガウスノイズである。
式(23)は、時刻T=kにおける状態ベクトルxが、時刻T=k−1における状態ベクトルxk−1を状態方程式fに代入して得られた値と、時刻T=k−1におけるプロセスノイズwk−1とを加算することにより推定されることを示している。
また、式(24)は、時刻T=kにおける観測値ベクトルyが、時刻T=kにおける状態ベクトルxを観測方程式hに代入して得られる値と、時刻T=kにおける観測ノイズuとを加算することにより推定されることを示している。
なお、プロセスノイズwの共分散をQ、観測ノイズuの共分散をUと表す。
Hereinafter, the dimension of the state vector x k is represented as “dim (x)”, and the dimension of the observation vector y k is represented as “dim (y)”. In the present embodiment, dim (x) = 15 and dim (y) = 9. Further, the process noise w k appearing in the equation (23) and the observation noise u k appearing in the equation (24) are Gaussian noises centered on “0”.
Equation (23) shows that the state vector x k at time T = k is obtained by substituting the state vector x k-1 at time T = k−1 for the state equation f, and the time T = k−1. It is estimated by adding the process noise w k−1 in FIG.
Further, the expression (24) indicates that the observed value vector y k at time T = k is obtained by substituting the state vector x k at time T = k into the observation equation h, and the observed noise u at time T = k. It shows that it is estimated by adding k .
Incidentally, representing the covariance of the process noise w k Q k, the covariance of the observation noise u k and U k.

時刻T=kにおける観測残差zは、実際の観測値ベクトルyと、推定観測値ベクトルy とに基づいて定められるベクトルであり、以下に示す式(25)で表される。カルマンフィルタは、以下の式(27)に示すように、観測残差z、推定状態ベクトルx 、及び、式(26)に示すカルマンゲインKを用いて、更新後の状態ベクトルx を算出する。また、カルマンフィルタは、以下の式(28)に示すように、状態ベクトルxの推定誤差の共分散Pを更新する。
ここで、P は、推定状態ベクトルx の推定誤差の共分散であり、P は、更新後の状態ベクトルx の推定誤差の共分散である。また、Pyy は、観測残差zの共分散であり、Pxy は、推定状態ベクトルx と、推定観測値ベクトルy との相互共分散行列である。

Figure 2013185898
The observation residual z k at time T = k is a vector determined based on the actual observation value vector y k and the estimated observation value vector y k, and is expressed by the following equation (25). As shown in the following equation (27), the Kalman filter uses the observed residual z k , the estimated state vector x k , and the Kalman gain K k shown in equation (26) to update the state vector x +. k is calculated. Further, the Kalman filter updates the covariance P k of the estimation error of the state vector x k as shown in the following equation (28).
Here, P k is the covariance of the estimated error of the estimated state vector x k , and P + k is the covariance of the estimated error of the updated state vector x + k . P yy k is a covariance of the observation residual z k , and P xy k is a mutual covariance matrix of the estimated state vector x k and the estimated observation value vector y k .
Figure 2013185898

なお、推定観測値ベクトルy は、推定状態ベクトルx (厳密には、推定シグマポイントχ )を、式(24)に示す観測モデルに適用することで算出される値である。よって、推定観測値ベクトルy と実際のセンサ出力に基づく観測値ベクトルyとの差分である観測残差zは、推定状態ベクトルx と実際の物理量を正確に表した値(真値)との近似度を示す値である。
従って、式(27)に示すように、観測残差zを用いて、推定状態ベクトルx を、更新後の状態ベクトルx へと更新することにより、状態ベクトルxの各要素を真値に近い値へと近付けることができる。
Note that the estimated observation value vector y k is a value calculated by applying the estimated state vector x k (strictly, the estimated sigma point χ k ) to the observation model shown in Expression (24). . Therefore, the observation residual z k that is the difference between the estimated observation vector y k and the observation vector y k based on the actual sensor output is a value that accurately represents the estimated state vector x k and the actual physical quantity ( This is a value indicating the degree of approximation to the true value.
Therefore, as shown in Expression (27), each element of the state vector x k is updated by updating the estimated state vector x k to the updated state vector x + k using the observation residual z k. Can be brought closer to the true value.

本実施形態に係るカルマンフィルタKFは、アンセンテッド変換を用いたシグマポイントカルマンフィルタを用いて、非線形カルマンフィルタの演算を実行する。
図5は、カルマンフィルタKF[m]の動作を説明するための機能ブロック図である。図5に示すように、遅延部310は、加算器390から出力される更新後の状態ベクトルx を、単位時間(時刻T=k−1から時刻T=kに相当する時間)だけ遅延させることで、状態ベクトルx k−1を生成し、これを、シグマポイント生成部320に対して出力する。なお、初回の演算(時刻T=0における演算)では、遅延部310は、初期値生成部200が出力する初期ベクトルINI[m]を、状態ベクトルx k−1に適用する。
The Kalman filter KF according to the present embodiment performs a nonlinear Kalman filter operation using a sigma point Kalman filter using unscented transformation.
FIG. 5 is a functional block diagram for explaining the operation of the Kalman filter KF [m]. As illustrated in FIG. 5, the delay unit 310 delays the updated state vector x + k output from the adder 390 by a unit time (time corresponding to time T = k from time T = k−1). As a result, a state vector x + k−1 is generated and output to the sigma point generation unit 320. In the first calculation (calculation at time T = 0), the delay unit 310 applies the initial vector INI [m] output from the initial value generation unit 200 to the state vector x + k−1 .

次に、シグマポイント生成部320は、「dim(x)」行「dim(x)」列の共分散行列P k−1及びQk−1を用いて、「2dim(x)+1」個のシグマポイントを生成する。
具体的には、まず、複数のシグマポイントの平均に対して、平均のまわりのシグマポイントの広がりを表すスケーリングパラメータλを用いて、式(29)及び式(30)に示すベクトルσ(1)〜σ(2dim(x))を定義する。

Figure 2013185898
Next, the sigma point generation unit 320 uses the covariance matrices P + k−1 and Q k−1 of “dim (x)” rows “dim (x)” columns to obtain “2 dim (x) +1” pieces. Generate sigma points for
Specifically, first, with respect to the average of a plurality of sigma points, a vector σ k (1) shown in Expressions (29) and (30) is used by using a scaling parameter λ representing the spread of sigma points around the average. ) To σ k (2dim (x)).
Figure 2013185898

このとき、シグマポイント生成部320は、ベクトルσk−1と状態ベクトルx k−1とに基づいて、式(31)及び式(32)で示される「2dim(x)+1」個のシグマポイントχ k−1(0)〜χ k−1(2dim(x))を生成する。

Figure 2013185898
At this time, the sigma point generation unit 320 performs “2dim (x) +1” sigma expressed by Expression (31) and Expression (32) based on the vector σ k−1 and the state vector x + k−1. Points χ + k−1 (0) to χ + k−1 (2dim (x)) are generated.
Figure 2013185898

状態遷移演算部330は、式(33)に示すように、時刻T=k−1における「2dim(x)+1」個のシグマポイントχ k−1(0)〜χ k−1(2dim(x))の各々を、状態方程式fに適用することにより、時刻T=kにおける「2dim(x)+1」個の推定シグマポイントχ (0)〜χ (2dim(x))を算出する。

Figure 2013185898
State transition operation unit 330, as shown in equation (33), "2dim (x) +1" number of sigma points χ + k-1 (0) at time T = k-1 ~χ + k -1 (2dim (x) each), by applying the state equation f, time T = "2Dim (x) +1" in the k estimated sigma points χ - k (0) ~χ - k (2dim (x)) Is calculated.
Figure 2013185898

次に、推定状態ベクトル算出部340は、式(34)に示すように、時刻T=kにおける「2dim(x)+1」個の推定シグマポイントχ (0)〜χ (2dim(x))の平均値を計算することで、推定状態ベクトルx を算出する。

Figure 2013185898
Then, the estimated state vector calculating unit 340, as shown in equation (34), time T = "2dim (x) +1" in the k estimated sigma points χ - k (0) ~χ - k (2dim ( The estimated state vector x - k is calculated by calculating the average value of x)).
Figure 2013185898

また、推定状態ベクトル算出部340は、式(35)に示すように、推定状態ベクトルx の推定誤差の共分散P を算出する。ここで、ベクトルξは、以下の式(36)に示す、推定シグマポイントχ (j)と推定状態ベクトルx との差分を表すベクトルである。

Figure 2013185898
Further, the estimated state vector calculating unit 340, as shown in equation (35), the estimated state vector x - calculates the k - covariance P of the estimation error of k. Here, the vector xi] j, the following is shown in equation (36), the estimated sigma point chi - a vector representing the difference between the k - k (j) and the estimated state vector x.
Figure 2013185898

このように、シグマポイント生成部320、状態遷移演算部330、及び、推定状態ベクトル算出部340は、状態ベクトルx k−1を状態遷移モデルに適用することで推定状態ベクトルx を算出する、状態遷移モデル部710として機能する。 As described above, the sigma point generation unit 320, the state transition calculation unit 330, and the estimated state vector calculation unit 340 calculate the estimated state vector x k by applying the state vector x + k−1 to the state transition model. Functions as a state transition model unit 710.

一方、推定観測値算出部350は、式(37)に示すように、時刻T=kにおける「2dim(x)+1」個の推定シグマポイントχ (0)〜χ (2dim(x))の各々を、観測方程式hに適用することにより、「2dim(x)+1」個の推定観測値γ(0)〜γ(2dim(x))を算出する。

Figure 2013185898
On the other hand, the estimated observation value calculating unit 350, as shown in equation (37), time T = "2dim (x) +1" in the k estimated sigma points χ - k (0) ~χ - k (2dim (x each)), by applying to the observation equation h, to calculate the "2dim (x) +1" number of estimated observations γ k (0) ~γ k ( 2dim (x)).
Figure 2013185898

そして、推定観測値ベクトル算出部360は、式(38)に示すように、「2dim(x)+1」個の推定観測値γ(0)〜γ(2dim(x))の平均を演算することにより、推定観測値ベクトルy を算出する。

Figure 2013185898
Then, the estimated observed value vector calculation unit 360, as shown in equation (38), the average of "2dim (x) +1" number of estimated observations γ k (0) ~γ k ( 2dim (x)) calculation By doing so, the estimated observation value vector y - k is calculated.
Figure 2013185898

また、推定観測値ベクトル算出部360は、式(39)に示すように、観測残差の共分散Pyy を算出する。ここで、ベクトルζは、以下の式(40)に示すように、推定観測値γ(j)と推定観測値ベクトルy との差分を表すベクトルである。

Figure 2013185898
Further, the estimated observation value vector calculation unit 360 calculates the covariance P yy k of the observation residual as shown in the equation (39). Here, the vector ζ j is a vector representing the difference between the estimated observation value γ k (j) and the estimated observation value vector y k , as shown in the following equation (40).
Figure 2013185898

このように、推定観測値算出部350、及び、推定観測値ベクトル算出部360は、推定シグマポイントχ (0)〜χ (2dim(x))の各々を観測モデルに適用することで推定観測値ベクトルy を算出する観測モデル部720として機能する。 Thus, the estimated observation value calculating unit 350, and the estimated observed value vector calculating unit 360 estimates the sigma points χ - k (0) ~χ - k be applied to each observation model (2dim (x)) Functions as an observation model unit 720 that calculates the estimated observation value vector y k .

減算器370は、式(25)に示したように、観測値ベクトルyと、推定観測値ベクトルy との差分として、観測残差zを算出する。
カルマンゲイン付与部380は、式(41)に示すように、相互共分散行列Pxy を算出する。そして、カルマンゲイン付与部380は、式(26)に示したように、観測残差の共分散Pyy と、相互共分散行列Pxy とに基づいて、カルマンゲインKを算出し、式(27)の右辺第2項(K)の演算を実行する。

Figure 2013185898
The subtractor 370 calculates an observation residual z k as a difference between the observed value vector y k and the estimated observed value vector y k , as shown in Expression (25).
The Kalman gain assigning unit 380 calculates the mutual covariance matrix P xy k as shown in Expression (41). Then, as shown in Expression (26), the Kalman gain assigning unit 380 calculates the Kalman gain K k based on the covariance P yy k of the observation residual and the mutual covariance matrix P xy k , The calculation of the second term (K k z k ) on the right side of Expression (27) is executed.
Figure 2013185898

加算器390は、式(27)に示したように、推定状態ベクトルx と、カルマンゲイン付与部380から出力される式(27)の右辺第2項(K)とを加算することにより、更新後の状態ベクトルx を算出する。また、加算器390は、式(28)に示したように、状態ベクトルxの推定誤差の共分散Pを、P からP に更新する。 The adder 390 adds the estimated state vector x k and the second term (K k z k ) on the right side of the equation (27) output from the Kalman gain assigning unit 380, as shown in the equation (27). Thus, the updated state vector x + k is calculated. The adder 390, as shown in equation (28), the covariance P k of the estimation error of the state vector x k, P - updates from k to P + k.

このように、減算器370、カルマンゲイン付与部380、及び、加算器390は、観測残差z、カルマンゲインK、及び、推定状態ベクトルx を用いて、状態ベクトルx k−1を更新した更新後の状態ベクトルx を算出する更新部730として機能する。 As described above, the subtractor 370, the Kalman gain assigning unit 380, and the adder 390 use the observation residual z k , the Kalman gain K k , and the estimated state vector x k to generate a state vector x + k−. It functions as an updating unit 730 that calculates the updated state vector x + k that updates 1 .

次に、状態遷移モデル部710において用いられる状態遷移モデルのうち、状態遷移演算部330における演算で用いられる状態方程式fについて説明する。   Next, of the state transition models used in the state transition model unit 710, the state equation f used in the calculation in the state transition calculation unit 330 will be described.

まず、状態方程式fのうち、時刻T=k−1における姿勢μ k−1から、単位時間経過後の時刻T=kにおける姿勢μ を推定する演算は、以下に示す式(42)として表される。ここで、μ は、時刻kにおける推定状態ベクトルx のうち、姿勢μを表す状態変数に対応する要素である。
なお、式(42)の右辺の演算子Ωは、式(43)により定義される。ここで、I3×3は3行3列の単位行列を表す。3次元ベクトルl=(l,l,l)に対して、演算子[l×]は、式(44)で定義される。また、単位時間(時刻T=k−1から時刻T=kまでの測定時間間隔)をΔtで表し、時刻T=kにおける更新後の状態ベクトルx のうち角速度を表す状態変数に対応する要素をω で表したとき、演算子Ωを構成する成分Ψ は、式(45)で定義される。

Figure 2013185898
First, of the state equation f, from the time T = k-1 attitude mu + k-1 in the posture mu at time T = k after the lapse of the unit time - calculation for estimating the k is given by the following equation (42) Represented as: Here, mu - k is estimated state vector x at time k - of k, an element corresponding to the state variable representing the attitude mu.
The operator Ω on the right side of the equation (42) is defined by the equation (43). Here, I 3 × 3 represents a unit matrix of 3 rows and 3 columns. For the three-dimensional vector l = (l 1 , l 2 , l 3 ), the operator [l ×] is defined by equation (44). Further, unit time (measurement time interval from time T = k−1 to time T = k) is represented by Δt, and corresponds to a state variable representing an angular velocity in the state vector x + k after the update at time T = k. When the element is represented by ω + k , the component Ψ + k constituting the operator Ω is defined by Expression (45).
Figure 2013185898

姿勢μは、クォータニオンで表現され、式(2)に示すように、正規化条件||μ||=1を満たす必要がある。しかし、シグマポイントカルマンフィルタを用いて状態ベクトルxを更新する場合、更新後の状態ベクトルx は、式(34)に示すように、推定シグマポイントχ (j)の平均として算出される推定状態ベクトルx に基づいて定められるため、(更新前の)状態ベクトルx k−1のノルムと、更新後の状態ベクトルx のノルムとは、異なる値となることがある。従って、シグマポイントカルマンフィルタの演算を行う場合、(更新前の)状態ベクトルx k−1の要素である姿勢μ k−1のノルムと、更新後の状態ベクトルx の要素である姿勢μ のノルムとは、異なる値となる可能性が存在する。つまり、シグマポイントカルマンフィルタの演算を行う場合、姿勢μについての正規化条件が満たされなくなる可能性が存在する。
そこで、姿勢μに対して何らかの演算が行われるときには、演算後の結果をそのベクトル自身の大きさで正規化する。
なお、より厳密に正規化条件を保つためには、状態ベクトルxを構成する要素のうち姿勢μについてはMRPs (modified Rodrigues parameters)を用いて前時刻との差分情報だけに限定し、カルマンフィルタの外部にある姿勢情報をカルマンフィルタから得られる差分情報に基づいて更新すればよい。
The attitude μ is expressed by a quaternion and needs to satisfy the normalization condition || μ || = 1 as shown in the equation (2). However, when the state vector x k is updated using the sigma point Kalman filter, the updated state vector x + k is calculated as an average of the estimated sigma points χ k (j) as shown in the equation (34). that the estimated state vector x - since that is determined based on k, the norm of the (pre-update) the state vector x + k-1, and the norm of the state vector x + k after update, it may become different values . Accordingly, when the sigma point Kalman filter is calculated, the norm of the posture μ + k−1 that is an element of the state vector x + k−1 (before update) and the posture that is an element of the state vector x + k after update. There is a possibility of a different value from the norm of μ + k . That is, when performing the sigma point Kalman filter calculation, there is a possibility that the normalization condition for the posture μ is not satisfied.
Therefore, when any calculation is performed on the posture μ, the result after the calculation is normalized by the size of the vector itself.
In order to maintain the normalization condition more strictly, the posture μ k among elements constituting the state vector x k is limited to only the difference information from the previous time using MRPs (modified Rodrigues parameters), and the Kalman filter May be updated based on the difference information obtained from the Kalman filter.

地磁気の強さr及び地磁気の伏角φは、変化を予測することが難しい。そこで、本実施形態に係る状態遷移モデルでは、便宜上、時刻T=kにおける地磁気の強さr及び伏角φと、時刻T=k−1における地磁気の強さrk−1及び伏角φk−1とは各々等しい値であると仮定する。
同様に、3次元角速度センサ90のオフセット推定値gOFFは、変化を予測することが難しい。そこで、本実施形態に係る状態遷移モデルでは、便宜上、時刻T=kにおける3次元角速度センサ90のオフセット推定値gOFF,Kと、時刻T=k−1における3次元角速度センサ90のオフセット推定値gOFF,K−1とは等しい値であると仮定する。
It is difficult to predict changes in the geomagnetic strength r and the geomagnetic dip angle φ. Therefore, in the state transition model according to the present embodiment, for the sake of convenience, the geomagnetic strength r k and the dip angle φ k at time T = k, and the geomagnetic strength r k-1 and the dip angle φ k at time T = k−1. It is assumed that −1 is an equal value.
Similarly, it is difficult to predict a change in the estimated offset value g OFF of the three-dimensional angular velocity sensor 90. Therefore, in the state transition model according to the present embodiment, for convenience, the estimated offset value g OFF, K of the three-dimensional angular velocity sensor 90 at time T = k and the estimated offset value of the three-dimensional angular velocity sensor 90 at time T = k−1. Assume that g OFF, K−1 is equal.

携帯機器1の角速度ωは、携帯機器1の利用者による携帯機器1の動かし方に依存して変化するため、時刻T=k−1の角速度ωk−1を用いて、時刻T=kにおける角速度ωを定式化することは難しい。そこで、本実施形態に係る状態遷移モデルでは、便宜上、時刻T=kにおける角速度ωと、時刻T=k−1における角速度ωk−1とは等しいと仮定する。 Since the angular velocity ω of the mobile device 1 changes depending on how the user of the mobile device 1 moves the mobile device 1, the angular velocity ω k−1 at time T = k −1 is used at time T = k. It is difficult to formulate the angular velocity ω k . Therefore, in the state transition model according to the present embodiment, for convenience, it is assumed that the angular velocity ω k at time T = k is equal to the angular velocity ω k-1 at time T = k−1.

前述のとおり、3次元磁気センサ70のオフセットは、携帯機器1の部品が発する内部磁界Biの方向及び大きさを機器座標系Σにおいて表現したベクトルである。従って、携帯機器1の内部状態が一定である間は、3次元磁気センサ70のオフセットも変化しない。一方、携帯機器1の内部状態が変化した場合、例えば、携帯機器1に搭載された部品を流れる電流の大きさが変化した場合や、携帯機器1に搭載された部品の着磁状況が変化した場合には、3次元磁気センサ70のオフセットも変化する。すなわち、携帯機器1の内部状態は、携帯機器1の利用者による携帯機器1の操作や、携帯機器1の外部の環境等に依存して変化する。従って、3次元磁気センサ70のオフセットが変化するタイミングや3次元磁気センサ70のオフセットの変化量を予測することは困難であり、時刻T=k−1における3次元磁気センサ70のオフセット推定値qOFF,K−1を用いて、時刻T=kにおける3次元磁気センサ70のオフセット推定値qOFF,Kを定式化することは難しい。
そこで、本実施形態に係る状態遷移モデルでは、便宜上、時刻T=kにおける3次元磁気センサ70のオフセット推定値qOFF,Kと、時刻T=k−1における3次元磁気センサ70のオフセット推定値qOFF,K−1とは等しいと仮定する。
As described above, the offset of the three-dimensional magnetic sensor 70 is a vector expressed in the direction and magnitude of the instrument coordinate system sigma S of the internal magnetic field Bi to the portable device 1 of the component emitted. Therefore, the offset of the three-dimensional magnetic sensor 70 does not change while the internal state of the mobile device 1 is constant. On the other hand, when the internal state of the mobile device 1 changes, for example, when the magnitude of the current flowing through the component mounted on the mobile device 1 changes, or the magnetization status of the component mounted on the mobile device 1 changes. In this case, the offset of the three-dimensional magnetic sensor 70 also changes. That is, the internal state of the mobile device 1 changes depending on the operation of the mobile device 1 by the user of the mobile device 1, the environment outside the mobile device 1, and the like. Therefore, it is difficult to predict the timing at which the offset of the three-dimensional magnetic sensor 70 changes and the amount of change in the offset of the three-dimensional magnetic sensor 70, and the offset estimated value q of the three-dimensional magnetic sensor 70 at time T = k−1. It is difficult to formulate the estimated offset value q OFF, K of the three-dimensional magnetic sensor 70 at time T = k using OFF, K-1 .
Therefore, in the state transition model according to this embodiment, for convenience, the estimated offset value q OFF, K of the three-dimensional magnetic sensor 70 at time T = k and the estimated offset value of the three-dimensional magnetic sensor 70 at time T = k−1. Assume that q OFF, K−1 is equal.

このように、本実施形態に係る状態遷移モデルにおける状態方程式fは、以下に示す式(46)のように、状態ベクトルxを構成する複数の状態変数のうち、姿勢μを表す状態変数以外は、前の時刻から変化しないことを表す方程式として、定式化される。

Figure 2013185898
As described above, the state equation f in the state transition model according to the present embodiment is a state variable representing the posture μ k among a plurality of state variables constituting the state vector x k as shown in the following equation (46). Other than the above, it is formulated as an equation indicating that it does not change from the previous time.
Figure 2013185898

このように、状態ベクトルxを、状態方程式fに適用した場合、状態ベクトルxのうち、姿勢μ以外の各要素の示す値は変化しない。
しかし、状態ベクトルxのうち姿勢μ以外の各要素は、加算器390において、観測残差zに基づいて真値に近づくように更新される。つまり、式(27)に示すように、状態ベクトルxの各要素は、状態遷移モデルにより算出される推定状態ベクトルx と、複数のセンサからの出力値(観測値ベクトルy)を用いて算出される観測残差zとの双方に基づいて、真値に近づくように更新される。
As described above, when the state vector x k is applied to the state equation f, the value indicated by each element other than the posture μ k in the state vector x k does not change.
However, each element of the state vector x k other than the posture μ k is updated by the adder 390 so as to approach the true value based on the observation residual z k . That is, as shown in Expression (27), each element of the state vector x k includes an estimated state vector x k calculated by the state transition model and output values (observed value vectors y k ) from a plurality of sensors. Based on both of the observation residuals z k calculated using the values, the values are updated so as to approach the true value.

次に、観測モデル部720において用いられる観測モデルのうち、推定観測値算出部350における演算で用いられる観測方程式hについて説明する。   Next, among the observation models used in the observation model unit 720, the observation equation h used in the calculation in the estimated observation value calculation unit 350 will be described.

3次元角速度センサ90から出力される角速度データgの推定値γgyroは、角速度ωと、角速度センサのオフセット推定値gOFFとを用いて、式(47)で与えられる。

Figure 2013185898
The estimated value γ gyro of the angular velocity data g output from the three-dimensional angular velocity sensor 90 is given by Expression (47) using the angular velocity ω and the estimated offset value g OFF of the angular velocity sensor.
Figure 2013185898

また、地上座標系Σにおいて地磁気Bgを表すベクトルBgは式(48)で与えられる。従って、3次元磁気センサ70から出力される磁気データqの推定値γmagは、磁気センサのオフセット推定値qOFFと、式(20)で示した行列B(μ)とを用いて、式(49)で与えられる。

Figure 2013185898
Furthermore, the vector G Bg of the ground coordinate system sigma G represents the geomagnetism Bg is given by equation (48). Therefore, the estimated value γ mag of the magnetic data q output from the three-dimensional magnetic sensor 70 is obtained by using the offset estimated value q OFF of the magnetic sensor and the matrix B (μ) shown in the expression (20). 49).
Figure 2013185898

また、観測モデルにおいて、3次元加速度センサ80から出力される加速度データaの推定値γaccは、式(20)で示した行列B(μ)と、ベクトルRVとを用いて、式(50)で与えられる。なお、ベクトルRVは、以下の式(51)に示すように、地上座標系Σにおいて重力加速度を表したベクトルを、重力加速度の大きさで正規化した3次元のベクトルである。

Figure 2013185898
Further, in the observation model, the estimated value γ acc of the acceleration data a output from the three-dimensional acceleration sensor 80 is expressed by the equation (20) using the matrix B (μ) expressed by the equation (20) and the vector G G RV. 50). Incidentally, the vector G G RV is as shown in the following equation (51), a vector representing the gravitational acceleration in the ground coordinate system sigma G, a three-dimensional vector obtained by normalizing the magnitude of the gravitational acceleration.
Figure 2013185898

このように、本実施形態に係る観測モデルにおける観測方程式hは、式(47)、式(49)、及び式(50)により定式化される。
そして、式(3)を式(25)の右辺第1項に代入し、式(47)、式(49)、及び式(50)を用いて式(25)の右辺第2項を表すことにより、式(25)を、以下の式(52)に変形することができる。このとき、観測残差zは、式(52)により算出される。

Figure 2013185898
Thus, the observation equation h in the observation model according to the present embodiment is formulated by the equations (47), (49), and (50).
Then, substituting Equation (3) into the first term on the right side of Equation (25) and expressing the second term on the right side of Equation (25) using Equation (47), Equation (49), and Equation (50). Thus, the equation (25) can be transformed into the following equation (52). At this time, the observation residual z k is calculated by the equation (52).
Figure 2013185898

[4. 結論]
初期ベクトルINIの各要素を、事前に定めた所定の値とした場合、姿勢μの初期値μは、姿勢μの初期値μ以外の要素(例えば、地磁気の強さrの初期値rや、地磁気の伏角φの初期値φ等)に比べて、真値から大きく乖離した値となる可能性が高い。例えば、上述のとおり、初期値μを、事前に定められた1つの固定値に定める場合、初期値μは真の姿勢(真値)から最大で180度ずれることになる。この場合、状態推定装置は、システムの状態を正しく推定することができない。
これに対して、本実施形態に係る状態推定装置は、画像情報Imgと位置情報Psとを用いて、姿勢μの初期値μ[1]〜μ[4]を生成するため、初期値μ[1]〜μ[4]のうち少なくとも1つの初期値μ[Sel]を真値に近い値とすることが可能となる。
真値に近い初期値μ[Sel]が供給されるカルマンフィルタKF[Sel]は、システムの状態を正確に推定することができる。すなわち、カルマンフィルタKF[Sel]が出力する状態ベクトルx[Sel]の各要素は、真値に近い正確な値となる。そして、出力情報制御部400は、カルマンフィルタKF[1]〜KF[4]が出力する状態ベクトルx[1]〜x[4]から、状態ベクトルx[Sel]を選択し、これを出力情報生成部500に供給する。この場合、出力情報生成部500は、地磁気Bg、携帯機器1の姿勢等を正確に表す出力情報を生成することができる。
このように、本実施形態に係る状態推定装置は、システムの状態を正確に推定することができる。
[4. Conclusion]
Each element of the initial vector INI, when a predetermined value set in advance, the posture initial value mu 0 of mu, the initial value mu 0 other elements of attitude mu (e.g., initial value r geomagnetic strength r 0 and, in comparison with the initial value phi 0, etc.) of the geomagnetic dip phi, it is likely to be a large discrepancy value from the true value. For example, as described above, when the initial value μ 0 is set to one predetermined fixed value, the initial value μ 0 is shifted by 180 degrees from the true posture (true value) at the maximum. In this case, the state estimation device cannot correctly estimate the state of the system.
On the other hand, the state estimation device according to the present embodiment generates the initial values μ 0 [1] to μ 0 [4] of the posture μ using the image information Img and the position information Ps. μ 0 [1] ~μ 0 [ 4] it is possible to a value close to the true value of at least one initial value mu 0 [Sel] of.
The Kalman filter KF [Sel] supplied with the initial value μ 0 [Sel] close to the true value can accurately estimate the state of the system. That is, each element of the state vector x k [Sel] output from the Kalman filter KF [Sel] has an accurate value close to the true value. The output information control unit 400, the Kalman filter KF [1] ~KF [4] the state vector x k [1] that is outputted ~x k [4], and select the state vector x k [Sel], this This is supplied to the output information generation unit 500. In this case, the output information generation unit 500 can generate output information that accurately represents the geomagnetism Bg, the posture of the mobile device 1, and the like.
Thus, the state estimation apparatus according to the present embodiment can accurately estimate the state of the system.

<B.変形例>
本発明は上述した実施形態に限定されるものではなく、例えば、以下の変形が可能である。また、以下に示す変形例のうちの2以上の変形例は、相互に矛盾しない範囲内で適宜に組み合わせることもできる。
<B. Modification>
The present invention is not limited to the above-described embodiments, and for example, the following modifications are possible. Further, two or more of the modifications shown below can be appropriately combined within a range that does not contradict each other.

(1)変形例1
上述した実施形態において、物体Objは、地上座標系Σにおける座標が既知のランドマークであったが、本発明はこのような態様に限定されるものではなく、物体Objは、太陽、月、星等の天体であってもよい。
変形例1に係る状態推定装置は、初期値生成部200の代わりに初期値生成部200aを備える点を除き、上述した実施形態に係る状態推定装置と同様に構成される。図6は、初期値生成部200aの機能ブロック図である。初期値生成部200aは、初期姿勢算出部220の代わりに、初期姿勢算出部220aを備える点を除き、初期値生成部200と同様に構成される。初期姿勢算出部220aは、撮影対象情報取得部221の代わりに、撮影対象情報取得部221aを備える点を除き、初期姿勢算出部220と同様に構成される。
変形例1に係る携帯機器が備えるROMには、物体Objの候補となり得る複数の天体の各々についての情報Pobj2を記憶したルックアップテーブルが格納される。ここで、情報Pobj2の具体的な内容は、各天体の軌道に関する情報(例えば、地球上の位置及び時刻と、当該位置及び時刻において各天体が見える方向とに関する情報)である。撮影対象情報取得部221aは、携帯機器の位置情報Ps、物体Objの情報Pobj2、及び、時刻情報Timeに基づいて、第2方向ベクトルβを生成する。初期姿勢算出部220aは、初期姿勢算出部220と同様に、少なくとも1つが真値に近い値を示す姿勢μの4つの初期値μ[1]〜μ[4]を生成することができる。従って、変形例1に係る状態推定装置は、システムの状態を正確に推定することができる。
(1) Modification 1
In the embodiment described above, the object Obj is coordinates in ground coordinate system sigma G was known landmarks, the present invention is not limited to such a mode, the object Obj is the sun, the moon, It may be a celestial body such as a star.
The state estimation device according to the modified example 1 is configured in the same manner as the state estimation device according to the above-described embodiment except that the initial value generation unit 200a is provided instead of the initial value generation unit 200. FIG. 6 is a functional block diagram of the initial value generation unit 200a. The initial value generation unit 200a is configured in the same manner as the initial value generation unit 200 except that an initial posture calculation unit 220a is provided instead of the initial posture calculation unit 220. The initial posture calculation unit 220a is configured in the same manner as the initial posture calculation unit 220 except that it includes a shooting target information acquisition unit 221a instead of the shooting target information acquisition unit 221.
The ROM included in the mobile device according to the first modification stores a look-up table storing information Pobj2 about each of a plurality of celestial bodies that can be candidates for the object Obj. Here, the specific content of the information Pobj2 is information on the orbit of each celestial body (for example, information on the position and time on the earth and the direction in which each celestial body can be seen at the position and time). The imaging target information acquisition unit 221a generates the second direction vector β based on the position information Ps of the mobile device, the information Obj2 of the object Obj, and the time information Time. Similar to the initial posture calculation unit 220, the initial posture calculation unit 220a can generate four initial values μ 0 [1] to μ 0 [4] of the posture μ in which at least one indicates a value close to the true value. . Therefore, the state estimation device according to the first modification can accurately estimate the state of the system.

(2)変形例2
上述した実施形態において、携帯機器1は時計130を備えるが、本発明に係る携帯機器はこのような構成に限定されるものではなく、携帯機器1は時計130を備えないものであってもよい。
(2) Modification 2
In the embodiment described above, the mobile device 1 includes the timepiece 130, but the mobile device according to the present invention is not limited to such a configuration, and the mobile device 1 may not include the timepiece 130. .

(3)変形例3
上述した実施形態及び変形例に係る状態推定装置は、4個の初期ベクトルINI[1]〜INI[4]に基づいて動作する4個のカルマンフィルタKF[1]〜KF[4]を備えるものであったが、本発明はこのような形態に限定されるものではなく、所定数Mの初期ベクトルINI[1]〜INI[M]に基づいて並列に動作する所定数MのカルマンフィルタKF[1]〜KF[M]を備えるものであってもよい(Mは、1≦Mを満たす自然数)。
この場合、変形例3に係る初期値生成部200は、所定数Mの初期ベクトルINI[1]〜INI[M]を生成するものであればよい。具体的には、変形例3に係る初期値生成部200は、第1方向ベクトルα及び第2方向ベクトルβに基づいて姿勢A(姿勢A[1])を算出し、直線AX(第2方向ベクトルβ)を軸として当該姿勢Aを所定角度(2π/M)ずつ回転させることで、姿勢A[2]〜A[M]を算出し、所定数Mの姿勢A[1]〜A[M]から、姿勢μの初期値μ[1]〜μ[M]を生成する初期姿勢算出部220と、所定数Mの初期値μ[1]〜μ[M]に基づいて、所定数Mの初期ベクトルINI[1]〜INI[M]を生成する初期ベクトル生成部230と、を備えるものであればよい。
また、この場合、出力情報制御部400は、所定数MのカルマンフィルタKF[1]〜KF[M]の中から、推定精度が最も高いカルマンフィルタを選択するものであればよい。
所定数Mが、「4」よりも大きい場合、変形例3に係る状態推定装置は、上述した実施形態に係る状態推定装置に比べて、より正確且つ迅速に、システムの状態を推定することが可能となる。また、所定数Mが、「4」よりも小さい場合、変形例3に係る状態推定装置は、上述した実施形態に係る状態推定装置に比べて、非線形カルマンフィルタの演算における処理負荷を小さく抑えることが可能となるため、状態推定装置が組み込まれる携帯機器の低消費電力化が可能となる。
(3) Modification 3
The state estimation device according to the embodiment and the modification described above includes four Kalman filters KF [1] to KF [4] that operate based on the four initial vectors INI [1] to INI [4]. However, the present invention is not limited to such a form, and the predetermined number M of Kalman filters KF [1] operating in parallel based on the predetermined number M of initial vectors INI [1] to INI [M]. -KF [M] may be provided (M is a natural number satisfying 1 ≦ M).
In this case, the initial value generation unit 200 according to the modification 3 may be anything that generates a predetermined number M of initial vectors INI [1] to INI [M]. Specifically, the initial value generation unit 200 according to the modified example 3 calculates the posture A C (posture A [1]) based on the first direction vector α and the second direction vector β, and generates a straight line AX (second by rotating the attitude a C as an axis direction vectors beta) by a predetermined angle (2π / M), and calculates the attitude a [2] ~A [M] , the posture a [1] of the predetermined number M to a from [M], based on the initial orientation calculation unit 220 that generates the initial value μ 0 [1] ~μ 0 posture mu [M], the initial value of a predetermined number M μ 0 [1] ~μ 0 [M] The initial vector generation unit 230 that generates the predetermined number M of initial vectors INI [1] to INI [M] may be used.
In this case, the output information control unit 400 only needs to select a Kalman filter with the highest estimation accuracy from a predetermined number M of Kalman filters KF [1] to KF [M].
When the predetermined number M is larger than “4”, the state estimation device according to the modified example 3 can estimate the state of the system more accurately and quickly than the state estimation device according to the above-described embodiment. It becomes possible. Further, when the predetermined number M is smaller than “4”, the state estimation device according to the modified example 3 can suppress the processing load in the calculation of the nonlinear Kalman filter to be smaller than that of the state estimation device according to the above-described embodiment. Therefore, it is possible to reduce the power consumption of the portable device in which the state estimation device is incorporated.

(4)変形例4
上述した実施形態及び変形例に係る状態推定装置は、カルマンフィルタKFの推定精度を、誤差評価値MAX[m]を用いて評価するものであったが、本発明はこのような態様に限定されるものではなく、状態ベクトルxの示す値と状態ベクトルの真値との誤差の大きさを評価することのできる値であれば、いかなる値を用いてカルマンフィルタKFの推定精度を評価してもよい。例えば、状態ベクトルxの推定誤差の共分散Pを用いて、カルマンフィルタKFの推定精度を評価するものであってもよい。
(4) Modification 4
The state estimation device according to the embodiment and the modification described above evaluates the estimation accuracy of the Kalman filter KF using the error evaluation value MAX z k [m], but the present invention is limited to such an aspect. the invention is not, if the value that can evaluate the magnitude of the error between the true value of the values and the state vector indicating the state vector x k, by evaluating the estimation accuracy of the Kalman filter KF using any value Also good. For example, using a covariance P k of the estimation error of the state vector x k, it may be configured to evaluate the estimation accuracy of the Kalman filter KF.

(5)変形例5
上述した実施形態及び変形例に係る状態推定装置は、カメラ110が1つの物体Objを撮影した際に出力される画像情報Imgに基づいて複数の初期ベクトルINI[1]〜INI[M]を生成し、これらが各々供給される複数のカルマンフィルタKF[1]〜KF[M]を並列に動作させるものであったが、本発明はこのような態様に限定されるものではなく、カメラ110が2つの物体Obj(物体Obj1、物体Obj2)を撮影した際に出力される画像情報Imgに基づいて1つの初期ベクトルINI[1]を生成し、当該初期ベクトルINI[1]が供給されるカルマンフィルタKF[1]を単独で動作させるものであってもよい。
2つの物体Objを撮影して画像情報Imgが生成される場合、当該画像情報Imgに基づいて、2つの物体Objのそれぞれに対応する2つの第1方向ベクトルαと、2つの物体Objのそれぞれに対応する2つの第2方向ベクトルβと、が生成される。この場合、2つの第1方向ベクトルαと、2つの第2方向ベクトルβとに基づいて、携帯機器1の姿勢μの初期値μ(姿勢A)を一意に特定することができるため、真値に近い値を有する正確な初期ベクトルINI[1]を、カルマンフィルタKF[1]に供給することができる。
(5) Modification 5
The state estimation device according to the embodiment and the modification described above generates a plurality of initial vectors INI [1] to INI [M] based on the image information Img output when the camera 110 captures one object Obj. However, the plurality of Kalman filters KF [1] to KF [M] to which these are supplied are operated in parallel. However, the present invention is not limited to such an embodiment, and two cameras 110 are provided. One initial vector INI [1] is generated based on image information Img output when two objects Obj (object Obj1, object Obj2) are photographed, and the initial vector INI [1] is supplied to the Kalman filter KF [ 1] may be operated independently.
When the image information Img is generated by photographing the two objects Obj, based on the image information Img, the two first direction vectors α corresponding to the two objects Obj and the two objects Obj, respectively. Two corresponding second direction vectors β are generated. In this case, since the initial value μ 0 (attitude A) of the attitude μ of the mobile device 1 can be uniquely specified based on the two first direction vectors α and the two second direction vectors β, true An accurate initial vector INI [1] having a value close to the value can be supplied to the Kalman filter KF [1].

図7は、変形例5に係る状態推定装置のうち、CPU10が変形例5に係る状態推定プログラムを実行することにより実現される機能を表した、機能ブロック図である。
図7に示すように、変形例5に係る状態推定装置は、初期値生成部200の代わりに初期値生成部200bを備える点、カルマンフィルタ演算部300の代わりにカルマンフィルタ演算部300bを備える点、及び、出力情報制御部400を備えない点を除き、実施形態に係る状態推定装置と同様に構成される。
初期値生成部200bは、画像処理部210b、初期姿勢算出部220b、及び、初期ベクトル生成部230bを備える。画像処理部210bは、カメラ110が2つの物体Obj(物体Obj1、物体Obj2)を撮影した際に出力される画像情報Imgに基づいて、機器座標系Σにおいて、携帯機器1から見た物体Obj1の方向を表す第1方向ベクトルαと、携帯機器1から見た物体Obj2の方向を表す第1方向ベクトルαとを算出する。第1方向ベクトルα及び第1方向ベクトルαは、長さが「1」に正規化されたベクトルである。
初期姿勢算出部220bは、撮影対象情報取得部221bと、姿勢計算部222bとを備える。撮影対象情報取得部221bは、カメラ110が撮影した2つの物体Objに係る情報Pobj(または情報Pobj2)と位置情報Psとに基づいて、地上座標系Σにおいて、携帯機器1から見た物体Obj1の方向を表す第2方向ベクトルβと、携帯機器1から見た物体Obj2の方向を表す第2方向ベクトルβとを算出する。第2方向ベクトルβ及び第2方向ベクトルβは、長さが「1」に正規化されたベクトルである。
カメラ110が2つの物体Objを撮影した際の、携帯機器1の姿勢をAとしたとき、式(53)及び式(54)が成立する。式(53)及び式(54)は、式(55)に変形できる。そして、式(53)〜式(55)は、式(56)に変形できる。なお、式(56)において、行列Dαは、式(57)に示す3行3列の行列であり、行列Dβは、式(58)に示す3行3列の行列である。従って、姿勢Aは、式(59)により、一意に算出することができる。姿勢計算部222bは、2つの第1方向ベクトルα、αと、2つの第2方向ベクトルβ、βとを用いて、式(59)に基づいて、姿勢A(携帯機器1の姿勢μの初期値μ[1])を算出する。初期ベクトル生成部230bは、初期値μ[1]に基づいて、初期ベクトルINI[1]を算出する。
カルマンフィルタ演算部300bは、1個のカルマンフィルタKF[1]を備え、カルマンフィルタKF[1]には、初期ベクトルINI[1]が供給される。カルマンフィルタKF[1]は、周期的に状態ベクトルx[1](厳密には、更新後の状態ベクトルx [1])を出力する。そして、出力情報生成部500は、状態ベクトルx[1]に基づいて、出力情報を生成する。
上述のとおり、初期ベクトルINI[1]は、状態ベクトルx[1]の真値に近い正確な値であるため、カルマンフィルタKF[1]は、システムの状態を正確且つ迅速に推定することができる。

Figure 2013185898
FIG. 7 is a functional block diagram illustrating functions realized by the CPU 10 executing the state estimation program according to the modification 5 in the state estimation device according to the modification 5.
As shown in FIG. 7, the state estimation device according to the modified example 5 includes an initial value generation unit 200b instead of the initial value generation unit 200, a point including a Kalman filter calculation unit 300b instead of the Kalman filter calculation unit 300, and The configuration is the same as that of the state estimation device according to the embodiment except that the output information control unit 400 is not provided.
The initial value generation unit 200b includes an image processing unit 210b, an initial posture calculation unit 220b, and an initial vector generation unit 230b. The image processing unit 210b, the camera 110 has two objects Obj (object Obj1, object Obj2) based on image information Img output upon shooting, in the device coordinate system sigma S, the object viewed from the portable device 1 Obj1 the first direction vector alpha 1 representing the direction of, and calculates a first direction vector alpha 2 representing the direction of the object Obj2 viewed from the portable device 1. The first direction vector α 1 and the first direction vector α 2 are vectors normalized in length to “1”.
The initial posture calculation unit 220b includes a shooting target information acquisition unit 221b and a posture calculation unit 222b. Photographing object information obtaining section 221b, on the basis of the information relating to two objects Obj camera 110 is photographed Pobj (or information Pobj2) and position information Ps, the ground coordinate system sigma G, the object viewed from the portable device 1 Obj1 a second direction vector beta 1 representing the direction of, and calculates a second direction vector beta 2 which represents the direction of the object Obj2 viewed from the portable device 1. The second direction vector β 1 and the second direction vector β 2 are vectors whose lengths are normalized to “1”.
When the camera 110 captures two objects Obj and the posture of the mobile device 1 is A, Expressions (53) and (54) are established. Expressions (53) and (54) can be transformed into Expression (55). And Formula (53)-Formula (55) can be deform | transformed into Formula (56). In Expression (56), the matrix is a 3 × 3 matrix shown in Expression (57), and the matrix is a 3 × 3 matrix shown in Expression (58). Therefore, the posture A can be uniquely calculated by the equation (59). The posture calculation unit 222b uses the two first direction vectors α 1 and α 2 and the two second direction vectors β 1 and β 2 , based on the equation (59), based on the equation (59). The initial value μ 0 [1]) of the posture μ is calculated. The initial vector generation unit 230b calculates an initial vector INI [1] based on the initial value μ 0 [1].
The Kalman filter operation unit 300b includes one Kalman filter KF [1], and an initial vector INI [1] is supplied to the Kalman filter KF [1]. The Kalman filter KF [1] periodically outputs a state vector x k [1] (strictly, an updated state vector x + k [1]). Then, the output information generation unit 500 generates output information based on the state vector x k [1].
As described above, since the initial vector INI [1] is an accurate value close to the true value of the state vector x 0 [1], the Kalman filter KF [1] can accurately and quickly estimate the state of the system. it can.
Figure 2013185898

なお、CPU10は、カメラ110が1つの物体Objを撮影した場合、実施形態(または変形例1〜4)に係る状態推定プログラム100を実行し、カメラ110が2つの物体Obj(物体Obj1、物体Obj2)を撮影した場合、変形例5に係る状態推定プログラムを実行してもよい。   Note that when the camera 110 captures one object Obj, the CPU 10 executes the state estimation program 100 according to the embodiment (or modified examples 1 to 4), and the camera 110 has two objects Obj (object Obj1, object Obj2). ) May be executed, the state estimation program according to Modification 5 may be executed.

(6)変形例6
上述した実施形態及び変形例に係る状態推定装置は、シグマポイントカルマンフィルタを用いて非線形カルマンフィルタの演算を実行するものであったが、本発明はこのような形態に限定されるものでは無く、拡張カルマンフィルタ等、公知の非線形カルマンフィルタを適宜適用して演算を行うものでもよい。
図8は、変形例6に係る状態推定プログラムを実行したときに実現される機能を表した機能ブロック図である。図8に示すように、変形例6に係る状態推定装置は、カルマンフィルタKF[m]の代わりにカルマンフィルタKFa[m]を備える点を除き、上述した実施形態及び変形例に係る状態推定装置と同様に構成される。カルマンフィルタKFa[m]は、状態遷移モデル部710を備える代わりに、状態遷移モデル部710aを備える点と、観測モデル部720を備える代わりに、観測モデル部720aを備える点とを除いて、カルマンフィルタKF[m]と同様に構成される。
状態遷移モデル部710aは、状態ベクトルx k−1を、式(23)に示す状態遷移モデルに適用することで、推定状態ベクトルx を算出する。観測モデル部720aは、推定状態ベクトルx を、式(24)に示す観測モデルに適用することにより、推定観測値ベクトルy を算出する。
このように、変形例6に係る非線形カルマンフィルタの演算では、複数のシグマポイントを生成することなく、状態ベクトルxを更新する。
(6) Modification 6
The state estimation device according to the above-described embodiment and the modification executes the operation of the nonlinear Kalman filter using the sigma point Kalman filter, but the present invention is not limited to such a form, and the extended Kalman filter For example, the calculation may be performed by appropriately applying a known nonlinear Kalman filter.
FIG. 8 is a functional block diagram showing functions realized when the state estimation program according to Modification 6 is executed. As illustrated in FIG. 8, the state estimation device according to the modification 6 is the same as the state estimation device according to the above-described embodiment and the modification, except that the Kalman filter KFa [m] is provided instead of the Kalman filter KF [m]. Configured. The Kalman filter KFa [m] is provided with a state transition model unit 710a instead of the state transition model unit 710 and a Kalman filter KF except for the point provided with the observation model unit 720a instead of the observation model unit 720. The configuration is the same as [m].
The state transition model unit 710a calculates the estimated state vector x k by applying the state vector x + k−1 to the state transition model shown in Expression (23). The observation model unit 720a calculates the estimated observation value vector y - k by applying the estimated state vector x - k to the observation model shown in Expression (24).
As described above, in the calculation of the nonlinear Kalman filter according to the modified example 6, the state vector x k is updated without generating a plurality of sigma points.

1…携帯機器、10…CPU、60…GPS部、70…3次元磁気センサ、80…3次元加速度センサ、90…3次元角速度センサ、100…状態推定プログラム、110…カメラ、200…初期値生成部、210…画像処理部、220…初期姿勢算出部、221…撮影対象情報取得部、222…姿勢計算部、230…初期ベクトル生成部、300…カルマンフィルタ演算部、400…出力情報制御部、500…出力情報生成部、q…磁気データ、Img…画像情報、Ps…位置情報、Pobj…情報、μ…姿勢、μ…姿勢μの初期値、x…状態ベクトル、y…観測値ベクトル、z…観測残差、α…第1方向ベクトル、β…第2方向ベクトル、Obj…物体、Σ…機器座標系、Σ…地上座標系。 DESCRIPTION OF SYMBOLS 1 ... Portable apparatus, 10 ... CPU, 60 ... GPS part, 70 ... 3D magnetic sensor, 80 ... 3D acceleration sensor, 90 ... 3D angular velocity sensor, 100 ... State estimation program, 110 ... Camera, 200 ... Initial value generation , 210 ... Image processing unit, 220 ... Initial posture calculation unit, 221 ... Shooting target information acquisition unit, 222 ... Posture calculation unit, 230 ... Initial vector generation unit, 300 ... Kalman filter operation unit, 400 ... Output information control unit, 500 ... Output information generation unit, q ... Magnetic data, Img ... Image information, Ps ... Position information, Pobj ... Information, µ ... Attitude, µ 0 ... Initial value of attitude µ, x ... State vector, y ... Observation value vector, z ... Observation residual, α ... First direction vector, β ... Second direction vector, Obj ... Object, Σ S ... Equipment coordinate system, Σ G ... Ground coordinate system.

Claims (5)

システムを観測して観測値を各々出力する複数のセンサと、位置情報を出力する位置情報出力部と、物体を撮影し画像情報を出力する画像取得部と、を備える機器に組み込まれ、前記システムの状態を推定する状態推定装置であって、
前記システムの状態を推定する値である複数の状態変数を要素とする状態ベクトルと、前記観測値の各々を要素とする観測値ベクトルとを用いて、前記状態ベクトルを更新するカルマンフィルタを1以上備えるカルマンフィルタ演算部と、
前記状態ベクトルの初期値である初期ベクトルを生成する初期値生成部と、
を備え、
前記複数の状態変数は、
前記機器の姿勢を推定する状態変数を含み、
前記初期値生成部は、
1以上の物体を前記画像取得部が撮影した際に前記画像取得部が出力する前記画像情報と、前記位置情報出力部が出力する前記位置情報と、に基づいて、前記機器の姿勢を推定する状態変数の初期値である初期姿勢推定値を算出し、前記初期姿勢推定値を要素とする前記初期ベクトルを生成する、
ことを特徴とする状態推定装置。
The system is incorporated in a device including a plurality of sensors that observe the system and output observation values, a position information output unit that outputs position information, and an image acquisition unit that images an object and outputs image information, A state estimation device for estimating the state of
One or more Kalman filters for updating the state vector using a state vector having a plurality of state variables as elements for estimating the state of the system and an observation value vector having each of the observation values as elements A Kalman filter operation unit;
An initial value generation unit that generates an initial vector that is an initial value of the state vector;
With
The plurality of state variables are:
Including a state variable that estimates the attitude of the device;
The initial value generator is
The posture of the device is estimated based on the image information output by the image acquisition unit when the image acquisition unit captures one or more objects and the position information output by the position information output unit. Calculating an initial posture estimated value that is an initial value of a state variable, and generating the initial vector having the initial posture estimated value as an element;
The state estimation apparatus characterized by the above-mentioned.
前記カルマンフィルタ演算部は、
並列に動作する所定数の前記カルマンフィルタを備え、
前記初期値生成部は、
前記画像取得部が、1の物体を撮影して前記画像情報を出力した場合に、前記画像情報に基づいて、前記機器に固定された3軸の座標系である機器座標系において、前記機器から見た前記1の物体の方向を表した第1方向ベクトルを算出する画像処理部と、
前記位置情報に基づいて、地球上に固定された3軸の座標系である地上座標系において、前記機器から見た前記1の物体の方向を表した第2方向ベクトルを算出し、前記第1方向ベクトル及び前記第2方向ベクトルに基づいて、初期姿勢候補値を算出し、前記初期姿勢候補値を、前記第2方向ベクトルを回転軸として所定角度ずつ回転させることで、前記所定数の前記初期姿勢推定値を算出する初期姿勢算出部と、
前記所定数の前記初期姿勢推定値の各々に対応する、前記所定数の前記初期ベクトルを生成し、これらを前記所定数の前記カルマンフィルタにそれぞれ供給する初期ベクトル生成部と、を備える、
ことを特徴とする請求項1に記載の状態推定装置。
The Kalman filter operation unit is
A predetermined number of the Kalman filters operating in parallel;
The initial value generator is
In the device coordinate system, which is a three-axis coordinate system fixed to the device, based on the image information, when the image acquisition unit captures one object and outputs the image information, from the device An image processing unit for calculating a first direction vector representing the direction of the one object seen;
Based on the position information, in a ground coordinate system that is a three-axis coordinate system fixed on the earth, a second direction vector representing the direction of the first object viewed from the device is calculated, and the first An initial posture candidate value is calculated based on the direction vector and the second direction vector, and the initial posture candidate value is rotated by a predetermined angle about the second direction vector as a rotation axis, whereby the predetermined number of the initial posture values are calculated. An initial posture calculation unit for calculating a posture estimation value;
An initial vector generation unit that generates the predetermined number of the initial vectors corresponding to each of the predetermined number of the initial posture estimation values, and supplies the initial vectors to the predetermined number of the Kalman filters, respectively.
The state estimation apparatus according to claim 1.
前記カルマンフィルタ演算部は、
1つの前記カルマンフィルタを備え、
前記初期値生成部は、
前記画像取得部が、2つの物体を撮影して前記画像情報を出力した場合に、前記画像情報に基づいて、前記機器に固定された3軸の座標系である機器座標系において、前記機器から見た前記2つの物体の各々の方向を表した2つの第1方向ベクトルを算出する画像処理部と、
前記位置情報に基づいて、地球上に固定された3軸の座標系である地上座標系において、前記機器から見た前記2つの物体の各々の方向を表した2つの第2方向ベクトルを算出し、前記2つの第1方向ベクトル及び前記2つの第2方向ベクトルに基づいて、前記初期姿勢推定値を算出する、初期姿勢算出部と、
前記初期姿勢推定値を要素とする前記初期ベクトルを生成し、これを前記カルマンフィルタに供給する初期ベクトル生成部と、を備える、
ことを特徴とする請求項1に記載の状態推定装置。
The Kalman filter operation unit is
Comprising one Kalman filter,
The initial value generator is
In the device coordinate system, which is a three-axis coordinate system fixed to the device, based on the image information, when the image acquisition unit captures two objects and outputs the image information, from the device An image processing unit for calculating two first direction vectors representing the directions of the two viewed objects,
Based on the position information, in the ground coordinate system, which is a three-axis coordinate system fixed on the earth, two second direction vectors representing the directions of the two objects viewed from the device are calculated. An initial posture calculating unit that calculates the initial posture estimated value based on the two first direction vectors and the two second direction vectors;
An initial vector generation unit that generates the initial vector having the initial posture estimated value as an element and supplies the initial vector to the Kalman filter;
The state estimation apparatus according to claim 1.
前記状態推定装置は、
時刻情報を出力する時刻出力部を備え、
前記初期姿勢算出部は、
前記位置情報と、前記時刻情報と、に基づいて、前記第2方向ベクトルを算出する、
ことを特徴とする請求項2または3に記載の状態推定装置。
The state estimation device includes:
A time output unit for outputting time information;
The initial posture calculation unit
Calculating the second direction vector based on the position information and the time information;
The state estimation apparatus according to claim 2 or 3, wherein
前記物体は、
前記地上座標系における座標が既知であり、
前記初期姿勢算出部は、前記位置情報と、前記物体の前記地上座標系における座標とに基づいて、前記第2方向ベクトルを算出する、
ことを特徴とする請求項2または3に記載の状態推定装置。
The object is
The coordinates in the ground coordinate system are known;
The initial posture calculating unit calculates the second direction vector based on the position information and coordinates of the object in the ground coordinate system;
The state estimation apparatus according to claim 2 or 3, wherein
JP2012050297A 2012-03-07 2012-03-07 State estimation device Pending JP2013185898A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2012050297A JP2013185898A (en) 2012-03-07 2012-03-07 State estimation device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2012050297A JP2013185898A (en) 2012-03-07 2012-03-07 State estimation device

Publications (1)

Publication Number Publication Date
JP2013185898A true JP2013185898A (en) 2013-09-19

Family

ID=49387456

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2012050297A Pending JP2013185898A (en) 2012-03-07 2012-03-07 State estimation device

Country Status (1)

Country Link
JP (1) JP2013185898A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016169991A (en) * 2015-03-12 2016-09-23 株式会社ゼンリンデータコム Route guidance device, route guidance method, and route guidance program
WO2020050084A1 (en) * 2018-09-07 2020-03-12 国立研究開発法人宇宙航空研究開発機構 Storage medium having guidance control program stored thereon
JP2020528553A (en) * 2017-07-26 2020-09-24 シスナヴ How to calibrate the magnetometer
CN113711280A (en) * 2019-04-15 2021-11-26 索尼集团公司 Information processing device, information processing method, communication terminal, communication method, and program
CN114370870A (en) * 2022-01-05 2022-04-19 中国兵器工业计算机应用技术研究所 Filter updating information screening method suitable for pose measurement Kalman filtering

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016169991A (en) * 2015-03-12 2016-09-23 株式会社ゼンリンデータコム Route guidance device, route guidance method, and route guidance program
JP2020528553A (en) * 2017-07-26 2020-09-24 シスナヴ How to calibrate the magnetometer
JP7112482B2 (en) 2017-07-26 2022-08-03 シスナヴ How to calibrate a magnetometer
WO2020050084A1 (en) * 2018-09-07 2020-03-12 国立研究開発法人宇宙航空研究開発機構 Storage medium having guidance control program stored thereon
CN113711280A (en) * 2019-04-15 2021-11-26 索尼集团公司 Information processing device, information processing method, communication terminal, communication method, and program
CN114370870A (en) * 2022-01-05 2022-04-19 中国兵器工业计算机应用技术研究所 Filter updating information screening method suitable for pose measurement Kalman filtering
CN114370870B (en) * 2022-01-05 2024-04-12 中国兵器工业计算机应用技术研究所 Filter update information screening method suitable for pose measurement Kalman filtering

Similar Documents

Publication Publication Date Title
CN111156998B (en) Mobile robot positioning method based on RGB-D camera and IMU information fusion
LaValle et al. Head tracking for the Oculus Rift
Michel et al. A comparative analysis of attitude estimation for pedestrian navigation with smartphones
Michel et al. Attitude estimation for indoor navigation and augmented reality with smartphones
CN108846857A (en) The measurement method and visual odometry of visual odometry
JP2014089113A (en) Posture estimation device and program
JP2020528553A (en) How to calibrate the magnetometer
US20140222369A1 (en) Simplified method for estimating the orientation of an object, and attitude sensor implementing such a method
JP2013064695A (en) State estimating device, offset updating method, and offset updating program
JP2013185898A (en) State estimation device
CN110352331A (en) The method and clouds terrace system of the attitude algorithm of hand-held holder
JP2017036970A (en) Information processor, information processing method, and program
Haslwanter 3D Kinematics
Nusbaum et al. Control theoretic approach to gyro-free inertial navigation systems
Troni et al. Magnetometer bias calibration based on relative angular position: Theory and experimental comparative evaluation
JP2013096724A (en) State estimation device
Peng et al. Design of an embedded icosahedron mechatronics for robust iterative IMU calibration
JP5870656B2 (en) Trajectory calculation device and trajectory calculation method
JP2013122384A (en) Kalman filter and state estimation device
KR100563948B1 (en) Apparatus for attitude determination test of star-sensor and method for display of imaginary constellation
Irmisch et al. Simulation framework for a visual-inertial navigation system
JP2015118101A (en) Information processing device and method and program
CN211601925U (en) Angular deviation measuring system
CN111238439B (en) Angular deviation measuring system
JP2013061309A (en) Kalman filter, state estimation device, method for controlling kalman filter, and control program of kalman filter