JP2017181218A - Portable terminal, program and method estimating forward direction of users using angular velocity sensor - Google Patents

Portable terminal, program and method estimating forward direction of users using angular velocity sensor Download PDF

Info

Publication number
JP2017181218A
JP2017181218A JP2016066935A JP2016066935A JP2017181218A JP 2017181218 A JP2017181218 A JP 2017181218A JP 2016066935 A JP2016066935 A JP 2016066935A JP 2016066935 A JP2016066935 A JP 2016066935A JP 2017181218 A JP2017181218 A JP 2017181218A
Authority
JP
Japan
Prior art keywords
matrix
angular velocity
posture matrix
error
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.)
Granted
Application number
JP2016066935A
Other languages
Japanese (ja)
Other versions
JP6516332B2 (en
Inventor
義浩 伊藤
Yoshihiro Ito
義浩 伊藤
大輔 上坂
Daisuke Kamisaka
大輔 上坂
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.)
KDDI Corp
Original Assignee
KDDI 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 KDDI Corp filed Critical KDDI Corp
Priority to JP2016066935A priority Critical patent/JP6516332B2/en
Publication of JP2017181218A publication Critical patent/JP2017181218A/en
Application granted granted Critical
Publication of JP6516332B2 publication Critical patent/JP6516332B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Navigation (AREA)

Abstract

PROBLEM TO BE SOLVED: To provide a portable terminal, a program and a method that estimate a turnaround of a user during moving along a passage on a map using an angular velocity sensor in accordance with a time elapse.SOLUTION: A portable terminal includes: map data storage means that stores a correct direction beforehand; angular velocity pose matrix calculation means that calculates an angular velocity pose matrix qat a time t from a matrix qexpressing rotation of a terminal pose on the basis of an angular velocity vector, and a terminal pose matrix qat a time t-1; forward direction estimation means that estimates a forward direction from the angular velocity pose matrix q; direction error calculation means that calculates a direction error Eserving as a difference between a correct direction and the forward direction; and error pose matrix calculation means calculates an error pose matrix qfrom an error having the angular velocity pose matrix qweighted with the direction error E, and feeds back and inputs the error pose matrix qto the angular velocity pose matrix calculation means at the time t+1 as a final terminal pose matrix qat the time t.SELECTED DRAWING: Figure 2

Description

本発明は、角速度センサを用いて、ユーザの動向を検出する技術に関する。   The present invention relates to a technique for detecting a user's trend using an angular velocity sensor.

従来、モーションセンサ(加速度センサ、角速度センサ)を用いて、現在位置を推定する技術がある(例えば特許文献1参照)。この技術によれば、モーションセンサから生成された波形に基づく進行速度と、実際の進行速度との間の誤差を用いて、現在位置を推定する。具体的には、端末姿勢だけでなくジャイロオフセット(ドリフト)も含めて、カルマンフィルタを用いた歩行者測位を実現している。   Conventionally, there is a technique for estimating a current position using a motion sensor (acceleration sensor, angular velocity sensor) (see, for example, Patent Document 1). According to this technique, the current position is estimated using an error between the traveling speed based on the waveform generated from the motion sensor and the actual traveling speed. Specifically, pedestrian positioning using the Kalman filter is realized including not only the terminal posture but also gyro offset (drift).

図1は、従来技術における携帯端末の機能構成図である。   FIG. 1 is a functional configuration diagram of a portable terminal in the prior art.

図1によれば、角速度センサによって推定された現在位置を、地図情報にマッピングすることによって補正する技術が表されている。この技術によれば、携帯端末は、進行可能な通路情報をマップデータとして記憶している。その上で、角速度センサの変化量及び積算値に基づいて算出された携帯端末の前方方向の向きから、コーナーを検出する。具体的には、一定時間以内に一定以上向きが変化した際に、コーナーとして検出する。検出されたコーナーは、地図情報に応じた進行方向をマッチングによって推定する。例えば十字通路があった場合、そのコーナーでの進行方向は、直進、90度、−90度の選択肢のいずれか1つに特定される。この推定結果に応じて、ユーザの前方方向が推定され、アプリケーションによってその方向に応じたサービスが提供される。   FIG. 1 shows a technique for correcting a current position estimated by an angular velocity sensor by mapping it to map information. According to this technology, the portable terminal stores the advancing path information as map data. Then, a corner is detected from the forward direction of the mobile terminal calculated based on the change amount and integrated value of the angular velocity sensor. Specifically, it is detected as a corner when the direction changes more than a certain time within a certain time. For the detected corner, the traveling direction corresponding to the map information is estimated by matching. For example, when there is a cross passage, the traveling direction at the corner is specified as one of the options of straight ahead, 90 degrees, and -90 degrees. The user's forward direction is estimated according to the estimation result, and a service corresponding to the direction is provided by the application.

特開2014−167461号公報JP 2014-167461 A

「スマートフォン内蔵センサーを用いた複数フロアーデッドレコニング」マルチメディア、分散協調とモバイルシンポジウム2013論文集 2013, 723 - 735, 2013-07-03"Multiple floor dead reckoning using sensors with built-in smartphones" Multimedia, Distributed Cooperation and Mobile Symposium 2013 Proceedings 2013, 723-735, 2013-07-03 「カルマンフィルタ」、[online]、[平成28年3月11日検索]、インターネット<URL:https://ja.wikipedia.org/wiki/%E3%82%AB%E3%83%AB%E3%83%9E%E3%83%B3%E3%83%95%E3%82%A3%E3%83%AB%E3%82%BF%E3%83%BC>“Kalman Filter”, [online], [Search on March 11, 2016], Internet <URL: https://en.wikipedia.org/wiki/%E3%82%AB%E3%83%AB%E3% 83% 9E% E3% 83% B3% E3% 83% 95% E3% 82% A3% E3% 83% AB% E3% 82% BF% E3% 83% BC> 「初心者の、初心者による、初心者のためのカルマンフィルタ」、[online]、[平成28年3月11日検索]、インターネット<URL:http://www1.accsnet.ne.jp/~aml00731/kalman.pdf>"Beginner, Kalman filter for beginners by beginners", [online], [Search March 11, 2016], Internet <URL: http://www1.accsnet.ne.jp/~aml00731/kalman. pdf> 「クォータニオン便利ノート」、[online]、[平成28年3月11日検索]、インターネット<URL:http://www.mss.co.jp/technology/report/pdf/18-07.pdf>"Quaternion convenience note", [online], [March 11, 2016 search], Internet <URL: http: //www.mss.co.jp/technology/report/pdf/18-07.pdf>

しかしながら、前述した従来技術によれば、「人は地図上の通路に沿って移動し、コーナーでのみ方向転換をする」という前提に基づいている。そのために、携帯端末を所持するユーザが、例えば十字通路で、人を避けるなどの想定外の動きをした際に、前方方向を誤判定してしまうという問題があった。角速度センサのみの位置推定によれば、一度でもコーナーを誤判定してしまうと、その後、本来の位置と大幅にずれた位置で測位され続けることとなる。
また、十字通路で進行方向を誤判定しなかったとしても、前方方向は常に地図情報に基づく方向のみを候補として出力する。そのために、例えば直進中に人を避けるといった動作までも検出することは難しい。
However, according to the above-described prior art, it is based on the premise that “a person moves along a path on a map and changes direction only at a corner”. For this reason, there is a problem that when the user who holds the mobile terminal makes an unexpected movement such as avoiding a person in the cross passage, for example, the forward direction is erroneously determined. According to the position estimation using only the angular velocity sensor, if the corner is erroneously determined even once, then the position is continuously measured at a position significantly deviated from the original position.
Even if the traveling direction is not erroneously determined in the cross passage, the forward direction always outputs only the direction based on the map information as a candidate. Therefore, it is difficult to detect even an operation such as avoiding a person while traveling straight ahead.

これに対し、本願の発明者らは、コーナーにおけるユーザの方向転換が、地図上の通路に沿うことを前提としていることに問題があるのではないか?と考えた。即ち、移動中のユーザにおけるコーナーでの方向転換が検出された際に、時間経過の中で緩やかな方向転換として判定すべきではないか?と考えた。特に、角速度センサにおけるコーナー判定を誤った場合であっても、前方方向の推定性能における大幅な劣化を防ぐことができないか?と考えた。   On the other hand, the inventors of the present application may have a problem that the direction change of the user at the corner is assumed to be along a path on the map. I thought. That is, when a change of direction at a corner of a moving user is detected, should it be determined as a gradual change of direction over time? I thought. In particular, is it possible to prevent a significant deterioration in the estimation performance in the forward direction even when the corner determination in the angular velocity sensor is wrong? I thought.

そこで、本発明は、角速度センサを用いて、地図上の通路に沿った移動中のユーザの方向転換を、時間経過に応じて推定する携帯端末、プログラム及び方法を提供することを目的とする。   Therefore, an object of the present invention is to provide a portable terminal, a program, and a method for estimating the direction change of a user who is moving along a path on a map according to the passage of time using an angular velocity sensor.

本発明によれば、角速度センサを有し、ユーザの前方方向を推定する携帯端末であって、
正解方向を予め記憶したマップデータ記憶手段と、
角速度センサによって計測された角速度ベクトルに基づく端末姿勢の回転を表す行列qgyroと、時刻t-1における端末姿勢行列qt-1とから、時刻tにおける角速度姿勢行列qt gyroを算出する角速度姿勢行列算出手段と、
角速度姿勢行列qt gyroから前方方向を推定する前方方向推定手段と、
正解方向と前方方向との差分となる方向誤差Etを算出する方向誤差算出手段と、
角速度姿勢行列qt gyroに方向誤差Etで重み付けた誤差から誤差姿勢行列qt errを算出し、当該誤差姿勢行列qt errを時刻tにおける最終的な端末姿勢行列qtとして、時刻t+1における角速度姿勢行列算出手段へフィードバックして入力する誤差姿勢行列算出手段と
を有することを特徴とする。
According to the present invention, the portable terminal has an angular velocity sensor and estimates the user's forward direction,
Map data storage means for storing the correct answer direction in advance;
Angular velocity posture for calculating angular velocity posture matrix q t gyro at time t from matrix q gyro representing rotation of the terminal posture based on the angular velocity vector measured by the angular velocity sensor and terminal posture matrix q t-1 at time t−1 Matrix calculation means;
Forward direction estimating means for estimating the forward direction from the angular velocity posture matrix q t gyro ;
A direction error calculating means for calculating a direction error E t which is a difference between the correct direction and the forward direction,
Calculates an error posture matrix q t err from errors weighted by direction error E t to the angular velocity posture matrix q t Gyro, as the final terminal attitude matrix q t the error posture matrix q t err at time t, the time t + And an error posture matrix calculation means for feeding back to the angular velocity posture matrix calculation means in 1.

本発明の携帯端末における他の実施形態によれば、
前方方向推定手段によって推定された前方方向を、アプリケーションへ出力することも好ましい。
According to another embodiment of the mobile terminal of the present invention,
It is also preferable to output the forward direction estimated by the forward direction estimation means to the application.

本発明の携帯端末における他の実施形態によれば、
誤差姿勢行列算出手段から出力された誤差姿勢行列qtから、前方方向を推定する付加的前方方向推定手段を更に有し、
付加的前方方向推定手段によって推定された前方方向を、アプリケーションへ出力することも好ましい。
According to another embodiment of the mobile terminal of the present invention,
Additional forward direction estimating means for estimating the forward direction from the error posture matrix q t output from the error posture matrix calculating means,
It is also preferable to output the forward direction estimated by the additional forward direction estimation means to the application.

本発明の携帯端末における他の実施形態によれば、
誤差姿勢行列算出手段は、
方向誤差Etに対する所定の単位補正割合rの単位補正角度rEtを算出し、
角速度姿勢行列qt gyroに、単位補正角度rEtだけ鉛直軸回りへの回転を表す姿勢行列を積算して、誤差姿勢行列qt errを算出することも好ましい。
According to another embodiment of the mobile terminal of the present invention,
The error posture matrix calculation means is
A unit correction angle rE t of a predetermined unit correction ratio r with respect to the direction error E t is calculated,
It is also preferable to calculate the error posture matrix q t err by adding the posture matrix representing the rotation about the vertical axis by the unit correction angle rE t to the angular velocity posture matrix q t gyro .

本発明の携帯端末における他の実施形態によれば、
角速度姿勢行列算出手段は、カルマンフィルタを用いて姿勢行列を算出することも好ましい。
According to another embodiment of the mobile terminal of the present invention,
The angular velocity posture matrix calculation means preferably calculates the posture matrix using a Kalman filter.

本発明の携帯端末における他の実施形態によれば、
加速度センサと、
加速度センサによって計測された重力ベクトルgaccと、角速度姿勢行列qt gyroから推定された重力ベクトルh(qt gyro)との差分et accを用いて、角速度姿勢行列qt gyroから、加速度姿勢行列qt accを算出する加速度姿勢行列算出手段と
を更に有し、
誤差姿勢行列算出手段は、角速度姿勢行列qt gyroに代えて、加速度姿勢行列qt accから誤差姿勢行列qt errを算出することも好ましい。
According to another embodiment of the mobile terminal of the present invention,
An acceleration sensor;
From the angular velocity posture matrix q t gyro using the difference e t acc between the gravity vector g acc measured by the acceleration sensor and the gravity vector h (q t gyro ) estimated from the angular velocity posture matrix q t gyro An acceleration posture matrix calculating means for calculating a matrix q t acc ,
The error posture matrix calculating means preferably calculates the error posture matrix q t err from the acceleration posture matrix q t acc instead of the angular velocity posture matrix q t gyro .

本発明の携帯端末における他の実施形態によれば、
誤差姿勢行列算出手段は、
方向誤差Etに対する所定の単位補正割合rの単位補正角度rEtを算出し、
加速度姿勢行列qt accに、単位補正角度rEtだけ鉛直軸回りへの回転を表す姿勢行列を積算して、誤差姿勢行列qt errを算出することも好ましい。
According to another embodiment of the mobile terminal of the present invention,
The error posture matrix calculation means is
A unit correction angle rE t of a predetermined unit correction ratio r with respect to the direction error E t is calculated,
It is also preferable to calculate an error posture matrix q t err by adding a posture matrix representing rotation about the vertical axis by the unit correction angle rE t to the acceleration posture matrix q t acc .

本発明の携帯端末における他の実施形態によれば、
角速度姿勢行列算出手段及び加速度姿勢行列算出手段は、カルマンフィルタを用いて姿勢行列を算出することも好ましい。
According to another embodiment of the mobile terminal of the present invention,
The angular velocity posture matrix calculating unit and the acceleration posture matrix calculating unit preferably calculate the posture matrix using a Kalman filter.

本発明の携帯端末における他の実施形態によれば、
誤差姿勢行列算出手段は、
正解方向の姿勢行列qt correctと、加速度姿勢行列qt accとの間の残差eerr tを算出し、
加速度姿勢行列算出手段のカルマンフィルタによって算出された共分散行列Pt accを用いて、最適カルマンゲインKt errを算出し、
加速度姿勢行列qt accから、残差eerr t及び最適カルマンゲインKt errの積に基づく誤差姿勢行列qt errを算出し、
共分散行列Pt accから、最適カルマンゲインKt errに基づく共分散行列Pt errを算出し、
更に、Pt errを時刻tにおける最終的な端末姿勢行列の共分散行列Ptとして、時刻t+1における角速度姿勢行列算出手段へフィードバックする
ことも好ましい。
According to another embodiment of the mobile terminal of the present invention,
The error posture matrix calculation means is
Calculate the residual e err t between the correct posture matrix q t correct and the acceleration posture matrix q t acc
An optimal Kalman gain K t err is calculated using the covariance matrix P t acc calculated by the Kalman filter of the acceleration posture matrix calculating means,
From the acceleration posture matrix q t acc, calculates an error posture matrix q t err based on the product of the residual e err t and the optimal Kalman gain K t err,
From the covariance matrix P t acc, to calculate the covariance matrix P t err based on optimal Kalman gain K t err,
Furthermore, it is also preferable to feed back P t err to the angular velocity posture matrix calculating means at time t + 1 as the final terminal posture matrix covariance matrix P t at time t.

本発明の携帯端末における他の実施形態によれば、
端末姿勢行列であるqt及びqt gyro,qt acc,qt errは、スカラー部及びベクトル部によって表現したクォータニオン(四元数)であることも好ましい。
According to another embodiment of the mobile terminal of the present invention,
The terminal attitude matrices q t and q t gyro , q t acc , q t err are preferably quaternions (quaternions) expressed by a scalar part and a vector part.

本発明の携帯端末における他の実施形態によれば、
マップデータ記憶手段の正解方向は、当該携帯端末の位置から通路方向に応じた1つ以上の進行可能な方向であることも好ましい。
According to another embodiment of the mobile terminal of the present invention,
The correct answer direction of the map data storage means is also preferably one or more advancing directions according to the direction of the passage from the position of the mobile terminal.

本発明の携帯端末における他の実施形態によれば、
加速度センサによって計測された加速度ベクトルaを端末座標系における重力方向とみなすことで、初期の角速度姿勢行列q0を算出し、当該角速度姿勢行列q0を角速度姿勢行列算出手段へ出力する初期姿勢行列算出手段を
更に有することも好ましい。
According to another embodiment of the mobile terminal of the present invention,
An initial posture matrix that calculates an initial angular velocity posture matrix q 0 and outputs the angular velocity posture matrix q 0 to the angular velocity posture matrix calculation means by regarding the acceleration vector a measured by the acceleration sensor as the gravity direction in the terminal coordinate system. It is also preferable to further have a calculation means.

本発明によれば、角速度センサを有し、ユーザの前方方向を推定する装置に搭載されたコンピュータを機能させるプログラムであって、
正解方向を予め記憶したマップデータ記憶手段と、
角速度センサによって計測された角速度ベクトルに基づく端末姿勢の回転を表す行列qgyroと、時刻t-1における端末姿勢行列qt-1とから、時刻tにおける角速度姿勢行列qt gyroを算出する角速度姿勢行列算出手段と、
角速度姿勢行列qt gyroから前方方向を推定する前方方向推定手段と、
正解方向と前方方向との差分となる方向誤差Etを算出する方向誤差算出手段と、
角速度姿勢行列qt gyroに方向誤差Etで重み付けた誤差から誤差姿勢行列qt errを算出し、当該誤差姿勢行列qt errを時刻tにおける最終的な端末姿勢行列qtとして、時刻t+1における角速度姿勢行列算出手段へフィードバックして入力する誤差姿勢行列算出手段と
してコンピュータを機能させることを特徴とする。
According to the present invention, there is provided a program for causing a computer mounted on a device having an angular velocity sensor and estimating a user's forward direction to function.
Map data storage means for storing the correct answer direction in advance;
Angular velocity posture for calculating angular velocity posture matrix q t gyro at time t from matrix q gyro representing rotation of the terminal posture based on the angular velocity vector measured by the angular velocity sensor and terminal posture matrix q t-1 at time t−1 Matrix calculation means;
Forward direction estimating means for estimating the forward direction from the angular velocity posture matrix q t gyro ;
A direction error calculating means for calculating a direction error E t which is a difference between the correct direction and the forward direction,
Calculates an error posture matrix q t err from errors weighted by direction error E t to the angular velocity posture matrix q t Gyro, as the final terminal attitude matrix q t the error posture matrix q t err at time t, the time t + The computer is caused to function as an error posture matrix calculation unit that feeds back and inputs to the angular velocity posture matrix calculation unit in 1.

本発明のプログラムにおける他の実施形態によれば、
装置は、加速度センサを更に有し、
加速度センサによって計測された重力ベクトルgaccと、角速度姿勢行列qt gyroから推定された重力ベクトルh(qt gyro)との差分et accを用いて、角速度姿勢行列qt gyroから、加速度姿勢行列qt accを算出する加速度姿勢行列算出手段と
してコンピュータを更に機能させ
誤差姿勢行列算出手段は、角速度姿勢行列qt gyroに代えて、加速度姿勢行列qt accから誤差姿勢行列qt errを算出する
ようにコンピュータを機能させることも好ましい。
According to another embodiment of the program of the present invention,
The apparatus further comprises an acceleration sensor,
From the angular velocity posture matrix q t gyro using the difference e t acc between the gravity vector g acc measured by the acceleration sensor and the gravity vector h (q t gyro ) estimated from the angular velocity posture matrix q t gyro The computer further functions as an acceleration posture matrix calculation means for calculating the matrix q t acc. The error posture matrix calculation means calculates the error posture matrix q t err from the acceleration posture matrix q t acc instead of the angular velocity posture matrix q t gyro. It is also preferable to make the computer function like this.

本発明によれば、角速度センサを有する装置の前方方向推定方法であって、
装置は、正解方向を予め記憶したマップデータ記憶部を有し、
装置は、
角速度センサによって計測された角速度ベクトルに基づく端末姿勢の回転を表す行列qgyroと、時刻t-1における端末姿勢行列qt-1とから、時刻tにおける角速度姿勢行列qt gyroを算出する第1のステップと、
角速度姿勢行列qt gyroから前方方向を推定する第2のステップと、
正解方向と前方方向との差分となる方向誤差Etを算出する第3のステップと、
角速度姿勢行列qt gyroに方向誤差Etで重み付けた誤差から誤差姿勢行列qt errを算出し、当該誤差姿勢行列qt errを時刻tにおける最終的な端末姿勢行列qtとして、時刻t+1における第1のステップへフィードバックして入力する第4のステップと
を実行することを特徴とする。
According to the present invention, there is provided a method for estimating a forward direction of an apparatus having an angular velocity sensor,
The apparatus has a map data storage unit that stores the correct answer direction in advance,
The device
A first angular velocity posture matrix q t gyro at time t is calculated from a matrix q gyro representing the rotation of the terminal posture based on the angular velocity vector measured by the angular velocity sensor and the terminal posture matrix q t-1 at time t−1. And the steps
A second step of estimating the forward direction from the angular velocity posture matrix q t gyro ;
A third step of calculating a direction error E t which is a difference between the correct direction and the forward direction,
Calculates an error posture matrix q t err from errors weighted by direction error E t to the angular velocity posture matrix q t Gyro, as the final terminal attitude matrix q t the error posture matrix q t err at time t, the time t + And a fourth step of feeding back to the first step in step 1 and executing the fourth step.

本発明の前方方向推定方法における他の実施形態によれば、
装置は、加速度センサを更に有し、
装置は、
加速度センサによって計測された重力ベクトルgaccと、角速度姿勢行列qt gyroから推定された重力ベクトルh(qt gyro)との差分et accを用いて、角速度姿勢行列qt gyroから、加速度姿勢行列qt accを算出するステップを更に実行し、
第4のステップは、角速度姿勢行列qt gyroに代えて、加速度姿勢行列qt accから誤差姿勢行列qt errを算出することも好ましい。
According to another embodiment of the forward direction estimation method of the present invention,
The apparatus further comprises an acceleration sensor,
The device
From the angular velocity posture matrix q t gyro using the difference e t acc between the gravity vector g acc measured by the acceleration sensor and the gravity vector h (q t gyro ) estimated from the angular velocity posture matrix q t gyro Further performing the step of calculating the matrix q t acc ;
In the fourth step, it is also preferable to calculate the error posture matrix q t err from the acceleration posture matrix q t acc instead of the angular velocity posture matrix q t gyro .

本発明の携帯端末、プログラム及び方法によれば、角速度センサを用いて、地図上の通路に沿った移動中のユーザの方向転換を、時間経過に応じて推定することができる。また、角速度センサにおけるコーナー判定を徐々に決定するために、前方方向の推定性能における大幅な劣化を防ぐことができる。   According to the mobile terminal, the program, and the method of the present invention, it is possible to estimate the direction change of the user who is moving along the path on the map according to the passage of time using the angular velocity sensor. In addition, since the corner determination in the angular velocity sensor is gradually determined, it is possible to prevent a significant deterioration in the estimation performance in the forward direction.

従来技術における携帯端末の機能構成図である。It is a functional block diagram of the portable terminal in a prior art. 本発明における携帯端末の第1の機能構成図である。It is a 1st functional block diagram of the portable terminal in this invention. 図2における各機能部の算出式を表す説明図である。It is explanatory drawing showing the calculation formula of each function part in FIG. 携帯端末に対する端末座標系と世界座標系とを表す説明図である。It is explanatory drawing showing the terminal coordinate system with respect to a portable terminal, and a world coordinate system. 本発明における前方方向の推定を表す説明図である。It is explanatory drawing showing estimation of the front direction in this invention. 本発明における携帯端末の第2の機能構成図である。It is a 2nd function block diagram of the portable terminal in this invention.

以下では、図面を用いて、本発明を実施するための形態について詳細に説明する。   Below, the form for implementing this invention is demonstrated in detail using drawing.

図2は、本発明における携帯端末の第1の機能構成図である。
図3は、図2における各機能部の算出式を表す説明図である。
FIG. 2 is a first functional configuration diagram of the mobile terminal according to the present invention.
FIG. 3 is an explanatory diagram illustrating calculation formulas of the respective functional units in FIG.

図2によれば、ユーザに所持される携帯端末1は、スマートフォンのような端末であって、ハードウェアとして、角速度センサ101と、加速度センサ102とを有する。また、携帯端末1は、ソフトウェアとしてユーザの前方方向を推定するものであって、初期姿勢算出部11と、角速度姿勢行列算出部12と、加速度姿勢行列算出部13と、前方方向推定部14と、方向誤差算出部15と、マップデータ記憶部150と、誤差姿勢行列算出部16と、付加的前方方向推定部17とを有する。これら機能構成部は、携帯端末に搭載されたコンピュータを機能させるプログラムを実行することによって実現される。また、これら機能構成部の処理の流れは、装置の前方方向推定方法としても理解できる。   According to FIG. 2, the portable terminal 1 possessed by the user is a terminal such as a smartphone, and includes an angular velocity sensor 101 and an acceleration sensor 102 as hardware. The mobile terminal 1 estimates the user's forward direction as software, and includes an initial posture calculation unit 11, an angular velocity posture matrix calculation unit 12, an acceleration posture matrix calculation unit 13, and a forward direction estimation unit 14. A direction error calculation unit 15, a map data storage unit 150, an error posture matrix calculation unit 16, and an additional forward direction estimation unit 17. These functional components are realized by executing a program that causes a computer mounted on the mobile terminal to function. Further, the processing flow of these functional components can also be understood as a method for estimating the forward direction of the apparatus.

[角速度センサ101]
角速度センサ101は、基準軸に対する回転運動を検出するセンサであって、角度又は角速度を出力する。携帯端末に搭載可能な角速度センサは、一般に、MEMS(micro electro mechanical systems)で構成されており、物体の運動軸と回転軸との直交方向に働く力を計測することができる。
[Angular velocity sensor 101]
The angular velocity sensor 101 is a sensor that detects a rotational movement with respect to a reference axis, and outputs an angle or an angular velocity. An angular velocity sensor that can be mounted on a mobile terminal is generally composed of MEMS (micro electro mechanical systems), and can measure a force acting in a direction orthogonal to the motion axis and the rotation axis of an object.

時刻tにおける角速度センサ101から計測される角速度ベクトルは、以下のように表される。
ωt=(ωx ωy ωz)
角速度ωについて、角速度センサのサンプリングレートfに対する時刻tにおける端末回転量Δθtは、以下のように表される。
Δθt=ωt/f
この回転は、端末座標系について、Δθt/|Δθt|を回転の軸として、|Δθt|の大きさだけ回転させたものである。
The angular velocity vector measured from the angular velocity sensor 101 at time t is expressed as follows.
ω t = (ωx ωy ωz)
With respect to the angular velocity ω, the terminal rotation amount Δθ t at the time t with respect to the sampling rate f of the angular velocity sensor is expressed as follows.
Δθ t = ω t / f
This rotation, the terminal coordinate system, [Delta] [theta] t / | as the axis of rotation of, | | [Delta] [theta] t is obtained by rotating only the magnitude | [Delta] [theta] t.

[加速度センサ102]
加速度センサ102は、端末姿勢を検出するべく、3次元(3軸)の加速度(単位時間当たりの速度の変化)を計測する。
時刻tにおける加速度センサ102から計測される加速度ベクトルは、以下のように表される。
t=(xt,yt,zt
[Acceleration sensor 102]
The acceleration sensor 102 measures three-dimensional (three-axis) acceleration (change in speed per unit time) in order to detect the terminal posture.
The acceleration vector measured from the acceleration sensor 102 at time t is expressed as follows.
a t = (x t , y t , z t )

[初期姿勢算出部11]
初期姿勢算出部11は、携帯端末の初期姿勢を決定する。初期姿勢としては、加速度センサ102によって計測された加速度ベクトルaを、端末座標系における重力方向gとみなす。端末姿勢は、重力方向gを鉛直方向下向きとして決定される。
[Initial posture calculation unit 11]
The initial posture calculation unit 11 determines the initial posture of the mobile terminal. As the initial posture, the acceleration vector a measured by the acceleration sensor 102 is regarded as the gravity direction g in the terminal coordinate system. The terminal posture is determined with the gravity direction g facing downward in the vertical direction.

具体的には、初期姿勢行列(クォータニオン)q0は、以下のように算出される。
g:重力ベクトル(=(0,0,−1))
a:加速度センサから得られた加速度ベクトル

na=a/|a| (|x|はベクトルxの大きさを表す)
h=g+na/|g+na|
0=(na・h,na×h) (・は内積、×は外積)
端末姿勢行列であるqt(以下で記述するqt gyro,qt acc,qt errも同様)は、スカラー部及びベクトル部によって表現したクォータニオン(四元数)である(例えば非特許文献4参照)。
Specifically, the initial posture matrix (quaternion) q 0 is calculated as follows.
g: Gravity vector (= (0,0, -1))
a: Acceleration vector obtained from the acceleration sensor

na = a / | a | (| x | represents the magnitude of the vector x)
h = g + na / | g + na |
q 0 = (na · h, na × h) (• is an inner product, × is an outer product)
The terminal attitude matrix q t (the same applies to q t gyro , q t acc , and q t err described below) is a quaternion expressed by a scalar part and a vector part (for example, Non-Patent Document 4). reference).

そして、計測された初期の角速度姿勢行列q0を、角速度姿勢行列算出部12へ出力する。尚、初期姿勢が誤っていても、時間経過とともに正しい姿勢に修正される。そのために、初期姿勢算出部11は、必須ではなく、固定の初期姿勢を与えてもよい。 Then, the measured initial angular velocity posture matrix q 0 is output to the angular velocity posture matrix calculation unit 12. Even if the initial posture is incorrect, it is corrected to the correct posture over time. Therefore, the initial posture calculation unit 11 is not essential and may give a fixed initial posture.

[角速度姿勢行列算出部12]
角速度姿勢行列算出部12は、角速度センサ101によって計測された角速度ベクトルに基づく端末姿勢の回転を表す行列qgyroと、時刻t-1における端末姿勢行列qt-1とから、時刻tにおける角速度姿勢行列qt gyroを算出する。
t gyro=qgyro×qt-1
×:クォータニオンの積の演算子
時刻t-1における端末姿勢行列qt-1は、誤差姿勢行列算出部16から入力される。
そして、算出された角速度姿勢行列qt gyroは、加速度姿勢行列算出部13へ出力される。
[Angular Velocity Posture Matrix Calculation Unit 12]
The angular velocity posture matrix calculation unit 12 calculates the angular velocity posture at time t from the matrix q gyro representing the rotation of the terminal posture based on the angular velocity vector measured by the angular velocity sensor 101 and the terminal posture matrix q t-1 at time t−1. The matrix q t gyro is calculated.
q t gyro = q gyro × q t-1
×: Operator of quaternion product The terminal posture matrix q t−1 at time t−1 is input from the error posture matrix calculating unit 16.
Then, the calculated angular velocity posture matrix q t gyro is output to the acceleration posture matrix calculation unit 13.

[加速度姿勢行列算出部13]
加速度姿勢行列算出部13は、加速度センサ102によって計測された重力ベクトルgaccと、角速度姿勢行列qt gyroから推定された重力ベクトルh(qt gyro)との差分et accを用いて、角速度姿勢行列qt gyroから、加速度姿勢行列qt accを算出する。
t acc=qt gyro+Kt acct acc
算出された加速度姿勢行列qt accは、前方方向推定部14及び誤差姿勢行列算出部16へ出力される。qt accは、補正前の端末姿勢に基づく加速度姿勢行列である。
[Acceleration posture matrix calculation unit 13]
Acceleration posture matrix calculating unit 13 uses the gravity vector g acc measured by the acceleration sensor 102, the difference e t acc of the angular velocity posture matrix q t Gyro deduced from the gravity vector h (q t gyro), an angular velocity An acceleration posture matrix q t acc is calculated from the posture matrix q t gyro .
q t acc = q t gyro + K t acc et t acc
The calculated acceleration posture matrix q t acc is output to the forward direction estimation unit 14 and the error posture matrix calculation unit 16. q t acc is an acceleration posture matrix based on the terminal posture before correction.

[前方方向推定部14]
前方方向推定部14は、加速度姿勢行列qt accから前方方向を推定する。例えば、ユーザが携帯端末を把持して、そのディスプレイを見ながら歩行している場合を前提とするならば、単純に、世界座標系における端末のy軸方向を水平面に投影したものを前方方向とみなす。
前方方向推定部14によって推定された前方方向は、アプリケーションと方向誤差算出部15へ出力される。
[Forward direction estimation unit 14]
The forward direction estimation unit 14 estimates the forward direction from the acceleration posture matrix q t acc . For example, if it is assumed that the user is grasping the mobile terminal and walking while looking at the display, simply projecting the y-axis direction of the terminal in the world coordinate system onto the horizontal plane is the forward direction. I reckon.
The forward direction estimated by the forward direction estimation unit 14 is output to the application and the direction error calculation unit 15.

図4は、携帯端末に対する端末座標系と世界座標系とを表す説明図である。   FIG. 4 is an explanatory diagram showing a terminal coordinate system and a world coordinate system for the mobile terminal.

図4(a)によれば、端末座標系が表されている。端末座標系とは、端末のセンサから得られる座標系であって、携帯端末の右方向をx軸方向とし、上方向をy軸方向とし、表面方向をz軸とする。
図4(b)によれば、世界座標系が表されている。世界座標系とは、地表に対するユークリッド座標系で、水平面をxy平面、鉛直方向をz軸としたものである。
尚、水平面について、どの方向がx軸y軸になるかは不定であって、端末の初期姿勢によって決定される。特に、角速度センサと加速度センサのみを用いる場合、水平面上での絶対的な方向(方位角)を定めることはできない。但し、地磁気センサを用いた場合、絶対的な方向を決定することができる。
FIG. 4A shows a terminal coordinate system. The terminal coordinate system is a coordinate system obtained from the sensor of the terminal, and the right direction of the mobile terminal is the x-axis direction, the upward direction is the y-axis direction, and the surface direction is the z-axis.
According to FIG. 4B, the world coordinate system is represented. The world coordinate system is a Euclidean coordinate system with respect to the ground surface, and the horizontal plane is the xy plane and the vertical direction is the z-axis.
Note that which direction is the x axis and the y axis with respect to the horizontal plane is indefinite and is determined by the initial posture of the terminal. In particular, when only the angular velocity sensor and the acceleration sensor are used, the absolute direction (azimuth angle) on the horizontal plane cannot be determined. However, when a geomagnetic sensor is used, the absolute direction can be determined.

ここで、前方方向推定部14が推定する前方方向は、世界座標系平面に投影した端末座標系のy軸方向である。   Here, the forward direction estimated by the forward direction estimation unit 14 is the y-axis direction of the terminal coordinate system projected onto the world coordinate system plane.

[マップデータ記憶部150]
マップデータ記憶部150は、正解方向を予め記憶したものである。「正解方向」は、当該携帯端末の位置から通路方向に応じた1つ以上の進行可能な方向である。例えば、携帯端末が通行可能な地図情報である。正解方向の候補としては、進行可能な通路に応じて、離散化した方向(0度、90度、180度、270度)となる。
[Map data storage unit 150]
The map data storage unit 150 stores the correct answer direction in advance. The “correct answer direction” is one or more advancing directions according to the direction of the passage from the position of the mobile terminal. For example, map information that the mobile terminal can pass through. The correct direction candidates are discretized directions (0 degrees, 90 degrees, 180 degrees, and 270 degrees) according to the path that can be traveled.

[方向誤差算出部15]
方向誤差算出部15は、前方方向推定部14から前方方向を入力し、マップデータ記憶部150から正解方向を入力する。そして、方向誤差算出部15は、前方方向に対して最も角度差が小さい正解方向を検索する。そして、本発明によれば、その角度差を打ち消す方向に進行方向をずらすこととなる。
方向誤差算出部15は、正解方向と前方方向との差分となる方向誤差Etを算出する。算出された方向誤差Etは、誤差姿勢行列算出部16へ出力される。
[Direction error calculation unit 15]
The direction error calculation unit 15 receives the forward direction from the forward direction estimation unit 14 and the correct direction from the map data storage unit 150. Then, the direction error calculation unit 15 searches for a correct direction having the smallest angle difference with respect to the forward direction. And according to this invention, a traveling direction will be shifted to the direction which cancels the angle difference.
Direction error calculating unit 15 calculates the direction error E t which is a difference between the correct direction and the forward direction. The calculated direction error Et is output to the error posture matrix calculation unit 16.

図4(b)によれば、世界座標系水平面に投影した携帯端末の端末座標系のy軸と、世界座標系の正解方向の間の誤差が、方向誤差Etとなる。例えば、推定された端末座標系のy軸(進行方向)が30度、正解方向の候補は90度単位であったとする。この場合、30度に一番近い離散化した方向は0度なので、0度を正解方向とみなし、+30度が方向誤差Etとなる。
尚、他の実施形態として、マップデータを用いて、推定された現在位置と最も近い通路の方向を正解方向として、方向誤差を計算することもできる。
According to FIG. 4 (b), it has a y-axis of the terminal coordinate system of a mobile terminal projected to the world coordinate system horizontal plane, error between the correct direction in the world coordinate system, a direction error E t. For example, it is assumed that the estimated y-axis (traveling direction) of the terminal coordinate system is 30 degrees, and the correct direction candidate is in units of 90 degrees. In this case, since the nearest discretized direction 30 degrees of 0 °, 0 ° regarded as correct direction, + 30 ° is direction error E t.
As another embodiment, it is also possible to calculate the direction error using the map data, with the direction of the path closest to the estimated current position as the correct direction.

[誤差姿勢行列算出部16]
誤差姿勢行列算出部16は、加速度姿勢行列算出部13から加速度姿勢行列qt accを入力し、方向誤差算出部15から方向誤差Etを入力する。
誤差姿勢行列算出部16は、加速度姿勢行列qt accに方向誤差Etで重み付けた誤差から誤差姿勢行列qt errを算出する。そして、当該誤差姿勢行列qt errを時刻tにおける最終的な端末姿勢行列qtとして、時刻t+1における角速度姿勢行列算出部12へフィードバックして入力する。
[Error posture matrix calculation unit 16]
Error posture matrix calculating unit 16 receives the acceleration posture matrix q t acc from the acceleration posture matrix calculating unit 13, inputs a direction error E t from the direction error calculating unit 15.
Error posture matrix calculating unit 16 calculates the error posture matrix q t err from errors weighted by direction error E t the acceleration posture matrix q t acc. Then, the error posture matrix q t err is fed back and input to the angular velocity posture matrix calculation unit 12 at time t + 1 as the final terminal posture matrix q t at time t.

[付加的前方方向推定部17]
付加的前方方向推定部17は、誤差姿勢行列算出部16から出力された誤差姿勢行列qtから、前方方向を推定する。付加的前方方向推定部17によって推定された前方方向を、アプリケーションへ出力する。
前方方向推定部14から出力される前方方向と異なって、付加的前方方向推定部17は、姿勢更新後の姿勢(誤差姿勢行列算出部16の誤差姿勢行列qt)に基づいて前方方向を推定する。そのために、現在のタイミングで補正された姿勢に基づく、正確な前方方向を出力することができる。
[Additional forward direction estimation unit 17]
The additional forward direction estimation unit 17 estimates the forward direction from the error posture matrix q t output from the error posture matrix calculation unit 16. The forward direction estimated by the additional forward direction estimation unit 17 is output to the application.
Unlike the forward direction output from the forward direction estimation unit 14, the additional forward direction estimation unit 17 estimates the forward direction based on the posture after the posture update (the error posture matrix q t of the error posture matrix calculation unit 16). To do. Therefore, it is possible to output an accurate forward direction based on the posture corrected at the current timing.

<<誤差姿勢行列を算出する実施形態>>
本発明によれば、前述した角速度姿勢行列算出部12と、加速度姿勢行列算出部13と、誤差姿勢行列算出部16とは、以下のような4つの実施形態で実現することができる。
<第1の実施形態:カルマンフィルタを用いた第1の誤差姿勢行列>
<第2の実施形態:カルマンフィルタを用いた第2の誤差姿勢行列>
<第3の実施形態:加速度姿勢行列の単位補正角度に基づく誤差姿勢行列>
<第4の実施形態:角速度姿勢行列の単位補正角度に基づく誤差姿勢行列>
<< Embodiment for Computing Error Posture Matrix >>
According to the present invention, the above-described angular velocity posture matrix calculation unit 12, acceleration posture matrix calculation unit 13, and error posture matrix calculation unit 16 can be realized in the following four embodiments.
<First Embodiment: First Error Attitude Matrix Using Kalman Filter>
<Second Embodiment: Second Error Posture Matrix Using Kalman Filter>
<Third Embodiment: Error posture matrix based on unit correction angle of acceleration posture matrix>
<Fourth Embodiment: Error posture matrix based on unit correction angle of angular velocity posture matrix>

<第1の実施形態:カルマンフィルタを用いた第1の誤差姿勢行列>
「カルマンフィルタ」とは、離散的な誤差のある観測から、時々刻々と時間変化する量を推定するために用いられる連続時間線形動的システムである(例えば非特許文献2、3参照)。これは、隠れマルコフモデルに類似したものであって、ガウス分布に従う雑音によって未来の状態変数を統計的に出力することができる。
<First Embodiment: First Error Attitude Matrix Using Kalman Filter>
A “Kalman filter” is a continuous-time linear dynamic system used to estimate an amount that changes with time from observation with discrete errors (for example, see Non-Patent Documents 2 and 3). This is similar to the Hidden Markov Model, and future state variables can be statistically output by noise following a Gaussian distribution.

[角速度姿勢行列算出部12]
角速度姿勢行列算出部12は、角速度センサ101によって絶対座標系で表した回転をΔθt Gとすると、時刻t-1における端末姿勢qt-1を用いて、以下のように表すことができる。
Δθt G=qt-1Δθt
q:回転を行列で表したクォータニオン(四元数)
[Angular Velocity Posture Matrix Calculation Unit 12]
If the rotation expressed in the absolute coordinate system by the angular velocity sensor 101 is Δθ t G , the angular velocity posture matrix calculation unit 12 can be expressed as follows using the terminal posture q t−1 at time t−1.
Δθ t G = q t-1 Δθ t
q: Quaternion (quaternion) representing rotation as a matrix

絶対座標系について、Δθt G/|Δθt G|を回転の軸として、|Δθt G|だけ回転させたものを、以下のように表す。
θt=|Δθt G|
t=Δθt G/|Δθt G|
The absolute coordinate system, [Delta] [theta] t G / | as the axis of rotation of, | | Δθ t G Δθ t G | those rotated by, expressed as follows.
θ t = | Δθ t G |
n t = Δθ t G / | Δθ t G |

クォータニオンによれば、3次元の回転軸ベクトルn(大きさは1)回りにθだけ回転させる場合、4次元ベクトルを用いて、角速度センサ101による回転量qgyroを、以下のように表すことができる。
gyro=(cos(θt/2) ntsin(θt/2))
角速度センサから計算した時刻tにおける端末姿勢である角速度姿勢行列qt gyroは、時刻t-1における端末姿勢qt-1を、qgyroだけ回転させたものとなる。
t gyro=qgyro×qt-1
×:クォータニオンの積の演算子
そして、角速度姿勢行列算出部12は、カルマンフィルタの「予測ステップ」を実行する。
t gyro=FPt-1T+Gkkk T
t=∂/∂q(qgyro・q)|qt-1
尚、カルマンフィルタによれば、時変な行列Fk、Gk、Hk、Qk、Rkによって特徴付けられる線形の状態方程式として表される。
According to the quaternion, when rotating by θ around a three-dimensional rotation axis vector n (size is 1), the rotation amount q gyro by the angular velocity sensor 101 can be expressed as follows using a four-dimensional vector. it can.
q gyro = (cos (θ t / 2) n t sin (θ t / 2))
The angular velocity posture matrix q t gyro that is the terminal posture at time t calculated from the angular velocity sensor is obtained by rotating the terminal posture q t-1 at time t−1 by q gyro .
q t gyro = q gyro × q t-1
X: Operator of quaternion product Then, the angular velocity posture matrix calculation unit 12 executes the “prediction step” of the Kalman filter.
P t gyro = FP t-1 F T + G k Q k G k T
F t = ∂ / ∂q (q gyro · q) | qt-1
The Kalman filter is expressed as a linear state equation characterized by time-varying matrices Fk, Gk, Hk, Qk, Rk.

角速度姿勢行列算出部12は、角速度姿勢行列qt gyroとカルマンフィルタの共分散行列Pt gyroとを、加速度姿勢行列算出部13へ出力する。 The angular velocity posture matrix calculation unit 12 outputs the angular velocity posture matrix q t gyro and the Kalman filter covariance matrix P t gyro to the acceleration posture matrix calculation unit 13.

[加速度姿勢行列算出部13]
加速度姿勢行列算出部13は、カルマンフィルタの「更新ステップ」を実行する。
acc:加速度ベクトル(=重力ベクトル)
h(q):端末姿勢qから推定される重力ベクトル
t acc=gacc−h(qt gyro
t acc=∂/∂q(h(q))|qt gyro
t acc=Ht acct gyrot accT+Rt acc
t acc=Pt gyrot accTacc-1
t acc=qt gyro+Kt acct acc
t acc=(I−Kt acct acc)Pt gyro
加速度姿勢行列算出部13は、加速度姿勢行列qt accとカルマンフィルタの共分散行列Pt accとを、前方方向推定部14及び誤差姿勢行列算出部16へ出力する。
[Acceleration posture matrix calculation unit 13]
The acceleration posture matrix calculation unit 13 executes the “update step” of the Kalman filter.
g acc : acceleration vector (= gravity vector)
h (q): the gravity vector is estimated from the terminal posture q e t acc = g acc -h (q t gyro)
H t acc = ∂ / ∂q (h (q)) | qt gyro
S t acc = H t acc P t gyro H t accT + R t acc
K t acc = P t gyro H t accT S acc-1
q t acc = q t gyro + K t acc et t acc
P t acc = (I−K t acc H t acc ) P t gyro
The acceleration posture matrix calculation unit 13 outputs the acceleration posture matrix q t acc and the Kalman filter covariance matrix P t acc to the forward direction estimation unit 14 and the error posture matrix calculation unit 16.

[誤差姿勢行列算出部16]
誤差姿勢行列算出部16は、以下のように端末姿勢を更新する。
方向誤差Etが0となる端末姿勢qt coreectは、誤差による補正前の端末姿勢qt accを鉛直軸回りに−Etだけ回転させたものである。鉛直軸回りに−Etの回転は、以下のクォータニオンを用いて表される。
t v=(cos(−Et/2) 0 0 sin(−Et/2))
これを用いることで、方向誤差Etが0となる端末姿勢qt coreectは下記のように計算できる。
t coreect=qt v×qt acc
(qt accを鉛直方向回りに誤差と同じ大きさで逆方向に回転させた姿勢)
t coreect:観測値(方向誤差が0となる端末姿勢)
t acc:内部状態の推定値
[Error posture matrix calculation unit 16]
The error attitude matrix calculation unit 16 updates the terminal attitude as follows.
Terminal attitude q t coreect the direction error E t is 0 is obtained by rotating only -E t a terminal attitude q t acc before correction by the error in the vertical axis. The rotation of −E t around the vertical axis is expressed using the following quaternion.
q t v = (cos (−E t / 2) 0 0 sin (−E t / 2))
By using this, the terminal posture q t coreect the direction error E t is 0 can be calculated as follows.
q t coreect = q t v × q t acc
(Attitude where q t acc is rotated in the opposite direction around the vertical direction with the same size as the error)
q t coreect : Observed value (terminal orientation with zero direction error)
q t acc : Estimated value of internal state

カルマンフィルタの更新ステップに従って更新することにより、次状態を計算できる。
正解方向の姿勢行列qt correctと、加速度姿勢行列qt accとの間の(観測)残差eerr tを、以下のように算出する。
t err=qt coreect−qt acc
また、観測残差の共分散は、以下のように計算できる。
t err=Pt acc+Rt err
t err:カルマンフィルタに外部から与えるパラメータ(固定値でもよい)
t errのパラメータの値を変えることで、1度のステップでの補正量を調整することが可能である。
加速度姿勢行列算出部13のカルマンフィルタによって算出された共分散行列Pt accを用いて、最適カルマンゲインKt errを、以下のように算出する(M-1は、行列Mの逆行列を表す)。
t err=Pt acct err-1
加速度姿勢行列qt accから、残差eerr t及び最適カルマンゲインKt errの積に基づく誤差姿勢行列qt err(更新後の姿勢の推定値)を、以下のように算出する。
t err=qt acc+KT errt err
共分散行列Pt accから、最適カルマンゲインKt errに基づく共分散行列Ptを、以下のように算出する。
t err=(I−Kt err)Pt acc
By updating according to the update step of the Kalman filter, the next state can be calculated.
The (observation) residual e err t between the correct orientation matrix x t correct and the acceleration attitude matrix q t acc is calculated as follows.
e t err = q t coreect −q t acc
In addition, the covariance of the observation residual can be calculated as follows.
S t err = P t acc + R t err
R t err : Parameter given to the Kalman filter from the outside (may be a fixed value)
By changing the parameter value of R t err , the correction amount in one step can be adjusted.
The optimum Kalman gain K t err is calculated as follows using the covariance matrix P t acc calculated by the Kalman filter of the acceleration posture matrix calculation unit 13 (M −1 represents an inverse matrix of the matrix M). .
K t err = P t acc S t err-1
From the acceleration posture matrix q t acc , an error posture matrix q t err (estimated value of updated posture) based on the product of the residual e err t and the optimum Kalman gain K t err is calculated as follows.
q t err = q t acc + K T err e t err
From the covariance matrix P t acc , a covariance matrix P t based on the optimum Kalman gain K t err is calculated as follows.
P t err = (I−K t err ) P t acc

そして、誤差姿勢行列算出部16は、時刻tにおける誤差姿勢行列qt err及び共分散行列Pt errを、時刻tにおける最終的な姿勢行列qt及び共分散Ptとして時刻t+1における角速度姿勢行列算出部12へフィードバックする。 Then, the error posture matrix calculation unit 16 uses the error posture matrix q t err and covariance matrix P t err at time t as the final posture matrix q t and covariance P t at time t, and the angular velocity at time t + 1. Feedback to the attitude matrix calculation unit 12 is performed.

<第2の実施形態:カルマンフィルタを用いた第2の誤差姿勢行列>
誤差姿勢行列算出部16は、以下のように端末姿勢を更新する。
クォータニオンq=(w,x,y,z)から、このクォータニオンによる回転と同等の回転を表す行列への変換を表す関数を、以下のように予め定義する。

Figure 2017181218
方向誤差Etが0となる絶対座標系における端末のY軸方向yt coreectは、誤差による補正前の端末のY軸方向yt accを鉛直軸回りに、−Etだけ回転させたものである。
誤差による補正前の端末のY軸方向yt accは、誤差による補正前の端末姿勢qt accを用いて計算することができる。具体的には、端末座標系でのy軸方向を表すベクトル、即ち、(0,1,0)をqt accを用いて回転させればよい。即ち、以下のように計算することができる(MTは、行列Mの転置行列を表す)。
t acc=R(qt acc)(0,1,0)T
鉛直軸回りに−Etの回転は、以下のクォータニオンを用いて表される。
t v=(cos(−Et/2) 0 0 sin(−Et/2))
これを用いて、方向誤差Etが0となる端末のY軸方向yt coreectは、以下のように算出することができる。
t coreect=R(qt v)yt acc
(yt accを鉛直方向回りに誤差と同じ大きさで逆方向に回転させたベクトル)
t coreect:観測値(方向誤差が0となる端末のY軸方向)
t acc:内部状態から推定値した端末のY軸方向 <Second Embodiment: Second Error Posture Matrix Using Kalman Filter>
The error attitude matrix calculation unit 16 updates the terminal attitude as follows.
A function representing conversion from quaternion q = (w, x, y, z) to a matrix representing rotation equivalent to rotation by quaternion is defined in advance as follows.
Figure 2017181218
Y axis direction y t coreect terminal in the absolute coordinate system direction error E t is 0, the Y-axis direction y t acc terminal before the correction by the error in the vertical axis, which was rotated by -E t is there.
The Y-axis direction y t acc of the terminal before correction by error can be calculated using the terminal posture q t acc before correction by error. Specifically, a vector representing the y-axis direction in the terminal coordinate system, that is, (0,1,0) may be rotated using q t acc . That is, it can be calculated as follows (M T represents a transposed matrix of the matrix M).
y t acc = R (q t acc ) (0,1,0) T
The rotation of −E t around the vertical axis is expressed using the following quaternion.
q t v = (cos (−E t / 2) 0 0 sin (−E t / 2))
Using this, Y axis direction y t coreect terminals direction error E t is 0, can be calculated as follows.
y t coreect = R (q t v ) y t acc
(Vector obtained by rotating y t acc in the reverse direction around the vertical direction with the same magnitude as the error)
y t coreect : Observation value (Y-axis direction of the terminal where the direction error is 0)
y t acc : Y-axis direction of terminal estimated from internal state

カルマンフィルタの更新ステップに従って更新することにより、次状態を計算することができる。
正解方向の姿勢行列yt correctと、加速度姿勢行列yt accとの間の(観測)残差eerr tを、以下のように算出する。
t err=yt coreect−R(qt acc)(0,1,0)T
尚、R(qt acc)(0,1,0)T=yt accである。
また、観測残差の共分散は、以下のように算出できる。
t err=HPt accT+Rt err
t err:カルマンフィルタに外部から与えるパラメータ(固定値でもよい)
H:R(q)(0,1,0)Tのヤコビ行列。
即ち、H=∂/∂q(R(q)(0,1,0)T)|qt acc
t errのパラメータの値を変えることで、1度のステップでの補正量を調整することが可能である。
加速度姿勢行列算出部13のカルマンフィルタによって算出された共分散行列Pt accを用いて、最適カルマンゲインKt errを、以下のように算出する(M-1は、行列Mの逆行列を表す)。
t err=Pt acct err-1
加速度姿勢行列qt accから、残差eerr t及び最適カルマンゲインKt errの積に基づく誤差姿勢行列qt(更新後の姿勢の推定値)を、以下のように算出する。
t err=qt acc+KT errt err
共分散行列Pt accから、最適カルマンゲインKt errに基づく共分散行列Ptを、以下のように算出する。
t err=(I−Kt err)Pt acc
By updating according to the Kalman filter update step, the next state can be calculated.
The (observed) residual e err t between the correct orientation posture matrix y t correct and the acceleration posture matrix y t acc is calculated as follows.
e t err = y t coreect −R (q t acc ) (0,1,0) T
Note that R (q t acc ) (0,1,0) T = y t acc .
Further, the covariance of the observation residual can be calculated as follows.
S t err = HP t acc H T + R t err
R t err : Parameter given to the Kalman filter from the outside (may be a fixed value)
H: Jacobian matrix of R (q) (0,1,0) T.
That is, H = ∂ / ∂q (R (q) (0,1,0) T ) | qt acc
By changing the parameter value of R t err , the correction amount in one step can be adjusted.
The optimum Kalman gain K t err is calculated as follows using the covariance matrix P t acc calculated by the Kalman filter of the acceleration posture matrix calculation unit 13 (M −1 represents an inverse matrix of the matrix M). .
K t err = P t acc S t err-1
From the acceleration posture matrix q t acc , an error posture matrix q t based on the product of the residual e err t and the optimum Kalman gain K t err is calculated as follows.
q t err = q t acc + K T err e t err
From the covariance matrix P t acc , a covariance matrix P t based on the optimum Kalman gain K t err is calculated as follows.
P t err = (I−K t err ) P t acc

そして、誤差姿勢行列算出部16は、時刻tにおける角速度姿勢行列qt err及び共分散行列Pt errを、時刻tにおける最終的な姿勢行列qt及び共分散Ptとして時刻t+1における角速度姿勢行列算出部12へフィードバックする。 Then, the error posture matrix calculation unit 16 uses the angular velocity posture matrix q t err and covariance matrix P t err at time t as the final posture matrix q t and covariance P t at time t, and the angular velocity at time t + 1. Feedback to the attitude matrix calculation unit 12 is performed.

<第3の実施形態:加速度姿勢行列の単位補正角度に基づく誤差姿勢行列>
誤差姿勢行列算出部16は、所定の単位補正割合rに基づいて、誤差姿勢行列qt errを算出する。また、qt errを時刻tにおける最終的な姿勢行列qtとする。
(1)方向誤差Etに対する所定の単位補正割合rの単位補正角度rEtを算出する。
(2)加速度姿勢行列qt accに、単位補正角度rEtだけ鉛直軸回りへの回転を表す姿勢行列を積算して、誤差姿勢行列qt errを算出する。
<Third Embodiment: Error posture matrix based on unit correction angle of acceleration posture matrix>
The error posture matrix calculation unit 16 calculates an error posture matrix q t err based on a predetermined unit correction ratio r. Also, let q t err be the final posture matrix q t at time t.
(1) Calculate the unit correction angle rE t of a predetermined unit correction ratio r with respect to the direction error E t.
(2) An attitude matrix representing rotation about the vertical axis by the unit correction angle rE t is added to the acceleration attitude matrix q t acc to calculate an error attitude matrix q t err .

単位補正割合r(0<r≦1)は、一度に補正する角度における、誤差に対する割合を表す。1回のステップで補正する角度は、rEtとする。
補正後の端末姿勢qt errは、誤差による補正前の端末姿勢qt accを、鉛直軸回りに、−rEtだけ回転させたものである。鉛直軸回りに−rEtの回転は、以下のクォータニオンを用いて表される。
t v=(cos(−rEt/2) 0 0 sin(−rEt/2))
t err=qt v×qt acc
The unit correction ratio r (0 <r ≦ 1) represents a ratio with respect to an error in the angle corrected at a time. The angle corrected in one step is rE t .
The corrected terminal posture q t err is obtained by rotating the terminal posture q t acc before correction due to an error by −rE t around the vertical axis. The rotation of −rE t about the vertical axis is expressed using the following quaternion.
q t v = (cos (−rE t / 2) 0 0 sin (−rE t / 2))
q t err = q t v × q t acc

<第4の実施形態:角速度姿勢行列の単位補正角度に基づく誤差姿勢行列>
図5は、本発明における携帯端末の第2の機能構成図である。
<Fourth Embodiment: Error posture matrix based on unit correction angle of angular velocity posture matrix>
FIG. 5 is a second functional configuration diagram of the mobile terminal according to the present invention.

図5(第3の実施形態)によれば、図2(第1の実施形態、第2の実施形態)と比較して、加速度センサ102を必要とせず、角速度センサ101のみで、前方方向を推定することができる。そのため、図5の機能構成図は、図2の機能構成図の上位概念的なものとなる。   According to FIG. 5 (3rd Embodiment), compared with FIG. 2 (1st Embodiment, 2nd Embodiment), the acceleration sensor 102 is not required, but only the angular velocity sensor 101 is used and the front direction is demonstrated. Can be estimated. Therefore, the functional configuration diagram of FIG. 5 is a high-level conceptual diagram of the functional configuration diagram of FIG.

誤差姿勢行列算出部16は、所定の単位補正割合rに基づいて、誤差姿勢行列qt errを算出する。また、qt errを時刻tにおける最終的な姿勢行列qtとする。
(1)方向誤差Etに対する所定の単位補正割合rの単位補正角度rEtを算出する。
(2)角速度姿勢行列qt gyroに、単位補正角度rEtだけ鉛直軸回りへの回転を表す姿勢行列を積算して、誤差姿勢行列qt errを算出する。
The error posture matrix calculation unit 16 calculates an error posture matrix q t err based on a predetermined unit correction ratio r. Also, let q t err be the final posture matrix q t at time t.
(1) Calculate the unit correction angle rE t of a predetermined unit correction ratio r with respect to the direction error E t.
(2) the angular velocity posture matrix q t Gyro, by integrating the attitude matrix representing the rotation of the unit correction angle rE t only about a vertical axis, and calculates the error posture matrix q t err.

尚、図5によれば、前方方向推定部14は、角速度姿勢行列qt accから前方方向を推定する。 According to FIG. 5, the forward direction estimation unit 14 estimates the forward direction from the angular velocity posture matrix q t acc .

図6は、本発明における前方方向の推定を表す説明図である。   FIG. 6 is an explanatory diagram showing estimation of the forward direction in the present invention.

図6(a)によれば、従来技術における前方方向の推定を表す(例えば非特許文献1参照)。例えばマップデータに基づく正解方向候補が右方向であった場合、携帯端末の前方方向が右向きとなった場合、コーナーで右折したと判定される。即ち、コーナーが検出されたら、正解方向候補の向きに合わせるという離散的な方向判定となる。   FIG. 6A shows the estimation of the forward direction in the prior art (see, for example, Non-Patent Document 1). For example, when the correct direction candidate based on the map data is the right direction, when the forward direction of the mobile terminal is the right direction, it is determined that the vehicle turns right at the corner. That is, when a corner is detected, a discrete direction determination is performed in which the direction of the correct direction candidate is matched.

これに対し、図6(b)によれば、本発明における前方方向の推定を表す。例えばマップデータに基づく正解方向候補が右方向であった場合、携帯端末の前方方向が右向きとなった場合であっても、正解方向候補に徐々に近づけている。そのために、直ぐに右折したとまでは判定しない。そのために、正解方向候補以外の方向への方向転換にも、ある程度追従することができる。特に、図6のように、本発明によれば、障害物を避けるなどの歩行時のノイズの影響によって、誤って判定された正解方向に測位されてしまうことを防ぐことができる。   On the other hand, according to FIG. 6B, the estimation of the forward direction in the present invention is represented. For example, when the correct direction candidate based on the map data is the right direction, even if the forward direction of the mobile terminal is the right direction, the correct direction candidate is gradually approached. For this reason, it is not determined that the vehicle has turned right immediately. Therefore, it is possible to follow the direction change to a direction other than the correct direction candidate to some extent. In particular, as shown in FIG. 6, according to the present invention, it is possible to prevent positioning in the correct direction determined erroneously due to the influence of noise during walking such as avoiding an obstacle.

以上、詳細に説明したように、本発明の携帯端末、プログラム及び方法によれば、角速度センサを用いて、地図上の通路に沿った移動中のユーザの方向転換を、時間経過に応じて推定することができる。また、角速度センサにおけるコーナー判定を徐々に決定するために、前方方向の推定性能における大幅な劣化を防ぐことができる。   As described above in detail, according to the mobile terminal, the program, and the method of the present invention, the direction change of the moving user along the path on the map is estimated with the passage of time using the angular velocity sensor. can do. In addition, since the corner determination in the angular velocity sensor is gradually determined, it is possible to prevent a significant deterioration in the estimation performance in the forward direction.

前述した本発明における種々の実施形態によれば、当業者は、本発明の技術思想及び見地の範囲における種々の変更、修正及び省略を容易に行うことができる。前述の説明はあくまで例であって、何ら制約しようとするものではない。本発明は、特許請求の範囲及びその均等物として限定するものにのみ制約される。   According to the various embodiments of the present invention described above, those skilled in the art can easily make various changes, modifications and omissions within the scope of the technical idea and the viewpoint of the present invention. The above description is merely an example, and is not intended to be restrictive. The invention is limited only as defined in the following claims and the equivalents thereto.

1 携帯端末
101 角速度センサ
102 加速度センサ
11 初期姿勢算出部
12 角速度姿勢行列算出部
13 加速度姿勢行列算出部
14 前方方向推定部
15 方向誤差算出部
150 マップデータ記憶部
16 誤差姿勢行列算出部
17 付加的前方方向推定部
DESCRIPTION OF SYMBOLS 1 Mobile terminal 101 Angular velocity sensor 102 Acceleration sensor 11 Initial attitude | position calculation part 12 Angular velocity attitude | position matrix calculation part 13 Acceleration attitude | position matrix calculation part 14 Forward direction estimation part 15 Direction error calculation part 150 Map data storage part 16 Error attitude matrix calculation part 17 Additional Forward direction estimation unit

Claims (16)

角速度センサを有し、ユーザの前方方向を推定する携帯端末であって、
正解方向を予め記憶したマップデータ記憶手段と、
前記角速度センサによって計測された角速度ベクトルに基づく端末姿勢の回転を表す行列qgyroと、時刻t-1における端末姿勢行列qt-1とから、時刻tにおける角速度姿勢行列qt gyroを算出する角速度姿勢行列算出手段と、
前記角速度姿勢行列qt gyroから前方方向を推定する前方方向推定手段と、
前記正解方向と前記前方方向との差分となる方向誤差Etを算出する方向誤差算出手段と、
前記角速度姿勢行列qt gyroに前記方向誤差Etで重み付けた誤差から誤差姿勢行列qt errを算出し、当該誤差姿勢行列qt errを時刻tにおける最終的な端末姿勢行列qtとして、時刻t+1における前記角速度姿勢行列算出手段へフィードバックして入力する誤差姿勢行列算出手段と
を有することを特徴とする携帯端末。
A portable terminal that has an angular velocity sensor and estimates a user's forward direction,
Map data storage means for storing the correct answer direction in advance;
Angular velocity for calculating the angular velocity posture matrix q t gyro at time t from the matrix q gyro representing the rotation of the terminal posture based on the angular velocity vector measured by the angular velocity sensor and the terminal posture matrix q t-1 at time t−1. Attitude matrix calculation means;
Forward direction estimation means for estimating a forward direction from the angular velocity posture matrix q t gyro ;
A direction error calculating means for calculating a direction error E t which is a difference between the forward direction and the correct direction,
Wherein calculating the error posture matrix q t err from errors weighted by the angular velocity posture matrix q t Gyro in the direction error E t, as the final terminal attitude matrix q t the error posture matrix q t err at time t, the time An error posture matrix calculation unit that feeds back and inputs to the angular velocity posture matrix calculation unit at t + 1.
前記前方方向推定手段によって推定された前記前方方向を、アプリケーションへ出力する
ことを特徴とする請求項1に記載の携帯端末。
The mobile terminal according to claim 1, wherein the forward direction estimated by the forward direction estimation means is output to an application.
前記誤差姿勢行列算出手段から出力された前記誤差姿勢行列qtから、前方方向を推定する付加的前方方向推定手段を更に有し、
前記付加的前方方向推定手段によって推定された前記前方方向を、アプリケーションへ出力する
ことを特徴とする請求項1に記載の携帯端末。
Additional forward direction estimating means for estimating a forward direction from the error posture matrix q t output from the error posture matrix calculating means,
The mobile terminal according to claim 1, wherein the forward direction estimated by the additional forward direction estimation unit is output to an application.
前記誤差姿勢行列算出手段は、
前記方向誤差Etに対する所定の単位補正割合rの単位補正角度rEtを算出し、
前記角速度姿勢行列qt gyroに、前記単位補正角度rEtだけ鉛直軸回りへの回転を表す姿勢行列を積算して、誤差姿勢行列qt errを算出する
ことを特徴とする請求項1から3のいずれか1項に記載の携帯端末。
The error posture matrix calculation means includes
Calculating a unit correction angle rE t of a predetermined unit correction ratio r with respect to the direction error E t,
The error attitude matrix q t err is calculated by adding the attitude matrix representing rotation about the vertical axis by the unit correction angle rE t to the angular velocity attitude matrix q t gyro. The mobile terminal according to any one of the above.
前記角速度姿勢行列算出手段は、カルマンフィルタを用いて姿勢行列を算出する
ことを特徴とする請求項1から4のいずれか1項に記載の携帯端末。
5. The mobile terminal according to claim 1, wherein the angular velocity posture matrix calculating unit calculates a posture matrix using a Kalman filter.
加速度センサと、
前記加速度センサによって計測された重力ベクトルgaccと、角速度姿勢行列qt gyroから推定された重力ベクトルh(qt gyro)との差分et accを用いて、角速度姿勢行列qt gyroから、加速度姿勢行列qt accを算出する加速度姿勢行列算出手段と
を更に有し、
前記誤差姿勢行列算出手段は、角速度姿勢行列qt gyroに代えて、前記加速度姿勢行列qt accから誤差姿勢行列qt errを算出する
ことを特徴とする請求項1から5のいずれか1項に記載の携帯端末。
An acceleration sensor;
From the angular velocity posture matrix q t gyro using the difference e t acc between the gravity vector g acc measured by the acceleration sensor and the gravity vector h (q t gyro ) estimated from the angular velocity posture matrix q t gyro Acceleration posture matrix calculating means for calculating posture matrix q t acc ,
6. The error posture matrix calculating unit calculates an error posture matrix q t err from the acceleration posture matrix q t acc instead of the angular velocity posture matrix q t gyro. The portable terminal as described in.
前記誤差姿勢行列算出手段は、
前記方向誤差Etに対する所定の単位補正割合rの単位補正角度rEtを算出し、
前記加速度姿勢行列qt accに、前記単位補正角度rEtだけ鉛直軸回りへの回転を表す姿勢行列を積算して、誤差姿勢行列qt errを算出する
ことを特徴とする請求項6に記載の携帯端末。
The error posture matrix calculation means includes
Calculating a unit correction angle rE t of a predetermined unit correction ratio r with respect to the direction error E t,
The error posture matrix q t err is calculated by adding the posture matrix representing rotation about the vertical axis by the unit correction angle rE t to the acceleration posture matrix q t acc. Mobile devices.
前記角速度姿勢行列算出手段及び前記加速度姿勢行列算出手段は、カルマンフィルタを用いて姿勢行列を算出する
ことを特徴とする請求項6に記載の携帯端末。
The mobile terminal according to claim 6, wherein the angular velocity posture matrix calculating unit and the acceleration posture matrix calculating unit calculate a posture matrix using a Kalman filter.
前記誤差姿勢行列算出手段は、
前記正解方向の姿勢行列qt correctと、前記加速度姿勢行列qt accとの間の残差eerr tを算出し、
前記加速度姿勢行列算出手段のカルマンフィルタによって算出された共分散行列Pt accを用いて、最適カルマンゲインKt errを算出し、
前記加速度姿勢行列qt accから、前記残差eerr t及び最適カルマンゲインKt errの積に基づく誤差姿勢行列qt errを算出し、
前記共分散行列Pt accから、最適カルマンゲインKt errに基づく共分散行列Pt errを算出し、
更に、Pt errを時刻tにおける最終的な端末姿勢行列の共分散行列Ptとして、時刻t+1における前記角速度姿勢行列算出手段へフィードバックする
ことを特徴とする請求項8に記載の携帯端末。
The error posture matrix calculation means includes
Calculating a residual e err t between the posture matrix q t correct in the correct direction and the acceleration posture matrix q t acc ;
An optimal Kalman gain K t err is calculated using the covariance matrix P t acc calculated by the Kalman filter of the acceleration posture matrix calculating means,
Wherein the acceleration posture matrix q t acc, calculates an error posture matrix q t err based on the product of the residual e err t and the optimal Kalman gain K t err,
From the covariance matrix P t acc, to calculate the covariance matrix P t err based on optimal Kalman gain K t err,
9. The mobile terminal according to claim 8, wherein P t err is fed back to the angular velocity posture matrix calculating means at time t + 1 as a final covariance matrix P t of the terminal posture matrix at time t. .
端末姿勢行列であるqt及びqt gyro,qt acc,qt errは、スカラー部及びベクトル部によって表現したクォータニオン(四元数)である
ことを特徴とする請求項1から9のいずれか1項に記載の携帯端末。
10. The terminal attitude matrix q t and q t gyro , q t acc , q t err are quaternions expressed by a scalar part and a vector part. The mobile terminal according to item 1.
前記マップデータ記憶手段の前記正解方向は、当該携帯端末の位置から通路方向に応じた1つ以上の進行可能な方向である
ことを特徴とする請求項1から10のいずれか1項に記載の携帯端末。
The said correct direction of the said map data storage means is one or more advancing directions according to the direction of a passage from the position of the said portable terminal, The one of Claim 1 to 10 characterized by the above-mentioned. Mobile device.
加速度センサによって計測された加速度ベクトルaを端末座標系における重力方向とみなすことで、初期の角速度姿勢行列q0を算出し、当該角速度姿勢行列q0を前記角速度姿勢行列算出手段へ出力する初期姿勢行列算出手段を
更に有することを特徴とする請求項1から11のいずれか1項に記載の携帯端末。
By assuming the acceleration vector a measured by the acceleration sensor as the gravity direction in the terminal coordinate system, an initial angular velocity posture matrix q 0 is calculated, and the angular velocity posture matrix q 0 is output to the angular velocity posture matrix calculating means. The mobile terminal according to claim 1, further comprising a matrix calculation unit.
角速度センサを有し、ユーザの前方方向を推定する装置に搭載されたコンピュータを機能させるプログラムであって、
正解方向を予め記憶したマップデータ記憶手段と、
前記角速度センサによって計測された角速度ベクトルに基づく端末姿勢の回転を表す行列qgyroと、時刻t-1における端末姿勢行列qt-1とから、時刻tにおける角速度姿勢行列qt gyroを算出する角速度姿勢行列算出手段と、
前記角速度姿勢行列qt gyroから前方方向を推定する前方方向推定手段と、
前記正解方向と前記前方方向との差分となる方向誤差Etを算出する方向誤差算出手段と、
前記角速度姿勢行列qt gyroに前記方向誤差Etで重み付けた誤差から誤差姿勢行列qt errを算出し、当該誤差姿勢行列qt errを時刻tにおける最終的な端末姿勢行列qtとして、時刻t+1における前記角速度姿勢行列算出手段へフィードバックして入力する誤差姿勢行列算出手段と
してコンピュータを機能させることを特徴とするプログラム。
A program for causing a computer mounted on a device having an angular velocity sensor and estimating a user's forward direction to function.
Map data storage means for storing the correct answer direction in advance;
Angular velocity for calculating the angular velocity posture matrix q t gyro at time t from the matrix q gyro representing the rotation of the terminal posture based on the angular velocity vector measured by the angular velocity sensor and the terminal posture matrix q t-1 at time t−1. Attitude matrix calculation means;
Forward direction estimation means for estimating a forward direction from the angular velocity posture matrix q t gyro ;
A direction error calculating means for calculating a direction error E t which is a difference between the forward direction and the correct direction,
Wherein calculating the error posture matrix q t err from errors weighted by the angular velocity posture matrix q t Gyro in the direction error E t, as the final terminal attitude matrix q t the error posture matrix q t err at time t, the time A program that causes a computer to function as an error posture matrix calculation unit that feeds back and inputs to the angular velocity posture matrix calculation unit at t + 1.
前記装置は、加速度センサを更に有し、
前記加速度センサによって計測された重力ベクトルgaccと、角速度姿勢行列qt gyroから推定された重力ベクトルh(qt gyro)との差分et accを用いて、角速度姿勢行列qt gyroから、加速度姿勢行列qt accを算出する加速度姿勢行列算出手段と
してコンピュータを更に機能させ
前記誤差姿勢行列算出手段は、角速度姿勢行列qt gyroに代えて、前記加速度姿勢行列qt accから誤差姿勢行列qt errを算出する
ようにコンピュータを機能させることを特徴とする請求項13に記載のプログラム。
The apparatus further includes an acceleration sensor,
From the angular velocity posture matrix q t gyro using the difference e t acc between the gravity vector g acc measured by the acceleration sensor and the gravity vector h (q t gyro ) estimated from the angular velocity posture matrix q t gyro The computer further functions as an acceleration posture matrix calculating means for calculating the posture matrix q t acc. The error posture matrix calculating means replaces the angular velocity posture matrix q t gyro with the error posture matrix q t from the acceleration posture matrix q t acc. The program according to claim 13, wherein the program causes the computer to calculate err .
角速度センサを有する装置の前方方向推定方法であって、
前記装置は、正解方向を予め記憶したマップデータ記憶部を有し、
前記装置は、
前記角速度センサによって計測された角速度ベクトルに基づく端末姿勢の回転を表す行列qgyroと、時刻t-1における端末姿勢行列qt-1とから、時刻tにおける角速度姿勢行列qt gyroを算出する第1のステップと、
前記角速度姿勢行列qt gyroから前方方向を推定する第2のステップと、
前記正解方向と前記前方方向との差分となる方向誤差Etを算出する第3のステップと、
前記角速度姿勢行列qt gyroに前記方向誤差Etで重み付けた誤差から誤差姿勢行列qt errを算出し、当該誤差姿勢行列qt errを時刻tにおける最終的な端末姿勢行列qtとして、時刻t+1における第1のステップへフィードバックして入力する第4のステップと
を実行することを特徴とする装置の前方方向推定方法。
A method for estimating the forward direction of a device having an angular velocity sensor, comprising:
The apparatus has a map data storage unit that stores a correct answer direction in advance,
The device is
An angular velocity posture matrix q t gyro at time t is calculated from a matrix q gyro representing rotation of the terminal posture based on the angular velocity vector measured by the angular velocity sensor and a terminal posture matrix q t-1 at time t−1. 1 step,
A second step of estimating a forward direction from the angular velocity posture matrix q t gyro ;
A third step of calculating a direction error E t which is a difference between the forward direction and the correct direction,
Wherein calculating the error posture matrix q t err from errors weighted by the angular velocity posture matrix q t Gyro in the direction error E t, as the final terminal attitude matrix q t the error posture matrix q t err at time t, the time A method for estimating a forward direction of an apparatus, comprising: performing a fourth step that is fed back and input to a first step at t + 1.
前記装置は、加速度センサを更に有し、
前記装置は、
前記加速度センサによって計測された重力ベクトルgaccと、角速度姿勢行列qt gyroから推定された重力ベクトルh(qt gyro)との差分et accを用いて、角速度姿勢行列qt gyroから、加速度姿勢行列qt accを算出するステップを更に実行し、
第4のステップは、角速度姿勢行列qt gyroに代えて、前記加速度姿勢行列qt accから誤差姿勢行列qt errを算出する
ことを特徴とする請求項15に記載の装置の前方方向推定方法。
The apparatus further includes an acceleration sensor,
The device is
From the angular velocity posture matrix q t gyro using the difference e t acc between the gravity vector g acc measured by the acceleration sensor and the gravity vector h (q t gyro ) estimated from the angular velocity posture matrix q t gyro Further executing the step of calculating the attitude matrix q t acc ;
16. The forward direction estimation method for an apparatus according to claim 15, wherein the fourth step calculates an error posture matrix q t err from the acceleration posture matrix q t acc instead of the angular velocity posture matrix q t gyro. .
JP2016066935A 2016-03-29 2016-03-29 Mobile terminal, program and method for estimating forward direction of user using angular velocity sensor Active JP6516332B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2016066935A JP6516332B2 (en) 2016-03-29 2016-03-29 Mobile terminal, program and method for estimating forward direction of user using angular velocity sensor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2016066935A JP6516332B2 (en) 2016-03-29 2016-03-29 Mobile terminal, program and method for estimating forward direction of user using angular velocity sensor

Publications (2)

Publication Number Publication Date
JP2017181218A true JP2017181218A (en) 2017-10-05
JP6516332B2 JP6516332B2 (en) 2019-05-22

Family

ID=60004353

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2016066935A Active JP6516332B2 (en) 2016-03-29 2016-03-29 Mobile terminal, program and method for estimating forward direction of user using angular velocity sensor

Country Status (1)

Country Link
JP (1) JP6516332B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110855797A (en) * 2019-11-28 2020-02-28 河北农业大学 Sheep behavior monitoring system and method based on action recognition

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2015152559A (en) * 2014-02-19 2015-08-24 株式会社リコー inertial device, control method, and program
JP2015179002A (en) * 2014-03-19 2015-10-08 セイコーエプソン株式会社 Attitude estimation method, attitude estimation device and program

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2015152559A (en) * 2014-02-19 2015-08-24 株式会社リコー inertial device, control method, and program
JP2015179002A (en) * 2014-03-19 2015-10-08 セイコーエプソン株式会社 Attitude estimation method, attitude estimation device and program

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110855797A (en) * 2019-11-28 2020-02-28 河北农业大学 Sheep behavior monitoring system and method based on action recognition

Also Published As

Publication number Publication date
JP6516332B2 (en) 2019-05-22

Similar Documents

Publication Publication Date Title
US10037028B2 (en) Systems, devices, and methods for on-board sensing and control of micro aerial vehicles
LaValle et al. Head tracking for the Oculus Rift
Weiss et al. Real-time metric state estimation for modular vision-inertial systems
JP5061264B1 (en) Small attitude sensor
Xiong et al. G-VIDO: A vehicle dynamics and intermittent GNSS-aided visual-inertial state estimator for autonomous driving
JP2012173190A (en) Positioning system and positioning method
Stančić et al. The integration of strap-down INS and GPS based on adaptive error damping
JP2014089113A (en) Posture estimation device and program
Grabe et al. A comparison of scale estimation schemes for a quadrotor UAV based on optical flow and IMU measurements
Hua et al. Stability analysis of velocity-aided attitude observers for accelerated vehicles
JP2004239643A (en) Hybrid navigator
JP2012193965A (en) Position estimating device, and position estimating method and position estimating position program for position estimating device
JP2019078560A (en) Gyro sensor offset correcting device, offset correction program, and pedestrian autonomous navigation device
CN108627154A (en) Polar region region operating attitude and heading reference system
JP5511088B2 (en) Portable device, program and method for correcting gravity vector used for autonomous positioning
Nilsson et al. Reliable vehicle pose estimation using vision and a single-track model
Castro-Toscano et al. A methodological use of inertial navigation systems for strapdown navigation task
WO2016089263A1 (en) Method and system for estimating relative angle between headings
JP2013122384A (en) Kalman filter and state estimation device
JP2017181218A (en) Portable terminal, program and method estimating forward direction of users using angular velocity sensor
CN109674480B (en) Human motion attitude calculation method based on improved complementary filtering
Zarei et al. Performance improvement for mobile robot position determination using cubature Kalman filter
Yang et al. Rotation estimation for mobile robot based on single-axis gyroscope and monocular camera
JP5893254B2 (en) Portable device, program and method for correcting gravity vector used for autonomous positioning
Kobzili et al. Multi-rate robust scale estimation of monocular SLAM

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20180306

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20181220

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20190108

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20190306

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20190411

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20190412

R150 Certificate of patent or registration of utility model

Ref document number: 6516332

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150