Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JP7634458B2 - Motor control device and motor control method - Google Patents
[go: Go Back, main page]

JP7634458B2 - Motor control device and motor control method - Google Patents

Motor control device and motor control method Download PDF

Info

Publication number
JP7634458B2
JP7634458B2 JP2021161476A JP2021161476A JP7634458B2 JP 7634458 B2 JP7634458 B2 JP 7634458B2 JP 2021161476 A JP2021161476 A JP 2021161476A JP 2021161476 A JP2021161476 A JP 2021161476A JP 7634458 B2 JP7634458 B2 JP 7634458B2
Authority
JP
Japan
Prior art keywords
motor
data
learning
torque
unit
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.)
Active
Application number
JP2021161476A
Other languages
Japanese (ja)
Other versions
JP2023051040A (en
Inventor
武之 河田
将哉 木村
英俊 池田
秀之 増井
潤 丸田
滉稀 中根
昭太郎 赤穂
英樹 麻生
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.)
Mitsubishi Electric Corp
Original Assignee
Mitsubishi Electric 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 Mitsubishi Electric Corp filed Critical Mitsubishi Electric Corp
Priority to JP2021161476A priority Critical patent/JP7634458B2/en
Publication of JP2023051040A publication Critical patent/JP2023051040A/en
Application granted granted Critical
Publication of JP7634458B2 publication Critical patent/JP7634458B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Feedback Control In General (AREA)
  • Control Of Electric Motors In General (AREA)

Description

本開示は、制御対象について軌跡制御を行うモータ制御装置及びモータ制御方法に関する。 This disclosure relates to a motor control device and a motor control method that perform trajectory control of a control target.

工作機械及びロボットをはじめとする機械を駆動するモータ制御装置では、機械を指令通りに駆動するために軌跡制御が行われる。軌跡制御が行われる際、機械に加わる摩擦力の影響により生じる軌跡誤差をいかに補償するかが課題となる。従来、機械に加わる摩擦力を模擬する摩擦モデルを用いて摩擦力を相殺するトルクを計算し、計算したトルクをトルク指令に印加することで摩擦力の影響を低減する補償方法が知られている。 In motor control devices that drive machines such as machine tools and robots, trajectory control is performed to drive the machine according to commands. When trajectory control is performed, a challenge is how to compensate for trajectory errors that occur due to the effects of frictional forces acting on the machine. A compensation method is known that reduces the effects of frictional forces by calculating a torque that offsets the frictional forces using a friction model that simulates the frictional forces acting on the machine and applying the calculated torque to the torque command.

摩擦モデルの精度が高いほど、摩擦力の影響を低減した高精度な軌跡制御が可能となる。最も単純な摩擦モデルは、モータ速度と摩擦とが比例関係となる線形の摩擦モデルであるが、当該摩擦モデルでは、摩擦力の高精度な模擬が困難な場合がある。実機においては、機械とモータとがボールねじ又は減速機といった機械要素部品を介して接続されている。機械要素部品が持つ軸受及び潤滑油の影響は、摩擦においてモータ速度に対する非線形な成分として表れる。従来、非線形性を持つ摩擦をモデル化し、得られた摩擦モデルを用いて摩擦補償をする技術が知られている。 The higher the accuracy of the friction model, the more accurate trajectory control that reduces the effects of frictional forces becomes possible. The simplest friction model is a linear friction model in which the motor speed and friction are proportional to each other, but this friction model can make it difficult to simulate frictional forces with high accuracy. In an actual machine, the machine and motor are connected via machine components such as a ball screw or a reducer. The effects of the bearings and lubricating oil of the machine components appear as nonlinear components in friction with respect to the motor speed. Conventionally, there is known technology that models nonlinear friction and compensates for friction using the obtained friction model.

特許文献1は、速度フィードフォワード制御部を有するモータ制御装置を開示している。当該速度フィードフォワード制御部は、入力された上位指令加速度を速度側加速度出力として出力する速度側加速度入力部と、入力された上位指令速度を速度側速度出力として出力する速度側速度入力部と、限定速度範囲を分割した複数の速度範囲の境界となる複数の境界速度に対応させて用意されて上位指令速度と対応する箇所より速度側境界速度出力を出力する複数の速度側境界速度入力部と、各入力部からの出力である速度側第1出力のそれぞれに対応する複数の速度側第1学習重みを速度偏差に応じて変更する速度側第1重み学習部と、速度側第1出力と速度側第1学習重みとを乗算した複数の速度側第1乗算値を加算して第2仮指令電流として出力する速度側出力部とを有する。 Patent Document 1 discloses a motor control device having a speed feedforward control section. The speed feedforward control section has a speed-side acceleration input section that outputs the input upper command acceleration as a speed-side acceleration output, a speed-side speed input section that outputs the input upper command speed as a speed-side speed output, a plurality of speed-side boundary speed input sections that are prepared corresponding to a plurality of boundary speeds that are boundaries of a plurality of speed ranges obtained by dividing a limited speed range and output a speed-side boundary speed output from a position corresponding to the upper command speed, a speed-side first weight learning section that changes a plurality of speed-side first learning weights corresponding to each of the speed-side first outputs that are outputs from each input section according to the speed deviation, and a speed-side output section that adds a plurality of speed-side first multiplication values obtained by multiplying the speed-side first output and the speed-side first learning weight, and outputs the result as a second tentative command current.

特開2017-127176号公報JP 2017-127176 A

特許文献1が開示している技術は、摩擦モデルを表現するためにニューラルネットワークの学習モデルを用いる。当該技術はニューラルネットワークの入力値を細かく離散化することで非線形の摩擦モデルの表現を可能とするが、入力値の離散化を細かくするほど重み係数の数が増加するために学習に必要なデータ数及び計算量が増加する。つまり、当該技術には、精度が高い調整を行おうとすると計算負荷が大きくなるという課題がある。 The technology disclosed in Patent Document 1 uses a neural network learning model to represent a friction model. This technology makes it possible to represent a nonlinear friction model by finely discretizing the input values of the neural network, but the more finely the input values are discretized, the greater the number of weighting coefficients becomes, and so the amount of data and calculation required for learning increases. In other words, this technology has the problem that the calculation load becomes large when attempting to perform highly accurate adjustments.

上述のように、特許文献1が開示している技術では、少ない計算負荷で精度が高い摩擦補償を調整することができるモータ制御装置を提供することができないという課題がある。 As described above, the technology disclosed in Patent Document 1 has the problem that it is not possible to provide a motor control device that can adjust friction compensation with high accuracy and with a small calculation load.

本開示は、上記に鑑みてなされたものであって、少ない計算負荷で精度が高い摩擦補償を調整することができるモータ制御装置を得ることを目的とする。 The present disclosure has been made in consideration of the above, and aims to provide a motor control device that can adjust friction compensation with high accuracy and low computational load.

上述した課題を解決し、目的を達成するために、本開示に係るモータ制御装置は、位置指令に基づいてモータを駆動しモータに機械的に接続された制御対象が移動する軌跡を制御する軌跡制御を実行するモータ制御装置であって、位置指令及びモータの位置に基づいてモータのトルクの指令である第1トルク指令を算出するフィードバック制御を実行するフィードバック制御部と、モータ又は制御対象の動作の状態に関するデータである軌跡制御データを保持するデータ保持部とを有する。本開示に係るモータ制御装置は、軌跡制御データを、モータの速度とモータの加速度に基づいて分類される複数のデータセットに分割し複数のデータセットの各々について、軌跡制御データのうちの対応するデータセットのデータのみを用いて学習モデル成する学習部と、摩擦を補償するモータのトルクである摩擦補償トルクを複数の学習モデルに基づいて算出する摩擦補償トルク算出部と、第1トルク指令と摩擦補償トルクとを加算して第2トルク指令を算出する加算器と、第2トルク指令に追従するようにモータへの電流を制御してモータを駆動する電流制御部とを更に有する。 In order to solve the above-mentioned problems and achieve the object, a motor control device according to the present disclosure is a motor control device that performs trajectory control to drive a motor based on a position command and control a trajectory of a control target mechanically connected to the motor, and includes a feedback control unit that performs feedback control to calculate a first torque command that is a command for the torque of the motor based on the position command and the position of the motor, and a data storage unit that stores trajectory control data that is data related to the operating state of the motor or the control target. The motor control device according to the present disclosure further includes a learning unit that divides the trajectory control data into a plurality of data sets classified based on the speed and acceleration of the motor , and generates a learning model for each of the plurality of data sets using only data from the corresponding data set of the trajectory control data , a friction compensation torque calculation unit that calculates a friction compensation torque that is a torque of the motor that compensates for friction based on the plurality of learning models, an adder that calculates a second torque command by adding the first torque command and the friction compensation torque, and a current control unit that drives the motor by controlling a current to the motor so as to follow the second torque command.

本開示に係るモータ制御装置は、少ない計算負荷で精度が高い摩擦補償を調整することができるという効果を奏する。 The motor control device disclosed herein has the advantage of being able to adjust friction compensation with high accuracy and low computational load.

実施の形態1に係るモータ制御装置の構成を示すブロック図FIG. 1 is a block diagram showing a configuration of a motor control device according to a first embodiment. 実施の形態1に係るモータ制御装置が制御するモータと駆動対象である対象機械との例を模式的に示す斜視図FIG. 1 is a perspective view showing a schematic example of a motor controlled by a motor control device according to a first embodiment and a target machine that is a drive target; 実施の形態1に係る軌跡制御データについての閾値の設定の例を示す図FIG. 1 is a diagram showing an example of setting a threshold value for trajectory control data according to the first embodiment; 実施の形態1に係る分割された軌跡制御データから生成された複数の学習モデルの例を示す図FIG. 1 is a diagram showing an example of a plurality of learning models generated from divided trajectory control data according to the first embodiment; 実施の形態1に係るガウス過程回帰で表現された摩擦モデルの例を示す図FIG. 1 is a diagram showing an example of a friction model expressed by Gaussian process regression according to the first embodiment; 実施の形態2に係る決定木で表された摩擦モデルの例を示す図FIG. 13 is a diagram showing an example of a friction model represented by a decision tree according to the second embodiment; 実施の形態2にかかる決定木で構成される単一の学習モデルと入力空間毎に構築された複数の学習モデルとの比較を示す図FIG. 11 is a diagram showing a comparison between a single learning model configured with a decision tree according to the second embodiment and multiple learning models constructed for each input space. 実施の形態3に係るニューラルネットワークで表現された摩擦モデルの例を示す図FIG. 13 is a diagram showing an example of a friction model expressed by a neural network according to the third embodiment; 実施の形態3に係るニューラルネットワークモデルで構成される単一の学習モデルと入力空間毎に構築された複数の学習モデルとの比較を示す図FIG. 11 is a diagram showing a comparison between a single learning model configured with a neural network model according to the third embodiment and multiple learning models constructed for each input space. 実施の形態4に係る特定の入力空間でクーロンの摩擦モデルを採用した学習モデルの例を示す図FIG. 13 is a diagram showing an example of a learning model that employs a Coulomb friction model in a specific input space according to the fourth embodiment. 実施の形態5に係るクラスタリングによる軌跡制御データの複数の組への分割を示す図FIG. 13 is a diagram showing division of trajectory control data into a plurality of sets by clustering according to the fifth embodiment. 実施の形態1に係るモータ制御装置が有するモデル速度算出部、フィードバック制御部、摩擦補償トルク算出部、加算器、電流制御部、データ保持部及び学習部の少なくとも一部がプロセッサによって実現される場合のプロセッサを示す図FIG. 1 is a diagram showing a processor in the case where at least some of a model speed calculation unit, a feedback control unit, a friction compensation torque calculation unit, an adder, a current control unit, a data holding unit, and a learning unit included in a motor control device according to a first embodiment are realized by a processor. 実施の形態1に係るモータ制御装置が有するモデル速度算出部、フィードバック制御部、摩擦補償トルク算出部、加算器、電流制御部、データ保持部及び学習部の少なくとも一部が処理回路によって実現される場合の処理回路を示す図FIG. 1 is a diagram showing a processing circuit in the case where at least a part of a model speed calculation unit, a feedback control unit, a friction compensation torque calculation unit, an adder, a current control unit, a data holding unit, and a learning unit included in a motor control device according to a first embodiment is realized by the processing circuit.

以下に、実施の形態に係るモータ制御装置及びモータ制御方法を図面に基づいて詳細に説明する。 The motor control device and motor control method according to the embodiment are described in detail below with reference to the drawings.

実施の形態1.
図1は、実施の形態1に係るモータ制御装置10の構成を示すブロック図である。モータ制御装置10は、位置指令に基づいてモータ20を駆動しモータ20に機械的に接続された制御対象が移動する軌跡を制御する軌跡制御を実行する装置である。モータ制御装置10は、制御対象の機械である対象機械30を駆動するモータ20に接続され、モータ20を制御する。図1には、モータ20及び対象機械30も示されている。モータ20は、対象機械30に機械的に接続される。対象機械30は、モータ制御装置10がモータ20を制御することによって動作する。
Embodiment 1.
Fig. 1 is a block diagram showing the configuration of a motor control device 10 according to a first embodiment. The motor control device 10 is a device that performs trajectory control by driving a motor 20 based on a position command and controlling a trajectory along which a control target mechanically connected to the motor 20 moves. The motor control device 10 is connected to a motor 20 that drives a target machine 30, which is a machine to be controlled, and controls the motor 20. The motor 20 and the target machine 30 are also shown in Fig. 1. The motor 20 is mechanically connected to the target machine 30. The target machine 30 operates as a result of the motor control device 10 controlling the motor 20.

図2は、実施の形態1に係るモータ制御装置10が制御するモータ20と駆動対象である対象機械30との例を模式的に示す斜視図である。図2は、対象機械30がボールねじ装置である場合を示している。ボールねじ装置は、ボールねじ31と、テーブル32と、カップリング33とを有する。 Figure 2 is a perspective view showing a schematic example of a motor 20 controlled by the motor control device 10 according to the first embodiment and a target machine 30 that is the object to be driven. Figure 2 shows a case where the target machine 30 is a ball screw device. The ball screw device has a ball screw 31, a table 32, and a coupling 33.

モータ20は、カップリング33を介してボールねじ31に接続される。ボールねじ31は、モータ20の回転運動を直動運動に変換する。ボールねじ31にはテーブル32が取り付けられており、テーブル32は直動運動を行う。モータ20は、第1方向と、第1方向と逆方向の第2方向との間で回転方向を切り換えることができる。モータ20は、位置検出器21を有する。位置検出器21は、モータ20の位置を検出し、モータ20の位置をモータ制御装置10に出力する。以下では、モータ20の位置は、モータ位置と記載される。 The motor 20 is connected to a ball screw 31 via a coupling 33. The ball screw 31 converts the rotational motion of the motor 20 into linear motion. A table 32 is attached to the ball screw 31, and the table 32 performs linear motion. The motor 20 can switch its rotation direction between a first direction and a second direction opposite to the first direction. The motor 20 has a position detector 21. The position detector 21 detects the position of the motor 20 and outputs the position of the motor 20 to the motor control device 10. Hereinafter, the position of the motor 20 will be referred to as the motor position.

実施の形態1では、対象機械30はボールねじ装置であるが、対象機械30はボールねじ装置に限定されない。モータ制御装置10は、ガイド機構をはじめとする機械要素部品以外にも、モータ20によって駆動される対象機械30について広く適用される。対象機械30の例として、ボールねじ装置以外に、垂直多関節ロボット、NC(Numerical Control)工作機械又は実装機を挙げることができる。 In the first embodiment, the target machine 30 is a ball screw device, but the target machine 30 is not limited to a ball screw device. The motor control device 10 is widely applied to the target machine 30 driven by the motor 20, in addition to machine components such as guide mechanisms. Examples of the target machine 30 include a vertical articulated robot, an NC (Numerical Control) machine tool, or a mounting machine, in addition to a ball screw device.

図1に戻り、モータ制御装置10は、モデル速度算出部1と、フィードバック制御部2と、摩擦補償トルク算出部3と、加算器4と、電流制御部5と、データ保持部6と、学習部7とを有する。 Returning to FIG. 1, the motor control device 10 has a model speed calculation unit 1, a feedback control unit 2, a friction compensation torque calculation unit 3, an adder 4, a current control unit 5, a data retention unit 6, and a learning unit 7.

モデル速度算出部1は、位置指令を入力としてモデル速度を出力とする。位置指令は、例えばコントローラ又はNC装置といった指令値生成装置からモデル速度算出部1に入力される。モデル速度は、モータ20の目標速度を示す値として、位置指令を時間微分してフィルタを適用することで得られる。時間微分に係る微分処理は離散時間系においては差分処理に置き換えられ、現在のモータ指令と1サンプル前のモータ指令との差を制御処理周期で除した値が近似的な微分値として使用される。位置指令はモータ20の回転位置の目標値であるが、単位換算を行うことによってテーブル32の並進位置の目標値が位置指令として用いられてもよい。 The model speed calculation unit 1 receives a position command as input and outputs a model speed. The position command is input to the model speed calculation unit 1 from a command value generating device such as a controller or an NC device. The model speed is obtained by time-differentiating the position command and applying a filter as a value indicating the target speed of the motor 20. Differential processing related to time differentiation is replaced by difference processing in a discrete time system, and the value obtained by dividing the difference between the current motor command and the motor command one sample before by the control processing cycle is used as an approximate differential value. The position command is a target value for the rotational position of the motor 20, but the target value for the translational position of the table 32 may be used as the position command by performing unit conversion.

フィードバック制御部2は、位置指令及びモータ位置に基づいてモータ20のトルクの指令である第1トルク指令を算出するフィードバック制御を実行する。つまり、フィードバック制御部2は、位置指令とモータ位置とに基づくフィードバック制御によってモータ20のトルクの指令である第1トルク指令を算出する。フィードバック制御部2は、位置指令及びモータ位置を受け取り、第1トルク指令を出力する。モータ位置は、モータ20が有する位置検出器21からフィードバック制御部2に入力される。フィードバック制御部2は、位置指令とモータ位置との偏差である位置偏差を小さくするように、比例制御又は積分制御の位置制御処理を行い、位置偏差を小さくするような第1トルク指令を出力する。モータ位置は、テーブル32の位置を例えばリニアスケールといったセンサによって読み取られた値であってもよい。フィードバック制御部2は、モータ位置を位置指令に追従させるものであれば、どのようなものであってもよい。例えば、フィードバック制御部2は、2自由度制御を行ってもよい。 The feedback control unit 2 executes feedback control to calculate a first torque command, which is a command for the torque of the motor 20, based on the position command and the motor position. That is, the feedback control unit 2 calculates a first torque command, which is a command for the torque of the motor 20, by feedback control based on the position command and the motor position. The feedback control unit 2 receives the position command and the motor position, and outputs a first torque command. The motor position is input to the feedback control unit 2 from a position detector 21 of the motor 20. The feedback control unit 2 performs a position control process of proportional control or integral control so as to reduce a position deviation, which is a deviation between the position command and the motor position, and outputs a first torque command that reduces the position deviation. The motor position may be a value obtained by reading the position of the table 32 by a sensor such as a linear scale. The feedback control unit 2 may be any type of control as long as it causes the motor position to follow the position command. For example, the feedback control unit 2 may perform two-degree-of-freedom control.

摩擦補償トルク算出部3は、モデル速度算出部1からモデル速度を受け取り、摩擦補償トルクを出力する。摩擦補償トルク算出部3は、複数の学習モデルを用いて構成される摩擦モデルに基づいて摩擦補償トルクを算出する。後述するように、各学習モデルはそれぞれ異なる軌跡制御データに基づいて学習される。摩擦モデルは、モデル速度とモデル速度の微分値であるモデル加速度とに基づいて摩擦補償トルクを出力する。摩擦モデルの出力である摩擦補償トルクは、軌跡誤差の原因となる摩擦外乱の影響を小さくするようにモータ20のトルク指令に加算される。上述の説明では、摩擦モデルは、モデル速度及びモデル加速度を入力とするが、モータ位置から得られるモータ20の速度をはじめ、モータ20の位置、速度又は加速度に関する任意のデータを用いることができる。以下では、モータ20の速度は、モータ速度と記載される。 The friction compensation torque calculation unit 3 receives the model speed from the model speed calculation unit 1 and outputs the friction compensation torque. The friction compensation torque calculation unit 3 calculates the friction compensation torque based on a friction model configured using multiple learning models. As described below, each learning model is learned based on different trajectory control data. The friction model outputs the friction compensation torque based on the model speed and the model acceleration, which is the differential value of the model speed. The friction compensation torque, which is the output of the friction model, is added to the torque command of the motor 20 so as to reduce the influence of friction disturbance that causes trajectory error. In the above description, the friction model takes the model speed and the model acceleration as inputs, but any data related to the position, speed, or acceleration of the motor 20, including the speed of the motor 20 obtained from the motor position, can be used. Hereinafter, the speed of the motor 20 is described as the motor speed.

加算器4は、第1トルク指令と摩擦補償トルクとを加算して第2トルク指令を算出する。つまり、加算器4は、第1トルク指令と摩擦補償トルクとの和を計算し、計算した結果を第2トルク指令として出力する。 The adder 4 calculates the second torque command by adding the first torque command and the friction compensation torque. In other words, the adder 4 calculates the sum of the first torque command and the friction compensation torque, and outputs the calculation result as the second torque command.

電流制御部5は、第2トルク指令に追従するようにモータ20への電流を制御してモータ20を駆動する。つまり、電流制御部5は、モータ20のトルクが第2トルク指令に追従するように、モータ20に電流を供給する。 The current control unit 5 drives the motor 20 by controlling the current to the motor 20 so that the current follows the second torque command. In other words, the current control unit 5 supplies a current to the motor 20 so that the torque of the motor 20 follows the second torque command.

データ保持部6は、モータ20又は制御対象の動作の状態に関するデータである軌跡制御データを保持する。データ保持部6は、摩擦補償トルクを用いた軌跡制御の実行中におけるモータ20又は制御対象の動作の状態に関するデータである軌跡制御データを保持する。 The data storage unit 6 stores trajectory control data, which is data related to the operating state of the motor 20 or the controlled object. The data storage unit 6 stores trajectory control data, which is data related to the operating state of the motor 20 or the controlled object during execution of trajectory control using friction compensation torque.

データ保持部6は、モータ20が有する位置検出器21によって検出されたモータ位置とモータ20に供給される電流の値である電流値とを受け取り、軌跡制御データを出力する。軌跡制御データは、モータ位置を微分したモータ速度と、モータ速度を微分したモータ加速度と、トルク情報である電流値とを含むデータセットである。データ保持部6は、制御周期毎に取得されるモータ位置及び電流値に対し、軌跡制御データのサンプリングと保持とを行う。データ保持部6は、モータ速度の正負の符号が切り替わる前と後とにおける軌跡制御データが含まれるように軌跡制御データをサンプリングする。すなわち、データ保持部6は、第1方向と第2方向との間で回転方向が切り替わる前と後とにおける軌跡制御データをサンプリングし、保持する。例えば、データ保持部6の一部は、半導体メモリによって実現される。 The data storage unit 6 receives the motor position detected by the position detector 21 of the motor 20 and a current value, which is the value of the current supplied to the motor 20, and outputs trajectory control data. The trajectory control data is a data set including the motor speed obtained by differentiating the motor position, the motor acceleration obtained by differentiating the motor speed, and a current value, which is torque information. The data storage unit 6 samples and stores the trajectory control data for the motor position and current value acquired for each control period. The data storage unit 6 samples the trajectory control data so that the trajectory control data is included before and after the positive/negative sign of the motor speed is switched. In other words, the data storage unit 6 samples and stores the trajectory control data before and after the rotation direction is switched between the first direction and the second direction. For example, a part of the data storage unit 6 is realized by a semiconductor memory.

学習部7は、軌跡制御データを複数のデータセットに分割し複数のデータセットの各々についてデータセットに基づいた学習とデータセットに対応する学習モデルの生成とを実行する。つまり、学習部7は、軌跡制御データを複数のデータセットに分割し複数のデータセットの各々に基づいた学習によって複数のデータセットの各々に対応する学習モデルを生成する。例えば、学習部7は、パラメータの個数が可変である学習モデルを学習する。摩擦補償トルク算出部3は、摩擦を補償するモータ20のトルクである摩擦補償トルクを複数の学習モデルに基づいて算出する。学習部7は、入力される軌跡制御データを複数の組に分ける。学習部7は、軌跡制御データが内包するモータ速度の値及びモータ加速度の値に基づいて、軌跡制御データを複数の組に分ける。学習部7は、各組の軌跡制御データに対応する各学習モデルを学習する。学習部7には、軌跡制御データを分割するための境界を規定するデータ境界が予め設定されており、学習部7は、データ境界に基づいて軌跡制御データを分割する。 The learning unit 7 divides the trajectory control data into a plurality of data sets, and performs learning based on the data set for each of the plurality of data sets and generates a learning model corresponding to the data set. That is, the learning unit 7 divides the trajectory control data into a plurality of data sets, and generates a learning model corresponding to each of the plurality of data sets by learning based on each of the plurality of data sets. For example, the learning unit 7 learns a learning model in which the number of parameters is variable. The friction compensation torque calculation unit 3 calculates the friction compensation torque, which is the torque of the motor 20 that compensates for friction, based on a plurality of learning models. The learning unit 7 divides the input trajectory control data into a plurality of groups. The learning unit 7 divides the trajectory control data into a plurality of groups based on the motor speed value and the motor acceleration value contained in the trajectory control data. The learning unit 7 learns each learning model corresponding to the trajectory control data of each group. The learning unit 7 has a data boundary that defines a boundary for dividing the trajectory control data set in advance, and the learning unit 7 divides the trajectory control data based on the data boundary.

学習部7は、学習モデルを学習することにより、モータ速度とモータ加速度に対応する摩擦補償トルクとの関係を学習する。摩擦補償トルクは、軌跡制御データに基づいて、モータ20の電流値を単位換算した実トルクから、モータ20に接続された負荷の慣性モーメントとモータ加速度との積で表される慣性トルクを減ずることによって算出される。各学習モデルは、対応する各軌跡制御データを用いた教師あり学習によって学習される。 The learning unit 7 learns the relationship between the motor speed and the friction compensation torque corresponding to the motor acceleration by learning the learning model. The friction compensation torque is calculated by subtracting the inertia torque expressed as the product of the moment of inertia of the load connected to the motor 20 and the motor acceleration from the actual torque obtained by converting the current value of the motor 20 into units based on the trajectory control data. Each learning model is learned by supervised learning using the corresponding trajectory control data.

学習部7は、学習モデルの学習時には、モータ速度及びモータ加速度と、モータ速度及びモータ加速度に対応する摩擦補償トルクとの関係を学習し、使用時には学習モデルに対してモデル速度とモデル加速度とを入力として出力を摩擦補償トルクとする。 When learning the learning model, the learning unit 7 learns the relationship between the motor speed and motor acceleration and the friction compensation torque corresponding to the motor speed and motor acceleration, and when in use, the learning model receives the model speed and model acceleration as inputs and outputs the friction compensation torque.

以下で学習部7の処理を説明する。軌跡制御データを8個の組に分ける例を用いて学習部7の処理を説明する。軌跡制御データに関する閾値が設定されることを仮定する。まず、モータ速度に対する3個の閾値としてV1、V2及びV3が設定される。ひとつ目の閾値V1は負の値であり、二つ目の閾値V2は0の値であり、三つ目の閾値V3は正の値である。つまり、学習部7は、モータ速度に対応して、モータ速度が閾値V1未満である場合と、モータ速度が閾値V1以上閾値V2未満である場合と、モータ速度が閾値V2以上閾値V3未満である場合と、モータ速度が閾値V3以上である場合との四つの場合に軌跡制御データを分ける。モータ加速度に対する閾値としてA1が設定され、閾値A1の値を0とする。つまり、学習部7は、モータ加速度の符号に対応させて軌跡制御データを二つに分ける。 The processing of the learning unit 7 will be described below. The processing of the learning unit 7 will be described using an example in which the trajectory control data is divided into eight groups. It is assumed that thresholds related to the trajectory control data are set. First, three thresholds V1, V2, and V3 are set as thresholds for the motor speed. The first threshold V1 is a negative value, the second threshold V2 is a value of 0, and the third threshold V3 is a positive value. In other words, the learning unit 7 divides the trajectory control data into four cases corresponding to the motor speed: when the motor speed is less than the threshold V1, when the motor speed is equal to or greater than the threshold V1 and less than the threshold V2, when the motor speed is equal to or greater than the threshold V2 and less than the threshold V3, and when the motor speed is equal to or greater than the threshold V3. A1 is set as a threshold for the motor acceleration, and the value of the threshold A1 is set to 0. In other words, the learning unit 7 divides the trajectory control data into two in accordance with the sign of the motor acceleration.

上述の閾値によって、軌跡制御データは第1組から第8組までの8個の組に分けられる。8個の組に対応する各軌跡制御データの領域は、図3に示される通りである。図3は、実施の形態1に係る軌跡制御データについての閾値の設定の例を示す図である。説明のため、8個の組に分けられたi組目の軌跡制御データを第i組軌跡制御データと呼ぶことにする。iは、1から8までの整数である。第i組軌跡制御データに対応し、第i組軌跡制御データを用いて学習される学習モデルを第i学習モデルと呼ぶことにする。図4は、実施の形態1に係る分割された軌跡制御データから生成された複数の学習モデルの例を示す図である。図4は、加速度が正である領域において第1学習モデルから第4学習モデルまでの各学習モデルが生成された際の速度と摩擦との関係を示している。 The trajectory control data is divided into eight groups, from group 1 to group 8, by the above-mentioned threshold value. The areas of the trajectory control data corresponding to the eight groups are as shown in FIG. 3. FIG. 3 is a diagram showing an example of threshold setting for the trajectory control data according to the first embodiment. For the sake of explanation, the i-th group of trajectory control data divided into eight groups will be called the i-th group of trajectory control data. i is an integer from 1 to 8. The learning model corresponding to the i-th group of trajectory control data and learned using the i-th group of trajectory control data will be called the i-th learning model. FIG. 4 is a diagram showing an example of multiple learning models generated from the divided trajectory control data according to the first embodiment. FIG. 4 shows the relationship between speed and friction when each learning model from the first learning model to the fourth learning model is generated in a region where the acceleration is positive.

第i学習モデルの学習のためには、第i組目の軌跡制御データのみが使われる。そのため、全ての軌跡制御データを使ってひとつの学習モデルを学習する場合と比較すると、ひとつの学習モデルの学習に用いるデータセットのデータ量は少量となる。 Only the i-th set of trajectory control data is used to train the i-th learning model. Therefore, compared to training one learning model using all trajectory control data, the amount of data in the dataset used to train one learning model is small.

学習部7は、上述の複数の学習モデルを用いて摩擦モデルを構築する。具体的には、学習部7は、下記の式(1)に示されるように、8個の学習モデルの出力の総和を摩擦補償トルクとして出力する摩擦モデルを構築する。 The learning unit 7 constructs a friction model using the multiple learning models described above. Specifically, the learning unit 7 constructs a friction model that outputs the sum of the outputs of the eight learning models as the friction compensation torque, as shown in the following formula (1).

Figure 0007634458000001
Figure 0007634458000001

式(1)において、Tは摩擦補償トルクであり、Fは第i学習モデルの出力である摩擦トルクであり、wは第i学習モデルの出力に掛かる係数である。 In equation (1), T is a friction compensation torque, F i is a friction torque that is the output of the i-th learning model, and w i is a coefficient multiplied to the output of the i-th learning model.

学習部7が構築する摩擦モデルは、モデル速度及びモデル加速度を入力として計算される。wの決め方について、入力されるモデル速度及びモデル加速度を含む第i組軌跡制御データに対応するwのみを大きくするように、wは決められてもよい。例えば、第1組軌跡制御データの範囲内のモデル速度及びモデル加速度が入力される場合、wを1とし、wからwまでを0とするように、wは決められてもよい。 The friction model constructed by the learning unit 7 is calculated using the model speed and model acceleration as inputs. Regarding the method of determining w i , w i may be determined so that only w i corresponding to the i-th set of trajectory control data including the input model speed and model acceleration is increased. For example, when the model speed and model acceleration within the range of the first set of trajectory control data are input, w i may be determined so that w 1 is 1 and w 2 to w 8 are 0.

次に、第i組軌跡制御データに基づく第i学習モデルの学習を説明する。教師あり学習が行われる。第i学習モデルの入力が第i組軌跡制御データに含まれるモータ速度及びモータ加速度であって、第i学習モデルの出力が摩擦トルクであるので、教師あり学習においては、モータ速度、モータ加速度及び摩擦トルクを含むデータセットを用いて学習が行われる。当該データセットに関して、モータ速度及びモータ加速度については、第i組軌跡制御データに含まれるデータが用いられる。摩擦トルクは、第i組軌跡制御データに基づいて、モータ20の電流値を単位換算した実トルクから、モータ20に接続された負荷の慣性モーメントとモータ加速度との積で表される慣性トルクを減ずることにより算出される。 Next, learning of the ith learning model based on the ith group trajectory control data will be described. Supervised learning is performed. Since the input of the ith learning model is the motor speed and motor acceleration included in the ith group trajectory control data, and the output of the ith learning model is friction torque, in supervised learning, learning is performed using a data set including the motor speed, motor acceleration, and friction torque. With regard to the data set, data included in the ith group trajectory control data is used for the motor speed and motor acceleration. The friction torque is calculated by subtracting the inertia torque, which is expressed as the product of the moment of inertia of the load connected to the motor 20 and the motor acceleration, from the actual torque obtained by converting the current value of the motor 20 into units based on the ith group trajectory control data.

学習モデルの例は、ガウス過程回帰で表現される学習モデルである。ガウス過程回帰で表現される学習モデルがデータの個数と同数のパラメータを有するため、データの個数がパラメータの個数となる。ガウス過程回帰で表現される学習モデルは、各データと入力のモータ速度との距離に対応して、摩擦トルクを出力する。 An example of a learning model is a learning model expressed by Gaussian process regression. Since a learning model expressed by Gaussian process regression has the same number of parameters as the number of data, the number of data is the number of parameters. A learning model expressed by Gaussian process regression outputs a friction torque corresponding to the distance between each data and the input motor speed.

このとき、摩擦トルクの予測分布も、ガウス分布の分散として同時に算出される。ただし、摩擦トルクの予測分布が算出される際に用いられる距離はカーネル関数kによって算出され、具体的に、xとxn’との2点間の距離は、一般的に下記の式(2)に示されるガウスカーネルを用いて表現される。なお、x及びxn’はベクトルである。nは、1以上の整数である。 At this time, the predicted distribution of the friction torque is also calculated at the same time as the variance of the Gaussian distribution. However, the distance used when calculating the predicted distribution of the friction torque is calculated by a kernel function k, and specifically, the distance between two points x n and x n' is generally expressed by using the Gaussian kernel shown in the following formula (2). Note that x n and x n' are vectors. n is an integer equal to or greater than 1.

Figure 0007634458000002
Figure 0007634458000002

式(2)において、θ及びθは学習部7に設定されるハイパーパラメータである。ただし、カーネル関数は、ガウスカーネルに限定されず、線形カーネル、指数カーネル、周期カーネル、又はMaternカーネルであってもよく、さらに、これらの和又は積の組み合わせで構成されたカーネル関数であってもよい。同時に、観測された電流値及び算出された摩擦トルクに観測ノイズが含まれていると考え、観測ノイズの平均が0であり、分散がσである下記の式(3)に示されるガウス分布に観測ノイズがしたがっているものとして、下記の式(4)に示されるように、カーネル関数kにノイズ項を追加したものが用いられてもよい。 In formula (2), θ 1 and θ 2 are hyperparameters set in the learning unit 7. However, the kernel function is not limited to the Gaussian kernel, and may be a linear kernel, an exponential kernel, a periodic kernel, or a Matern kernel, or may be a kernel function formed by a combination of the sum or product of these. At the same time, it is considered that the observed current value and the calculated friction torque contain observation noise, and the observation noise follows a Gaussian distribution shown in formula (3) below, in which the average of the observation noise is 0 and the variance is σ 2. As shown in formula (4) below, a kernel function k with a noise term added thereto may be used.

Figure 0007634458000003
Figure 0007634458000003

Figure 0007634458000004
Figure 0007634458000004

式(4)において、デルタ関数δ(x,xn’)は、同じ軌跡制御データ間で距離計算を行うn=n’の場合に1を返し、n=n’以外の場合に0を返す関数である。図5は、実施の形態1に係るガウス過程回帰で表現された摩擦モデルの例を示す図である。図5は、ガウス過程回帰で表現される学習モデルを示している。 In formula (4), the delta function δ(x n , x n′ ) is a function that returns 1 when n=n′ in distance calculation between the same trajectory control data, and returns 0 when n=n′. Fig. 5 is a diagram showing an example of a friction model expressed by Gaussian process regression according to the first embodiment. Fig. 5 shows a learning model expressed by Gaussian process regression.

学習部7は、ガウス過程回帰のカーネル関数におけるハイパーパラメータを推定し、ハイパーパラメータを同定した後の学習モデルを出力する。ハイパーパラメータは、軌跡制御データから構成されるXとハイパーパラメータをまとめたθ=(θ,θ,σ)とに対する摩擦トルクyの尤度関数p(y|X,θ)が最大となるように推定される。尤度関数が最大となるようなハイパーパラメータθの同定方法として、θ空間のグリッド探索若しくはMCMC(Markov Chain Monte Carlo)法を用いた探索手法、又は、最急降下法、共役勾配法若しくは準ニュートン法をはじめとする勾配法を用いることができる。なお、X,y及びハイパーパラメータをまとめたθはベクトルである。 The learning unit 7 estimates hyperparameters in the kernel function of the Gaussian process regression, and outputs a learning model after identifying the hyperparameters. The hyperparameters are estimated so that a likelihood function p(y|X, θ) of friction torque y for X consisting of trajectory control data and θ=(θ 1 , θ 2 , σ 2 ) summarizing the hyperparameters is maximized. As a method for identifying the hyperparameter θ that maximizes the likelihood function, a search method using a grid search in the θ space or an MCMC (Markov Chain Monte Carlo) method, or a gradient method such as a steepest descent method, a conjugate gradient method, or a quasi-Newton method can be used. It should be noted that θ summarizing X, y, and the hyperparameters is a vector.

ガウス過程回帰で表現される学習モデルを用いることで、学習モデルが摩擦トルクを出力する際、学習部7は、摩擦トルクの分散を同時に算出することができる。したがって、学習モデルが出力する摩擦トルクの精度を評価することができる。例えば精度が低い場合、学習部7は、軌跡制御データを増やしたり、軌跡制御データを取得しなおしたりして精度を向上させることが可能となる。 By using a learning model expressed by Gaussian process regression, when the learning model outputs a friction torque, the learning unit 7 can simultaneously calculate the variance of the friction torque. Therefore, the accuracy of the friction torque output by the learning model can be evaluated. For example, if the accuracy is low, the learning unit 7 can increase the trajectory control data or reacquire the trajectory control data to improve the accuracy.

ただし、ガウス過程回帰における学習に用いられるデータの個数がNである場合、下記の式(5)に示されるように、Nの三乗に比例する計算量の計算が必要になる。Nは、自然数である。 However, when the number of data used for learning in Gaussian process regression is N, the amount of calculation required is proportional to the cube of N, as shown in the following formula (5). N is a natural number.

Figure 0007634458000005
Figure 0007634458000005

つまり、データの個数の増加に伴う計算量の増加が非常に大きく、このことが効率的な調整を困難とする原因となる。実施の形態1では、軌跡制御データは8個に分割される。説明の簡単のためにデータが等分されるとすると、計算量は下記の式(6)に示されるようになる。 In other words, the increase in the amount of calculations as the number of data items increases is very large, which makes efficient adjustment difficult. In the first embodiment, the trajectory control data is divided into eight pieces. For simplicity of explanation, if the data is divided equally, the amount of calculations is as shown in the following formula (6).

Figure 0007634458000006
Figure 0007634458000006

つまり、データを分割する前の計算量と比較すると、計算量を64分の1に低減することができ、効率的な調整が可能となる。上述の例では軌跡制御データは等分されるが、分割については必ずしも等分である必要はない。 In other words, compared to the amount of calculation before the data was divided, the amount of calculation can be reduced to 1/64, enabling efficient adjustment. In the above example, the trajectory control data is divided equally, but the division does not necessarily have to be equal.

実施の形態1では学習モデルとしてガウス過程回帰が用いられるが、軌跡制御データから学習モデルを構築することができれば、他の学習手法が用いられてもよい。他の学習手法においても軌跡制御データを分割して、分割によって得られる複数のデータ群の各々に対応する複数の学習モデルを学習することで効率の良い調整を実現することができる。 In the first embodiment, Gaussian process regression is used as the learning model, but other learning methods may be used as long as a learning model can be constructed from the trajectory control data. In other learning methods, efficient adjustment can also be achieved by dividing the trajectory control data and learning multiple learning models corresponding to each of the multiple data groups obtained by the division.

以上により、実施の形態1によれば、少ない計算負荷で精度が高い摩擦補償を調整することができるモータ制御装置10を提供することができる。 As described above, according to the first embodiment, it is possible to provide a motor control device 10 that can adjust friction compensation with high accuracy and low computational load.

実施の形態2.
次に、実施の形態2に係るモータ制御装置を説明する。実施の形態1では、学習部7における学習モデルをガウス過程回帰により表現し、摩擦外乱のフィードフォワード補正を行うモータ制御装置10を説明した。実施の形態2に係るモータ制御装置は、決定木によって摩擦モデルを表現する。摩擦補償トルク算出部3及び学習部7以外については、実施の形態1と同様であるため、説明を省略する。
Embodiment 2.
Next, a motor control device according to embodiment 2 will be described. In embodiment 1, the motor control device 10 is described in which the learning model in the learning unit 7 is expressed by Gaussian process regression and feedforward correction of friction disturbance is performed. The motor control device according to embodiment 2 expresses the friction model by a decision tree. Since the components other than the friction compensation torque calculation unit 3 and the learning unit 7 are the same as those in embodiment 1, the description will be omitted.

図6は、実施の形態2に係る決定木で表された摩擦モデルの例を示す図である。決定木の学習では、下記の式(7)で示される目的関数IGを最大化するように、ノード分割が行われる。 Figure 6 shows an example of a friction model represented by a decision tree according to embodiment 2. In learning the decision tree, node splitting is performed to maximize the objective function IG shown in the following equation (7).

Figure 0007634458000007
Figure 0007634458000007

式(7)において、Dは親データセット又は親ノードであり、fは特徴量数であり、Dleftは親ノードから見た左の子ノードであり、Drightは親ノードから見た右の子ノードであり、Nは親ノードDに含まれるデータ数であり、Nleftは左の子ノードDleftに含まれるデータ数であり、Nrightは右の子ノードDrightに含まれるデータ数であり、Iは不純度指標である。不純度指標Iについては、実施の形態2では摩擦トルクに対する回帰問題が扱われるため、下記の式(8)に示される平均二乗誤差が用いられる。 In formula (7), D p is a parent dataset or a parent node, f is the number of features, D left is a left child node from the parent node, D right is a right child node from the parent node, N p is the number of data included in the parent node D p , N left is the number of data included in the left child node D left , N right is the number of data included in the right child node D right , and I is an impurity index. Regarding the impurity index I, since a regression problem for friction torque is dealt with in the second embodiment, the mean square error shown in the following formula (8) is used.

Figure 0007634458000008
Figure 0007634458000008

式(8)において、yはノードDにおける各サンプルの値であり、yは当該各サンプルの値の平均値である。NはノードDにおけるサンプル数である。すなわち、yは軌跡制御データの出力に対応し、親ノードの分散から二つの子ノードの分散の和を引いた目的関数IGが最大となるように、分岐は生成される。ノードDにおける分岐候補の選び方に関し、出力yに対応する複数の軌跡制御データの入力xをモータ速度又はモータ加速度の軸に着目して小さい順に並べ、隣接する軌跡制御データの中間地点を分岐候補点として、複数の分岐候補の各々について式(6)の評価が行われる。 In formula (8), y i is the value of each sample at node D t , and y t is the average value of the values of each sample. N t is the number of samples at node D t . That is, y i corresponds to the output of the trajectory control data, and the branch is generated so that the objective function IG obtained by subtracting the sum of the variances of the two child nodes from the variance of the parent node is maximized. Regarding the method of selecting branch candidates at node D t , the inputs x i of the multiple trajectory control data corresponding to the output y i are arranged in ascending order with attention paid to the axis of the motor speed or motor acceleration, and the midpoint of the adjacent trajectory control data is set as the branch candidate point, and formula (6) is evaluated for each of the multiple branch candidates.

実施の形態1と同様に、軌跡制御データを8個の組に分ける例を用いて、決定木における複数の学習モデルを用いた際の計算量の削減を説明する。軌跡制御データに関する閾値V1、閾値V2、閾値V3及び閾値A1の設定方法、並びに第i組軌跡制御データと第i学習モデルとの対応は、実施の形態1と同じである。学習に用いられる軌跡制御データの個数がNであって、図6に示される単一の学習モデルと同サイズの摩擦モデルを学習する場合、式(6)の評価を各層で最大(N-1)回行う必要がある。層数がNに比べて十分に小さい場合、下記の式(9)に示されるように、Nの三乗に比例する計算量の計算が必要になる。 As in the first embodiment, the reduction in the amount of calculations when using multiple learning models in a decision tree will be explained using an example in which trajectory control data is divided into eight groups. The method of setting the thresholds V1, V2, V3, and A1 for the trajectory control data, and the correspondence between the i-th group of trajectory control data and the i-th learning model are the same as in the first embodiment. When the number of trajectory control data used for learning is N, and a friction model of the same size as the single learning model shown in FIG. 6 is learned, it is necessary to evaluate formula (6) a maximum of (N-1) times in each layer. When the number of layers is sufficiently smaller than N, a calculation amount proportional to the cube of N is required, as shown in the following formula (9).

Figure 0007634458000009
Figure 0007634458000009

つまり、データ数の増加に伴う計算量の増加が非常に大きく、このことが効率的な調整を困難とする原因となる。 In other words, the amount of calculation increases significantly as the amount of data increases, making efficient adjustments difficult.

実施の形態2では、軌跡制御データ及び学習モデルは8個に分割される。閾値V1、閾値V2、閾値V3及び閾値A1が既知として予め設定されるため、式(7)及び式(8)の計算を行う必要がなく、各軌跡制御データがどの学習モデルに対応するかを判定するのみでよく、下記の式(10)に示される通り、計算量はNに比例する。 In the second embodiment, the trajectory control data and learning model are divided into eight. Since thresholds V1, V2, V3, and A1 are set in advance as known values, there is no need to calculate equations (7) and (8). It is only necessary to determine which learning model each trajectory control data corresponds to, and the amount of calculation is proportional to N, as shown in equation (10) below.

Figure 0007634458000010
Figure 0007634458000010

つまり、データを分割する前の計算量と比較すると、計算量をNの二乗分の1に低減することができ、効率的な調整が可能となる。図7は、実施の形態2にかかる決定木で構成される単一の学習モデルと入力空間毎に構築された複数の学習モデルとの比較を示す図である。図7は、各組へ分割後の学習モデルを示している。 In other words, compared to the amount of calculation before the data was divided, the amount of calculation can be reduced to one squared N, enabling efficient adjustment. Figure 7 is a diagram showing a comparison between a single learning model configured with a decision tree according to the second embodiment and multiple learning models constructed for each input space. Figure 7 shows the learning models after division into each group.

決定木は、与えられるデータに偏りがある場合及び単一の深い木を構成する場合、過学習になりやすい性質を有する。そのため、対象の既知の物理的な性質を予め閾値として設定し、複数の浅い木に分けて複数の浅い木の各々について別に学習を行うことによって、学習モデルの汎化性能を高められることが知られている。 Decision trees have a tendency to become overlearned when the data given is biased or when a single deep tree is constructed. For this reason, it is known that the generalization performance of a learning model can be improved by setting a threshold value based on known physical properties of the target, dividing the target into multiple shallow trees, and training each of the multiple shallow trees separately.

したがって、実施の形態2によれば、少ない計算負荷で精度が高い摩擦補償を調整することができるモータ制御装置を提供することができる。 Therefore, according to the second embodiment, it is possible to provide a motor control device that can adjust friction compensation with high accuracy with a small calculation load.

摩擦モデルには、上述のような決定木を複数含むランダムフォレスト又は勾配ブースティング決定木をはじめとするアンサンブル法が用いられてもよく、構築過程で木の生成を早めに止める事前枝刈りと、木を構築した後に情報の少ないノードを削除する事後枝刈りとのうちの一方又は両方が適用されてもよい。 The friction model may use an ensemble method such as a random forest or gradient boosting decision tree that includes multiple decision trees as described above, and may apply one or both of pre-pruning, which stops tree generation early during the construction process, and post-pruning, which removes nodes with little information after the tree is constructed.

実施の形態3.
次に、実施の形態3に係るモータ制御装置を説明する。実施の形態1では、学習部7における学習モデルをガウス過程回帰により表現し、実施の形態2では、学習部7における学習モデルを決定木により表現し、摩擦外乱のフィードフォワード補正を行うモータ制御装置を説明した。実施の形態3に係るモータ制御装置では、摩擦モデルがニューラルネットワークによって表現される。摩擦補償トルク算出部3及び学習部7以外については、実施の形態1及び実施の形態2と同様であるため、説明を省略する。
Embodiment 3.
Next, a motor control device according to a third embodiment will be described. In the first embodiment, the learning model in the learning unit 7 is expressed by Gaussian process regression, and in the second embodiment, the learning model in the learning unit 7 is expressed by a decision tree, and a motor control device that performs feedforward correction of friction disturbance has been described. In the motor control device according to the third embodiment, the friction model is expressed by a neural network. As the components other than the friction compensation torque calculation unit 3 and the learning unit 7 are the same as those in the first and second embodiments, the description will be omitted.

図8は、実施の形態3に係るニューラルネットワークで表現された摩擦モデルの例を示す図である。ニューラルネットワークの各層をXとおくと、層Xの入出力は下記の漸化式(11)で表現される。 8 is a diagram showing an example of a friction model expressed by a neural network according to embodiment 3. If each layer of the neural network is represented as X i , the input and output of layer X i are expressed by the following recurrence formula (11).

Figure 0007634458000011
Figure 0007634458000011

式(11)において、Wは行列であり、X及びBは縦ベクトルであり、Wは重み行列と呼ばれ、Bはバイアスベクトルと呼ばれる。したがって、ニューラルネットワークの計算量は、W及びBの行数と一致する一層あたりのノード数Cと、ニューラルネットワーク全体に含まれる層数Lとによって決まる。ニューラルネットワークの層数とノード数とを増やすことで、学習モデルはより高次の複雑な学習モデルとなるため、一般的にニューラルネットワークの推定精度と計算量とはトレードオフの関係にある。 In formula (11), W i is a matrix, X i and B i are column vectors, W is called a weight matrix, and B is called a bias vector. Therefore, the computational complexity of a neural network is determined by the number of nodes C per layer, which is equal to the number of rows of W and B, and the number of layers L included in the entire neural network. By increasing the number of layers and nodes of a neural network, the learning model becomes a more complex learning model of a higher order, so there is generally a trade-off between the estimation accuracy and the computational complexity of a neural network.

実施の形態1及び実施の形態2と同様に、実施の形態3でも軌跡制御データが8個の組に分けられる例が示される。図8に示すように、層数L、ノード数Cの単一の学習モデルを用いて学習した場合、層数L及びノード数Cは、速度ゼロ近傍の複雑な曲線と一定速度以上の滑らかな曲線とを同時に表現するために比較的大きな値をとる必要があり、このときの計算量は、下記の式(12)に示されるように、L×Cで表される。 As in the case of the first and second embodiments, the third embodiment also shows an example in which the trajectory control data is divided into eight sets. As shown in Fig. 8, when learning is performed using a single learning model having a number of layers Ls and a number of nodes Cs , the number of layers Ls and the number of nodes Cs need to be relatively large values in order to simultaneously express a complex curve near zero speed and a smooth curve above a certain speed, and the amount of calculation in this case is expressed as Ls × Cs as shown in the following formula (12).

Figure 0007634458000012
Figure 0007634458000012

つまり、単一の学習モデルのみを使用することに伴う計算量の増加が非常に大きく、このことが効率的な調整を困難とする原因となる。 In other words, the increase in computational complexity associated with using only a single learning model is significant, which makes efficient adjustment difficult.

実施の形態3では、軌跡制御データ及び学習モデルは8個に分割される。ただし、閾値V1、閾値V2、閾値V3及び閾値A1は既知である。複雑に変化するゼロ速度近傍の閾値V1から閾値V3までの間の曲線について、この領域に対応する学習モデルのLをLとおくと共に、当該学習モデルのCをCとおくと、各モデルの計算量はL×Cと表される。L×Cは、全速度帯の摩擦変化を学習する必要なく得られるため、下記の式(13)に示されるように、L×Cと比較すると小さな値となる。mは、1以上の整数である。 In the third embodiment, the trajectory control data and the learning model are divided into eight parts. However, the thresholds V1, V2, V3, and A1 are known. For a curve between the thresholds V1 and V3 near zero speed that changes in a complex manner, if L of the learning model corresponding to this region is set as Lm and C of the learning model is set as Cm , the amount of calculation for each model is expressed as Lm x Cm . Since Lm x Cm can be obtained without the need to learn friction changes in all speed ranges, it is a small value compared to Ls x Cs , as shown in the following formula (13). m is an integer of 1 or more.

Figure 0007634458000013
Figure 0007634458000013

さらに、閾値V1以下及び閾値V3以上の領域に対応する学習モデルのLをLとおくと共に、当該領域に対応する学習モデルのCをCとおくと、計算量はL×Cと表される。当該領域ではゼロ速度近傍の閾値V1から閾値V3までの曲線に比べて急峻な変化の無い単調な形状となることが知られているため、下記の式(14)に示されるように、L×CはL×Cと比較すると小さな値となる。 Furthermore, if L of the learning model corresponding to the region below threshold V1 and above threshold V3 is denoted as Lh and C of the learning model corresponding to the region is denoted as Ch , the amount of calculation is expressed as Lh × Ch . Since it is known that the curve in the region has a monotonous shape without abrupt changes compared to the curve from threshold V1 to threshold V3 near zero speed, Lh × Ch is a smaller value than Ls × Cs , as shown in the following formula (14).

Figure 0007634458000014
Figure 0007634458000014

つまり、データを分割する前の計算量と比較するとデータを分割した後の計算量を低減することができ、効率的な調整が可能となる。図9は、実施の形態3に係るニューラルネットワークモデルで構成される単一の学習モデルと入力空間毎に構築された複数の学習モデルとの比較を示す図である。図9は、各組へ分割後の学習モデルを示している。 In other words, the amount of calculations after dividing the data can be reduced compared to the amount of calculations before dividing the data, enabling efficient adjustment. Figure 9 is a diagram showing a comparison between a single learning model configured with a neural network model according to embodiment 3 and multiple learning models constructed for each input space. Figure 9 shows the learning models after division into each group.

実施の形態2で述べた決定木と同様に、ニューラルネットワークは、与えられるデータに偏りがある場合又はサイズが大きい場合、過学習になりやすい性質を有する。そこで、軌跡制御データの出力の特性が入力空間の特定の領域で大きく変化することが既知である場合、当該領域毎にニューラルネットワークのモデルを分けて個々に学習することによって、各々の学習モデルを出力の複雑さに合わせて適切なサイズに変更することができ、汎化性能を高めることができる。 As with the decision tree described in the second embodiment, neural networks have a tendency to become overtrained when the data provided is biased or large in size. Therefore, if it is known that the output characteristics of the trajectory control data change significantly in a specific region of the input space, by dividing the neural network model for each region and training them individually, each learning model can be changed to an appropriate size according to the complexity of the output, thereby improving generalization performance.

したがって、実施の形態3によれば、比較的少ない計算負荷で比較的精度が高い摩擦補償を調整することができるモータ制御装置を提供することができる。 Therefore, according to the third embodiment, it is possible to provide a motor control device that can adjust friction compensation with relatively high accuracy with a relatively small computational load.

ニューラルネットワークについて、中間層の入出力関係に再帰的な構造を持つRNN(Recurrent Neural Network)、LSTM(Long Short Term Memory)若しくはGRU(Gated Recurrent Unit)といったリカレント型と呼ばれるニューラルネットワーク、又は、CNN(Convolutional Neural Network)、FCN(Fully Convolutional Network)若しくはTCN(Temporal Convolutional Network)といった畳み込み型のニューラルネットワークが用いられてもよい。 As for the neural network, a recurrent type neural network such as an RNN (Recurrent Neural Network), LSTM (Long Short Term Memory) or GRU (Gated Recurrent Unit) that has a recursive structure in the input/output relationship of the intermediate layer, or a convolution type neural network such as a CNN (Convolutional Neural Network), FCN (Fully Convolutional Network) or TCN (Temporal Convolutional Network) may be used.

実施の形態4.
次に、実施の形態4に係るモータ制御装置を説明する。実施の形態1から実施の形態3まででは、学習部7における学習モデルは、同一の機械学習アルゴリズムが用いられて入力の領域毎に構築される。実施の形態4に係るモータ制御装置は、領域毎に異なる機械学習アルゴリズム又は関数形を用いることによって摩擦モデルを表現する。摩擦補償トルク算出部3及び学習部7以外については、実施の形態1及び実施の形態2と同様であるため、説明を省略する。
Embodiment 4.
Next, a motor control device according to embodiment 4 will be described. In embodiments 1 to 3, the learning model in the learning unit 7 is constructed for each input region using the same machine learning algorithm. The motor control device according to embodiment 4 expresses a friction model by using a different machine learning algorithm or function form for each region. As the components other than the friction compensation torque calculation unit 3 and the learning unit 7 are the same as those in embodiments 1 and 2, description thereof will be omitted.

実施の形態4でも、実施の形態1から実施の形態3までと同様に、軌跡制御データを8個の組に分ける例が用いられる。実施の形態3で述べた通り、閾値V1以下及び閾値V3以上の領域では、ゼロ速度近傍の閾値V1から閾値V3までの曲線に比べて急峻な変化の無い単調な形状となることが知られているため、一般的に、対象機械30の一例であるボールねじ装置にかかる摩擦は、下記の式(15)に示されるゼロ速度のモータ速度における一定閾値以下の駆動力とつりあうクーロン摩擦と、モータ速度に対する比例関係で表される粘性摩擦とにより、精度よく表される。 In the fourth embodiment, as in the first to third embodiments, an example is used in which the trajectory control data is divided into eight sets. As described in the third embodiment, it is known that in the regions below threshold V1 and above threshold V3, the curve has a monotonous shape without any abrupt changes compared to the curve from threshold V1 to threshold V3 near zero speed. Therefore, the friction acting on a ball screw device, which is an example of the target machine 30, is generally accurately represented by Coulomb friction that balances with the driving force below a certain threshold at the motor speed of zero speed shown in the following formula (15), and viscous friction that is expressed in a proportional relationship to the motor speed.

Figure 0007634458000015
Figure 0007634458000015

式(15)において、fは摩擦力であり、vは粘性摩擦係数であり、wはモータ速度であり、cはクーロン摩擦項である。 In equation (15), f is the friction force, v is the viscous friction coefficient, w is the motor speed, and c is the Coulomb friction term.

モータ速度の正負の符号が切り替わる前と後、つまり閾値V1から閾値V3までの領域においては、例えばスティックスリップ現象に代表されるモータ速度以外の荷重条件に依存する非線形な摩擦が生ずることが知られている。当該摩擦は、対象機械30の軸の運動方向が反転する際に象限突起として生じる軌跡誤差の要因となっている。 It is known that nonlinear friction that depends on load conditions other than the motor speed, such as the stick-slip phenomenon, occurs before and after the motor speed switches from positive to negative, that is, in the region between thresholds V1 and V3. This friction is a cause of trajectory errors that appear as quadrant projections when the direction of motion of the axis of the target machine 30 is reversed.

実施の形態4では、ゼロ速度近傍の閾値V1から閾値V3までの領域のみ実施の形態1から3までに記載されている機械学習アルゴリズムで学習モデルが構築され、閾値V1以下及び閾値V3以上の領域では、式(15)に示されるクーロンの摩擦モデルで推論が行われる。これにより、実施の形態4に係るモータ制御装置は、摩擦モデルの精度を劣化することなく、計算量を削減することができる。図10は、実施の形態4に係る特定の入力空間でクーロンの摩擦モデルを採用した学習モデルの例を示す図である。図10は、閾値V1以下及び閾値V3以上の領域でクーロンの摩擦モデルを採用した学習モデルの例を示している。 In the fourth embodiment, a learning model is constructed using the machine learning algorithm described in the first to third embodiments only in the region from threshold V1 to threshold V3 near zero speed, and inference is performed using the Coulomb friction model shown in equation (15) in the region below threshold V1 and above threshold V3. This allows the motor control device according to the fourth embodiment to reduce the amount of calculations without degrading the accuracy of the friction model. FIG. 10 is a diagram showing an example of a learning model that employs the Coulomb friction model in a specific input space according to the fourth embodiment. FIG. 10 shows an example of a learning model that employs the Coulomb friction model in the region below threshold V1 and above threshold V3.

閾値V1以下及び閾値V3以上の領域で用いられる摩擦モデルについては、クーロンの摩擦モデルでなく、例えば、LuGre Model、Seven parameter model、又は、State variable modelといった摩擦モデルが用いられてもよい。 For the friction model used in the region below threshold V1 and above threshold V3, a friction model such as the LuGre Model, the Seven parameter model, or the State variable model may be used instead of the Coulomb friction model.

閾値V1以下及び閾値V3以上の領域と閾値V1から閾値V3までの領域とで、実施の形態1から実施の形態3までで挙げられた機械学習アルゴリズムと学習モデルとが切り替えられてもよい。閾値V1以下及び閾値V3以上の領域でデータ数Nを小さく設定したガウス過程回帰を用い、閾値V1から閾値V3までの領域でニューラルネットワークを用いることによって、単一の摩擦モデルを用いる場合に比べて計算量が少ない学習モデルを構成することができる。用いられる機械学習アルゴリズムについても、実施の形態1から実施の形態3までで挙げられた手法に限定されず、回帰モデルを学習可能な任意のアルゴリズムが用いられてもよい。 The machine learning algorithm and learning model given in the first to third embodiments may be switched between the region below threshold V1 and above threshold V3 and the region between threshold V1 and threshold V3. By using Gaussian process regression with a small number of data N set in the region below threshold V1 and above threshold V3, and using a neural network in the region between threshold V1 and threshold V3, a learning model with a smaller amount of calculations can be configured compared to the case where a single friction model is used. The machine learning algorithm used is not limited to the methods given in the first to third embodiments, and any algorithm capable of learning a regression model may be used.

したがって、実施の形態4によれば、少ない計算負荷で精度が高い摩擦補償を調整することができるモータ制御装置を提供することができる。 Therefore, according to the fourth embodiment, it is possible to provide a motor control device that can adjust friction compensation with high accuracy and low computational load.

実施の形態5.
次に、実施の形態5に係るモータ制御装置を説明する。実施の形態1から実施の形態4まででは、学習部7の動作によって軌跡制御データを複数の組に分けて各組の軌跡制御データに対応する各学習モデルが学習されるモータ制御装置を説明した。実施の形態1から実施の形態4まででは、軌跡制御データは、予め設定された閾値に基づいて分けられる。
Embodiment 5.
Next, a motor control device according to embodiment 5 will be described. In the first to fourth embodiments, the motor control device has been described in which the trajectory control data is divided into a plurality of groups by the operation of the learning unit 7, and each learning model corresponding to the trajectory control data of each group is learned. In the first to fourth embodiments, the trajectory control data is divided based on a preset threshold value.

実施の形態5では、軌跡制御データを分けるための閾値は事前に設定されない。実施の形態5では、クラスタリングの手法を用いて軌跡制御データを複数の組に分けて各組の軌跡制御データに対応する各学習モデルを学習する学習部を有するモータ制御装置を説明する。実施の形態5の学習部は、学習部7eと記載される。学習部7e以外については、実施の形態1と同様であるため説明を省略する。 In the fifth embodiment, a threshold value for dividing the trajectory control data is not set in advance. In the fifth embodiment, a motor control device having a learning unit that divides the trajectory control data into a plurality of groups using a clustering technique and learns each learning model corresponding to the trajectory control data of each group is described. The learning unit in the fifth embodiment is referred to as learning unit 7e. The components other than learning unit 7e are the same as those in the first embodiment, so the description is omitted.

上述の通り、実施の形態5に係るモータ制御装置は、学習部7eを有する。学習部7eは、入力される軌跡制御データを複数の組に分ける。学習部7eは、軌跡制御データに基づくクラスタリングにより軌跡制御データを分割する。学習部7eは、軌跡制御データが内包するモータ速度の値及び加速度の値に基づいて、k平均法によって軌跡制御データを複数の組に分ける。学習部7eは、各組の軌跡制御データに対応する各学習モデルを学習する。学習モデルの入力はモータ速度及びモータ加速度であって、学習モデルの出力は摩擦トルクである。各学習モデルは、対応する各軌跡制御データを用いた教師あり学習によって学習される。 As described above, the motor control device according to the fifth embodiment has a learning unit 7e. The learning unit 7e divides the input trajectory control data into a plurality of groups. The learning unit 7e divides the trajectory control data by clustering based on the trajectory control data. The learning unit 7e divides the trajectory control data into a plurality of groups by k-means based on the motor speed value and acceleration value contained in the trajectory control data. The learning unit 7e learns each learning model corresponding to each group of trajectory control data. The input of the learning model is the motor speed and motor acceleration, and the output of the learning model is the friction torque. Each learning model is learned by supervised learning using the corresponding trajectory control data.

以下で、学習部7eが行う軌跡制御データを複数の組に分ける処理を説明する。学習部7eが軌跡制御データを8個の組に分ける例を想定し、用いられるk平均法の処理を説明する。 The process of dividing the trajectory control data into multiple sets performed by the learning unit 7e will be described below. Assuming an example in which the learning unit 7e divides the trajectory control data into eight sets, the k-means method process used will be described.

学習に用いられる軌跡制御データをn点としてそれらのうちのi番目のモータ速度の値及びi番目の加速度の値を含むデータは、まとめてxと表記される。iは、1からnまでの整数である。nは、1以上の整数である。学習部7eは、軌跡制御データを8個の組に分けるため、まずはn点のデータを無作為に8個の組に割り振る。 The trajectory control data used for learning is represented by n points, and data including the i-th motor speed value and the i-th acceleration value among them is collectively represented as x i , where i is an integer from 1 to n, and n is an integer equal to or greater than 1. To divide the trajectory control data into eight sets, the learning unit 7e first randomly allocates the n points of data to the eight sets.

次に、8個の組の各々において、学習部7eは、組の中心Mを計算する。jは、1から8までの整数である。学習部7eは、組の中心Mが当該組に含まれるデータの算術平均となるように計算する。 Next, for each of the eight pairs, the learning unit 7e calculates the center Mj of the pair, where j is an integer from 1 to 8. The learning unit 7e calculates the center Mj of the pair so that it is the arithmetic mean of the data included in the pair.

次に、学習部7eは、i番目のデータxと8個の組の中心Mの各々との距離を計算して、8個の距離のなかから距離が最も小さくなる組にi番目のデータを割り振る。学習部7eは、当該操作をn点の全てのデータに関して実施する。 Next, the learning unit 7e calculates the distance between the i-th data x i and each of the centers M j of the eight sets, and assigns the i-th data to the set with the smallest distance among the eight distances. The learning unit 7e performs this operation on all n data points.

これにより、各組に属するデータが入れ替わるために組の中心が移動する。そこで、学習部7eは、組の中心Mが当該組のデータの算術平均となるように再度計算する。 As a result, the data belonging to each group is replaced, and the center of the group moves. Therefore, the learning unit 7e performs calculations again so that the center Mj of the group becomes the arithmetic mean of the data of the group.

学習部7eは、各組の中心の計算と、各データと各組の中心との距離の計算と、各データの各組への割り振りとを、各データの割り振りが収束するまで、又はあらかじめ決められた回数の繰返しが完了するまで実行する。図11は、実施の形態5に係るクラスタリングによる軌跡制御データの複数の組への分割を示す図である。図11は、各データと各組の中心の対応を示している。 The learning unit 7e calculates the center of each group, calculates the distance between each data item and the center of each group, and allocates each data item to each group until the allocation of each data item converges or a predetermined number of repetitions are completed. FIG. 11 is a diagram showing the division of trajectory control data into a plurality of groups by clustering according to the fifth embodiment. FIG. 11 shows the correspondence between each data item and the center of each group.

以上の手順により、事前に閾値を決めることなく軌跡制御データに基づくクラスタリングによって8個の組が形成される。上述の説明ではクラスタリング手法としてk平均法を用いる例が示されたが、実施の形態5におけるクラスタリング手法はk平均法に限られず、例えば、単リンク法又は群平均法といった他のクラスタリング手法が用いられてもよい。 By the above procedure, eight groups are formed by clustering based on the trajectory control data without determining a threshold value in advance. In the above explanation, an example was given in which the k-means method was used as the clustering method, but the clustering method in embodiment 5 is not limited to the k-means method, and other clustering methods such as the single-link method or group average method may be used.

学習部7eによって軌跡制御データは第1組から第8組までの8個の組に分けられる。8個の組に分けられた軌跡制御データのi組目を第i組軌跡制御データと呼ぶことにする。第i組軌跡制御データに対応し、第i組軌跡制御データを用いて学習される学習モデルを第i学習モデルと呼ぶことにする。 The learning unit 7e divides the trajectory control data into eight groups, group 1 to group 8. The i-th group of the trajectory control data divided into the eight groups is referred to as the i-th group trajectory control data. The learning model that corresponds to the i-th group trajectory control data and is learned using the i-th group trajectory control data is referred to as the i-th learning model.

第i学習モデルの学習のためには、第i組目の軌跡制御データのみが使われる。そのため、全ての軌跡制御データを使う場合と比較すると学習に用いるデータセットの量は少量となる。 Only the i-th set of trajectory control data is used to train the i-th learning model. Therefore, the amount of data set used for training is smaller than when all trajectory control data is used.

学習部7eは、複数の学習モデルを用いて摩擦モデルを構築する。摩擦モデルの構築方法は、実施の形態1に記載されている方法と同じである。 The learning unit 7e constructs a friction model using multiple learning models. The method for constructing the friction model is the same as the method described in embodiment 1.

実施の形態5に係るモータ制御装置によれば、学習部7eで実行される軌跡制御データに基づくクラスタリングにより軌跡制御データが複数の組に分けられる。そのため、軌跡制御データを分けるための閾値を事前に設定する必要がない。学習モデルの入力である速度及び加速度の値の大きさが近いデータが同じ学習モデルの学習用データとして用いられるため、比較的少ない学習用データによる効率が良い高精度な学習が可能となる。高精度な複数の学習モデルを用いることで、高精度な摩擦モデルを構築することが可能になる。 According to the motor control device of embodiment 5, the trajectory control data is divided into multiple groups by clustering based on the trajectory control data executed by the learning unit 7e. Therefore, it is not necessary to set a threshold value for dividing the trajectory control data in advance. Data with similar magnitudes of the speed and acceleration values, which are inputs to the learning model, are used as learning data for the same learning model, making it possible to perform efficient, highly accurate learning using a relatively small amount of learning data. By using multiple highly accurate learning models, it becomes possible to construct a highly accurate friction model.

高精度な摩擦モデルを用いることで、軌跡制御を高精度化するための摩擦補償を実現することができる。 By using a highly accurate friction model, it is possible to achieve friction compensation to improve the accuracy of trajectory control.

実施の形態5によれば、少ない計算負荷で精度が高い摩擦補償を調整することできるモータ制御装置を提供することができる。 According to embodiment 5, it is possible to provide a motor control device that can adjust friction compensation with high accuracy and low computational load.

図12は、実施の形態1に係るモータ制御装置10が有するモデル速度算出部1、フィードバック制御部2、摩擦補償トルク算出部3、加算器4、電流制御部5、データ保持部6及び学習部7の少なくとも一部がプロセッサ91によって実現される場合のプロセッサ91を示す図である。つまり、モデル速度算出部1、フィードバック制御部2、摩擦補償トルク算出部3、加算器4、電流制御部5、データ保持部6及び学習部7の少なくとも一部の機能は、メモリ92に格納されるプログラムを実行するプロセッサ91によって実現されてもよい。プロセッサ91は、CPU(Central Processing Unit)、処理システム、演算システム、マイクロプロセッサ、又はDSP(Digital Signal Processor)である。図12には、メモリ92も示されている。 FIG. 12 is a diagram showing a processor 91 in the case where at least some of the model speed calculation unit 1, feedback control unit 2, friction compensation torque calculation unit 3, adder 4, current control unit 5, data retention unit 6, and learning unit 7 of the motor control device 10 according to the first embodiment are realized by the processor 91. In other words, at least some of the functions of the model speed calculation unit 1, feedback control unit 2, friction compensation torque calculation unit 3, adder 4, current control unit 5, data retention unit 6, and learning unit 7 may be realized by the processor 91 that executes a program stored in the memory 92. The processor 91 is a CPU (Central Processing Unit), a processing system, an arithmetic system, a microprocessor, or a DSP (Digital Signal Processor). The memory 92 is also shown in FIG. 12.

モデル速度算出部1、フィードバック制御部2、摩擦補償トルク算出部3、加算器4、電流制御部5、データ保持部6及び学習部7の少なくとも一部の機能がプロセッサ91によって実現される場合、当該一部の機能は、プロセッサ91と、ソフトウェア、ファームウェア、又は、ソフトウェアとファームウェアとの組み合わせとによって実現される。ソフトウェア又はファームウェアは、プログラムとして記述され、メモリ92に格納される。プロセッサ91は、メモリ92に記憶されたプログラムを読み出して実行することにより、モデル速度算出部1、フィードバック制御部2、摩擦補償トルク算出部3、加算器4、電流制御部5、データ保持部6及び学習部7の少なくとも一部の機能を実現する。 When at least some of the functions of the model speed calculation unit 1, feedback control unit 2, friction compensation torque calculation unit 3, adder 4, current control unit 5, data storage unit 6, and learning unit 7 are realized by the processor 91, the functions are realized by the processor 91 and software, firmware, or a combination of software and firmware. The software or firmware is written as a program and stored in the memory 92. The processor 91 realizes at least some of the functions of the model speed calculation unit 1, feedback control unit 2, friction compensation torque calculation unit 3, adder 4, current control unit 5, data storage unit 6, and learning unit 7 by reading and executing the program stored in the memory 92.

モデル速度算出部1、フィードバック制御部2、摩擦補償トルク算出部3、加算器4、電流制御部5、データ保持部6及び学習部7の少なくとも一部の機能がプロセッサ91によって実現される場合、モータ制御装置10は、モデル速度算出部1、フィードバック制御部2、摩擦補償トルク算出部3、加算器4、電流制御部5、データ保持部6及び学習部7によって実行されるステップの少なくとも一部が結果的に実行されることになるプログラムを格納するためのメモリ92を有する。メモリ92に格納されるプログラムは、モデル速度算出部1、フィードバック制御部2、摩擦補償トルク算出部3、加算器4、電流制御部5、データ保持部6及び学習部7が実行する手順又は方法の少なくとも一部をコンピュータに実行させるものであるともいえる。 When at least some of the functions of the model speed calculation unit 1, feedback control unit 2, friction compensation torque calculation unit 3, adder 4, current control unit 5, data storage unit 6, and learning unit 7 are realized by the processor 91, the motor control device 10 has a memory 92 for storing a program that results in at least some of the steps executed by the model speed calculation unit 1, feedback control unit 2, friction compensation torque calculation unit 3, adder 4, current control unit 5, data storage unit 6, and learning unit 7. It can also be said that the program stored in the memory 92 causes a computer to execute at least some of the procedures or methods executed by the model speed calculation unit 1, feedback control unit 2, friction compensation torque calculation unit 3, adder 4, current control unit 5, data storage unit 6, and learning unit 7.

メモリ92は、例えば、RAM(Random Access Memory)、ROM(Read Only Memory)、フラッシュメモリ、EPROM(Erasable Programmable Read Only Memory)、EEPROM(登録商標)(Electrically Erasable Programmable Read-Only Memory)等の不揮発性若しくは揮発性の半導体メモリ、磁気ディスク、フレキシブルディスク、光ディスク、コンパクトディスク、ミニディスク又はDVD(Digital Versatile Disk)等である。 The memory 92 may be, for example, a non-volatile or volatile semiconductor memory such as a RAM (Random Access Memory), a ROM (Read Only Memory), a flash memory, an EPROM (Erasable Programmable Read Only Memory), or an EEPROM (registered trademark) (Electrically Erasable Programmable Read-Only Memory), a magnetic disk, a flexible disk, an optical disk, a compact disk, a mini disk, or a DVD (Digital Versatile Disk).

図13は、実施の形態1に係るモータ制御装置10が有するモデル速度算出部1、フィードバック制御部2、摩擦補償トルク算出部3、加算器4、電流制御部5、データ保持部6及び学習部7の少なくとも一部が処理回路93によって実現される場合の処理回路93を示す図である。つまり、モデル速度算出部1、フィードバック制御部2、摩擦補償トルク算出部3、加算器4、電流制御部5、データ保持部6及び学習部7の少なくとも一部は、処理回路93によって実現されてもよい。 FIG. 13 is a diagram showing a processing circuit 93 in a case where at least a part of the model speed calculation unit 1, feedback control unit 2, friction compensation torque calculation unit 3, adder 4, current control unit 5, data holding unit 6, and learning unit 7 of the motor control device 10 according to embodiment 1 is realized by the processing circuit 93. In other words, at least a part of the model speed calculation unit 1, feedback control unit 2, friction compensation torque calculation unit 3, adder 4, current control unit 5, data holding unit 6, and learning unit 7 may be realized by the processing circuit 93.

処理回路93は、専用のハードウェアである。処理回路93は、例えば、単一回路、複合回路、プログラム化されたプロセッサ、並列プログラム化されたプロセッサ、ASIC(Application Specific Integrated Circuit)、FPGA(Field-Programmable Gate Array)、又はこれらを組み合わせたものである。 The processing circuitry 93 is dedicated hardware. For example, the processing circuitry 93 is a single circuit, a composite circuit, a programmed processor, a parallel programmed processor, an ASIC (Application Specific Integrated Circuit), an FPGA (Field-Programmable Gate Array), or a combination of these.

モデル速度算出部1、フィードバック制御部2、摩擦補償トルク算出部3、加算器4、電流制御部5、データ保持部6及び学習部7の一部は、残部とは別個の専用のハードウェアによって実現されてもよい。 The model speed calculation unit 1, feedback control unit 2, friction compensation torque calculation unit 3, adder 4, current control unit 5, data retention unit 6, and part of the learning unit 7 may be realized by dedicated hardware separate from the remaining units.

モデル速度算出部1、フィードバック制御部2、摩擦補償トルク算出部3、加算器4、電流制御部5、データ保持部6及び学習部7の複数の機能について、当該複数の機能の一部がソフトウェア又はファームウェアで実現され、当該複数の機能の残部が専用のハードウェアで実現されてもよい。このように、モデル速度算出部1、フィードバック制御部2、摩擦補償トルク算出部3、加算器4、電流制御部5、データ保持部6及び学習部7の複数の機能は、ハードウェア、ソフトウェア、ファームウェア、又はこれらの組み合わせによって実現することができる。 Regarding the multiple functions of the model speed calculation unit 1, feedback control unit 2, friction compensation torque calculation unit 3, adder 4, current control unit 5, data retention unit 6, and learning unit 7, some of the multiple functions may be realized by software or firmware, and the remaining multiple functions may be realized by dedicated hardware. In this way, the multiple functions of the model speed calculation unit 1, feedback control unit 2, friction compensation torque calculation unit 3, adder 4, current control unit 5, data retention unit 6, and learning unit 7 can be realized by hardware, software, firmware, or a combination of these.

実施の形態2から実施の形態5までの各摩擦補償トルク算出部3は、メモリに格納されるプログラムを実行するプロセッサによって実現されてもよい。当該メモリは、メモリ92と同様のメモリである。当該プロセッサは、プロセッサ91と同様のプロセッサである。実施の形態2から実施の形態5までの各摩擦補償トルク算出部3は、処理回路によって実現されてもよい。当該処理回路は、処理回路93と同様の処理回路である。 Each of the friction compensation torque calculation units 3 in the second to fifth embodiments may be realized by a processor that executes a program stored in a memory. The memory is a memory similar to the memory 92. The processor is a processor similar to the processor 91. Each of the friction compensation torque calculation units 3 in the second to fifth embodiments may be realized by a processing circuit. The processing circuit is a processing circuit similar to the processing circuit 93.

実施の形態2から実施の形態4までの各学習部7及び実施の形態5の学習部7eは、メモリに格納されるプログラムを実行するプロセッサによって実現されてもよい。当該メモリは、メモリ92と同様のメモリである。当該プロセッサは、プロセッサ91と同様のプロセッサである。実施の形態2から実施の形態4までの各学習部7及び実施の形態5の学習部7eは、処理回路によって実現されてもよい。当該処理回路は、処理回路93と同様の処理回路である。 Each of the learning units 7 in the second to fourth embodiments and the learning unit 7e in the fifth embodiment may be realized by a processor that executes a program stored in a memory. The memory is a memory similar to the memory 92. The processor is a processor similar to the processor 91. Each of the learning units 7 in the second to fourth embodiments and the learning unit 7e in the fifth embodiment may be realized by a processing circuit. The processing circuit is a processing circuit similar to the processing circuit 93.

以上の実施の形態に示した構成は、一例を示すものであり、別の公知の技術と組み合わせることも可能であるし、実施の形態同士を組み合わせることも可能であるし、要旨を逸脱しない範囲で、構成の一部を省略又は変更することも可能である。 The configurations shown in the above embodiments are merely examples, and may be combined with other known technologies, or the embodiments may be combined with each other. In addition, parts of the configurations may be omitted or modified without departing from the spirit of the invention.

1 モデル速度算出部、2 フィードバック制御部、3 摩擦補償トルク算出部、4 加算器、5 電流制御部、6 データ保持部、7,7e 学習部、10 モータ制御装置、20 モータ、21 位置検出器、30 対象機械、31 ボールねじ、32 テーブル、33 カップリング、91 プロセッサ、92 メモリ、93 処理回路。 1 Model speed calculation unit, 2 Feedback control unit, 3 Friction compensation torque calculation unit, 4 Adder, 5 Current control unit, 6 Data storage unit, 7, 7e Learning unit, 10 Motor control device, 20 Motor, 21 Position detector, 30 Target machine, 31 Ball screw, 32 Table, 33 Coupling, 91 Processor, 92 Memory, 93 Processing circuit.

Claims (6)

位置指令に基づいてモータを駆動し前記モータに機械的に接続された制御対象が移動する軌跡を制御する軌跡制御を実行するモータ制御装置であって、
前記位置指令及び前記モータの位置に基づいて前記モータのトルクの指令である第1トルク指令を算出するフィードバック制御を実行するフィードバック制御部と、
前記モータ又は前記制御対象の動作の状態に関するデータである軌跡制御データを保持するデータ保持部と、
前記軌跡制御データを、前記モータの速度と前記モータの加速度に基づいて分類される複数のデータセットに分割し前記複数のデータセットの各々について、前記軌跡制御データのうちの対応するデータセットのデータのみを用いて学習モデル成する学習部と、
摩擦を補償する前記モータのトルクである摩擦補償トルクを複数の前記学習モデルに基づいて算出する摩擦補償トルク算出部と、
前記第1トルク指令と前記摩擦補償トルクとを加算して第2トルク指令を算出する加算器と、
前記第2トルク指令に追従するように前記モータへの電流を制御して前記モータを駆動する電流制御部と
を備えることを特徴とするモータ制御装置。
A motor control device that performs trajectory control to drive a motor based on a position command and control a trajectory of a control target mechanically connected to the motor,
a feedback control unit that executes feedback control to calculate a first torque command, which is a command for a torque of the motor, based on the position command and a position of the motor;
a data storage unit that stores trajectory control data that is data related to an operation state of the motor or the controlled object;
a learning unit that divides the trajectory control data into a plurality of data sets classified based on a speed of the motor and an acceleration of the motor , and generates a learning model for each of the plurality of data sets using only data of a corresponding data set among the trajectory control data ;
a friction compensation torque calculation unit that calculates a friction compensation torque, which is a torque of the motor that compensates for friction, based on a plurality of the learning models;
an adder that calculates a second torque command by adding the first torque command and the friction compensation torque;
a current control unit that drives the motor by controlling a current to the motor so as to follow the second torque command.
前記学習部は、パラメータの個数が可変である学習モデルを学習する
ことを特徴とする請求項1に記載のモータ制御装置。
The motor control device according to claim 1 , wherein the learning unit learns a learning model in which the number of parameters is variable.
前記データ保持部は、前記摩擦補償トルクを用いた前記軌跡制御の実行中における前記モータ又は前記制御対象の動作の状態に関するデータである軌跡制御データを保持する
ことを特徴とする請求項1に記載のモータ制御装置。
The motor control device according to claim 1 , wherein the data storage unit stores trajectory control data that is data related to an operational state of the motor or the controlled object during execution of the trajectory control using the friction compensation torque.
前記学習部には、前記軌跡制御データを分割するための境界を規定するデータ境界が予め設定されており、前記学習部は、前記データ境界に基づいて前記軌跡制御データを分割する
ことを特徴とする請求項1に記載のモータ制御装置。
The motor control device according to claim 1 , wherein the learning unit is configured to have a data boundary that defines a boundary for dividing the trajectory control data, and the learning unit divides the trajectory control data based on the data boundary.
前記学習部は、前記軌跡制御データに基づくクラスタリングにより前記軌跡制御データを分割する
ことを特徴とする請求項1に記載のモータ制御装置。
The motor control device according to claim 1 , wherein the learning unit divides the trajectory control data by clustering based on the trajectory control data.
位置指令に基づいてモータを駆動し前記モータに機械的に接続された制御対象が移動する軌跡を制御する軌跡制御を実行するモータ制御方法であって、
前記位置指令と前記モータの位置とに基づくフィードバック制御によって前記モータのトルクの指令である第1トルク指令を算出するステップと、
前記軌跡制御の実行中における前記モータ又は前記制御対象の動作の状態に関するデータである軌跡制御データを保持するステップと、
前記軌跡制御データを、前記モータの速度と前記モータの加速度に基づいて分類される複数のデータセットに分割し前記複数のデータセットの各々について、前記軌跡制御データのうちの対応するデータセットのデータのみを用いて学習モデルを生成するステップと、
摩擦を補償する前記モータのトルクである摩擦補償トルクを複数の前記学習モデルに基づいて算出するステップと、
前記第1トルク指令と前記摩擦補償トルクとを加算して第2トルク指令を算出するステップと、
前記第2トルク指令に追従するように前記モータへの電流を制御して前記モータを駆動するステップと
を含むことを特徴とするモータ制御方法。
A motor control method for performing trajectory control in which a motor is driven based on a position command and a trajectory of a control target mechanically connected to the motor is controlled, the method comprising the steps of:
calculating a first torque command, which is a command for torque of the motor, by feedback control based on the position command and a position of the motor;
storing trajectory control data relating to a state of an operation of the motor or the controlled object during execution of the trajectory control;
Dividing the trajectory control data into a plurality of data sets classified based on a speed of the motor and an acceleration of the motor , and generating a learning model for each of the plurality of data sets using only data of a corresponding data set among the trajectory control data ;
calculating a friction compensation torque, which is a torque of the motor that compensates for friction, based on a plurality of the learning models;
calculating a second torque command by adding the first torque command and the friction compensation torque;
and controlling a current to the motor so as to follow the second torque command, thereby driving the motor.
JP2021161476A 2021-09-30 2021-09-30 Motor control device and motor control method Active JP7634458B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2021161476A JP7634458B2 (en) 2021-09-30 2021-09-30 Motor control device and motor control method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2021161476A JP7634458B2 (en) 2021-09-30 2021-09-30 Motor control device and motor control method

Publications (2)

Publication Number Publication Date
JP2023051040A JP2023051040A (en) 2023-04-11
JP7634458B2 true JP7634458B2 (en) 2025-02-21

Family

ID=85805521

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2021161476A Active JP7634458B2 (en) 2021-09-30 2021-09-30 Motor control device and motor control method

Country Status (1)

Country Link
JP (1) JP7634458B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2025142126A1 (en) * 2023-12-28 2025-07-03 パナソニックIpマネジメント株式会社 Control system, control method, and program
WO2026083669A1 (en) * 2024-10-15 2026-04-23 パナソニックIpマネジメント株式会社 Control device, model generation system, control method, model generation method, and program

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014122822A1 (en) 2013-02-07 2014-08-14 三菱電機株式会社 Servo control device
JP2017127176A (en) 2016-01-08 2017-07-20 株式会社ジェイテクト Motor controller
JP2019185742A (en) 2018-04-17 2019-10-24 ファナック株式会社 Controller and control method
JP2020087343A (en) 2018-11-30 2020-06-04 ブラザー工業株式会社 Control system, update method, estimation method, and computer program

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0754317B1 (en) * 1994-04-08 1998-09-23 Siemens Aktiengesellschaft Device designed to compensate for non-linearity of machine shafts

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014122822A1 (en) 2013-02-07 2014-08-14 三菱電機株式会社 Servo control device
JP2017127176A (en) 2016-01-08 2017-07-20 株式会社ジェイテクト Motor controller
JP2019185742A (en) 2018-04-17 2019-10-24 ファナック株式会社 Controller and control method
JP2020087343A (en) 2018-11-30 2020-06-04 ブラザー工業株式会社 Control system, update method, estimation method, and computer program

Also Published As

Publication number Publication date
JP2023051040A (en) 2023-04-11

Similar Documents

Publication Publication Date Title
Tian et al. Adaptive neuro-fuzzy control of a flexible manipulator
EP3424650B1 (en) A method and apparatus for performing control of a movement of a robot arm
CN113748597B (en) Motor control device
JP7634458B2 (en) Motor control device and motor control method
CN111890351A (en) Robot, method of controlling the same, and computer-readable storage medium
CN115741692B (en) Hydraulic mechanical arm high-precision control method and system based on data driving
CN115488881B (en) Man-machine sharing autonomous teleoperation method and system based on multiple movement skills prior
JP6949284B1 (en) Numerical control device
CN118081773A (en) A robot control method based on actor-critic algorithm with comprehensive loss
WO2025004241A1 (en) Parameter adjustment device and parameter adjustment method
Zhang et al. A sample construction method in kinematics characteristics domain to identify the feed drive model
Licher et al. Adaptive model-predictive control of a soft continuum robot using a physics-informed neural network based on cosserat rod theory
Moran-Armenta et al. Solving trajectory tracking of robot manipulators via PID control with neural network compensation: M. Moran-Armenta et al.
Brown et al. Design of a neural controller using reinforcement learning to control a rotational inverted pendulum
JP7505695B2 (en) Motor Control Device
CN114800525A (en) Robot collision detection method, system, computer and readable storage medium
CN119927934A (en) Adaptive compensation and dynamic balance control method for joint torque of surgical robot arm
JP2022088174A (en) Reliability assessment device
Ting et al. Locally Weighted Regression for Control.
JP7575007B2 (en) Hand load estimation device, robot control system, and robot system
Scholl et al. Interpretable Robotic Friction Learning via Symbolic Regression
CN119567248B (en) Pipeline pneumatic soft robot control method and system based on deep reinforcement learning
CN120029037B (en) Online calibration device and method for control parameters of engine control system
Mohammad et al. Learning from demonstration
Szuster et al. Control of mechatronic systems

Legal Events

Date Code Title Description
A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A821

Effective date: 20211004

A711 Notification of change in applicant

Free format text: JAPANESE INTERMEDIATE CODE: A711

Effective date: 20240523

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20240527

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A821

Effective date: 20240523

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20241030

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20241105

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20241225

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: 20250114

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20250210

R150 Certificate of patent or registration of utility model

Ref document number: 7634458

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150