[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

CN108803335B - Method for eliminating control disorder of direct current servo motor - Google Patents

Method for eliminating control disorder of direct current servo motor Download PDF

Info

Publication number
CN108803335B
CN108803335B CN201810657507.2A CN201810657507A CN108803335B CN 108803335 B CN108803335 B CN 108803335B CN 201810657507 A CN201810657507 A CN 201810657507A CN 108803335 B CN108803335 B CN 108803335B
Authority
CN
China
Prior art keywords
output
input
layer
hidden layer
matrix
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
CN201810657507.2A
Other languages
Chinese (zh)
Other versions
CN108803335A (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.)
Nanjing University of Posts and Telecommunications
Original Assignee
Nanjing University of Posts and Telecommunications
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 Nanjing University of Posts and Telecommunications filed Critical Nanjing University of Posts and Telecommunications
Priority to CN201810657507.2A priority Critical patent/CN108803335B/en
Publication of CN108803335A publication Critical patent/CN108803335A/en
Application granted granted Critical
Publication of CN108803335B publication Critical patent/CN108803335B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B13/00Adaptive control systems, i.e. systems automatically adjusting themselves to have a performance which is optimum according to some preassigned criterion
    • G05B13/02Adaptive control systems, i.e. systems automatically adjusting themselves to have a performance which is optimum according to some preassigned criterion electric
    • G05B13/04Adaptive control systems, i.e. systems automatically adjusting themselves to have a performance which is optimum according to some preassigned criterion electric involving the use of models or simulators
    • G05B13/042Adaptive control systems, i.e. systems automatically adjusting themselves to have a performance which is optimum according to some preassigned criterion electric involving the use of models or simulators in which a parameter or coefficient is automatically adjusted to optimise the performance

Landscapes

  • Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Evolutionary Computation (AREA)
  • Medical Informatics (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Automation & Control Theory (AREA)
  • Control Of Electric Motors In General (AREA)
  • Feedback Control In General (AREA)

Abstract

The invention discloses a disorder eliminating method in control of a direct current servo motor, which is characterized in that a timestamp generator, a logic comparator and a prediction controller are added on the basis of a traditional network control system, the timestamp generator adds a timestamp to a data packet, the logic comparator is utilized at the two ends of a controller and an actuator to select the latest control signal for controlling the direct current servo motor, meanwhile, the concept of the prediction controller is provided, the real-time control performance of the system is further improved by utilizing a prediction algorithm when the system is out of order, and the waste of system resources is avoided.

Description

一种直流伺服电机控制乱序消除方法A method for eliminating out-of-order control of DC servo motor

技术领域technical field

本发明涉及直流伺服电机的网络控制,提出一种解决由于网络传输所带来的乱序问题的方法,并具体阐述了相关的数据包重排方法。The invention relates to network control of a DC servo motor, proposes a method for solving the disorder problem caused by network transmission, and specifically describes a related data packet rearrangement method.

背景技术Background technique

网络控制系统(NCS)是指通过网络将被控对象、传感器、控制器以及执行器连接起来的反馈控制系统,便于远程操作和控制。但网络的引入也给电机的控制带来了一系列问题,其中数据包的乱序很大程度上影响了电机的运行性能。Network Control System (NCS) refers to a feedback control system that connects the controlled object, sensors, controllers and actuators through a network, which is convenient for remote operation and control. But the introduction of the network also brings a series of problems to the control of the motor, among which the disorder of the data packets greatly affects the running performance of the motor.

对于直流伺服电机的网络控制,李若琼等人在2014年对系统中存在的时延的情形进行了分析;许培等人在2013年研究了丢包对系统控制性能的影响。但是以上研究都没有考虑数据包乱序的影响,很难满足工程的实际需求。For the network control of DC servo motors, Li Ruoqiong et al. analyzed the time delay in the system in 2014; Xu Pei et al. studied the impact of packet loss on system control performance in 2013. However, the above studies have not considered the impact of out-of-order data packets, and it is difficult to meet the actual needs of the project.

发明内容SUMMARY OF THE INVENTION

为了弥补现有研究的不足,本发明提出一种改进的数据包重排方法来解决电机控制中的乱序问题,以改善电机的控制性能。In order to make up for the insufficiency of the existing research, the present invention proposes an improved data packet rearrangement method to solve the disorder problem in motor control, so as to improve the control performance of the motor.

本发明技术方案如下:The technical scheme of the present invention is as follows:

一种直流伺服电机控制乱序消除方法,在网络控制系统上加入时间戳生成器、逻辑比较器和预测控制器,实现对乱序数据包重新排序;具体包括以下步骤:A method for eliminating out-of-order control of a DC servo motor. A time stamp generator, a logic comparator and a prediction controller are added to a network control system to realize the reordering of out-of-order data packets; the method specifically includes the following steps:

步骤S1,时间戳生成器设置在传感器端用来对传感器采集到的数据进行标记,以方便后续进行乱序判断;Step S1, the time stamp generator is set at the sensor end to mark the data collected by the sensor, so as to facilitate subsequent out-of-order judgment;

步骤S2,在控制器和执行器两端分别设置逻辑比较器;两个逻辑比较器分别对控制器和执行器接收到的数据的时间戳进行比较,将新到达的数据的时间戳与存储在寄存器中的数据的时间戳进行比较,判断是否发生乱序;若新到达的数据包的时间戳新于原来的数据包的时间戳,则没有发生乱序,否则发生乱序;如果判断结果没有发生乱序则更新寄存器中的数据,否则寄存器中的数据保持不变;当寄存器更新后,则控制器把控制信号发送给执行器,执行器将控制信号应用到直流伺服电机的控制;In step S2, logical comparators are respectively set at both ends of the controller and the executor; the two logical comparators respectively compare the timestamps of the data received by the controller and the executor, and compare the timestamps of the newly arrived data with those stored in the executor. Compare the timestamps of the data in the register to determine whether out of order occurs; if the timestamp of the newly arrived packet is newer than the timestamp of the original packet, no disorder occurs, otherwise disorder occurs; if the judgment result is no If the order is out of order, the data in the register will be updated, otherwise the data in the register will remain unchanged; when the register is updated, the controller will send the control signal to the actuator, and the actuator will apply the control signal to the control of the DC servo motor;

步骤S3,预测控制器设置在控制器端,预测控制器的通过预测算法获取预测输出信号u并发送到控制器端,生成控制信号供执行器使用,保证整个系统的连续性;预测输出信号u为状态方程描述的电机系统模型的输入,对系统进行滚动优化。Step S3, the prediction controller is set at the controller end, the prediction controller obtains the prediction output signal u through the prediction algorithm and sends it to the controller end, generates a control signal for the actuator to use, and ensures the continuity of the whole system; the prediction output signal u Rolling optimization of the system is performed as input to the motor system model described by the equation of state.

预测算法为基于极限学习机(ELM)的预测算法,具体包括以下步骤:The prediction algorithm is a prediction algorithm based on extreme learning machine (ELM), which specifically includes the following steps:

(1)、采用单隐含层前馈神经网络结构,确定隐含层的神经元个数,随机设置并固定输入层与隐含层间的连接权值w与隐含层神经元阈值b;(1) Using a single hidden layer feedforward neural network structure, the number of neurons in the hidden layer is determined, and the connection weight w and the hidden layer neuron threshold b between the input layer and the hidden layer are randomly set and fixed;

输入层与隐含层、隐含层与输出层神经元间全连接,输入层有n个神经元,对应n个输入量;隐含层有为单层,共有l个神经元;输出层有m个神经元,对应m个输出量;输入层与隐含层之间的连接权值w为:The input layer and the hidden layer, the hidden layer and the output layer are fully connected. The input layer has n neurons, corresponding to n inputs; the hidden layer is a single layer, with a total of l neurons; the output layer has m neurons, corresponding to m outputs; the connection weight w between the input layer and the hidden layer is:

Figure BDA0001705909400000021
Figure BDA0001705909400000021

式(1)中,wij表示第i个输入层神经元与第j个隐含层神经元之间的连接权值,l表示隐含层的神经元个数;n表示输入层神经元个数;In formula (1), w ij represents the connection weight between the i-th input layer neuron and the j-th hidden layer neuron, l represents the number of neurons in the hidden layer; n represents the number of input layer neurons number;

隐含层与输出层之间的连接权值β为:The connection weight β between the hidden layer and the output layer is:

Figure BDA0001705909400000031
Figure BDA0001705909400000031

其中βjk表示隐含层第j个神经元与输出层第k个神经元之间的连接权值;l表示隐含层的神经元个数;m表示输出层神经元个数;where β jk represents the connection weight between the jth neuron in the hidden layer and the kth neuron in the output layer; l represents the number of neurons in the hidden layer; m represents the number of neurons in the output layer;

隐含层神经元的阈值b为:The threshold b of the hidden layer neurons is:

Figure BDA0001705909400000032
Figure BDA0001705909400000032

其中bi表示第i个隐含层神经元的阈值;where b i represents the threshold of the ith hidden layer neuron;

(2)、确定隐含层神经元的激活函数g(x),计算隐含层输出矩阵H;(2), determine the activation function g(x) of the neurons in the hidden layer, and calculate the output matrix H of the hidden layer;

(3)、计算输出层权值

Figure BDA0001705909400000033
;T′为矩阵T的转置;H是神经网络的隐含层输出矩阵;(3) Calculate the weights of the output layer
Figure BDA0001705909400000033
; T′ is the transpose of the matrix T; H is the output matrix of the hidden layer of the neural network;

(4)、对已知的控制信号(预测输出信号u)进行分组处理,归一化作为神经网络的输入矩阵;(4), perform group processing on the known control signal (predicted output signal u), and normalize it as the input matrix of the neural network;

(5)、预测下一步的控制信号;(5), predict the next control signal;

(6)、将预测结果作为系统模型的输入。(6), take the prediction result as the input of the system model.

以状态方程描述的电机系统模型:The motor system model described by the equation of state:

Figure BDA0001705909400000034
Figure BDA0001705909400000034

式中x(k)∈Rn是状态变量,u(k)和y(k)分别为系统输入和输出,矩阵A、B和cT是是维数为n×n的常矩阵;从k时刻起系统的输入发生了M步变化(M=0,1,2…),计算在预测输入u(k)、u(k+1)…u(k+i)…u(k+M-1)作用下未来P个时刻的系统状态,u(k+i)由ELM算法预测得到;where x(k) ∈Rn is the state variable, u(k) and y(k) are the system input and output respectively, and the matrices A, B and cT are constant matrices with dimension n×n; Since the input of the system has changed M steps (M=0, 1, 2...), the calculation is performed in the predicted input u(k), u(k+1)...u(k+i)...u(k+M- 1) Under the action of the system state at P moments in the future, u(k+i) is predicted by the ELM algorithm;

系统状态预测表示为:The system state prediction is expressed as:

X(k)=Fxx(k)+GxU(k) (15)X(k)=F x x(k)+G x U(k) (15)

其中,in,

Figure BDA0001705909400000041
Figure BDA0001705909400000041

Figure BDA0001705909400000042
Figure BDA0001705909400000042

Figure BDA0001705909400000043
Figure BDA0001705909400000043

Figure BDA0001705909400000044
Figure BDA0001705909400000044

其中Fx和Gx分别是x(k)和u(k)的系数矩阵,由A和B组成;P表示对未来P个采样时刻做P次预测;where F x and G x are the coefficient matrices of x(k) and u(k), respectively, composed of A and B; P means to make P predictions for P sampling moments in the future;

式(15)预测得到了系统未来时刻的系统状态,通过输出和状态的关系式y(k)=cTx(k)来预测出系统的输出,并将输出发送到控制器端,进行系统的滚动优化。Equation (15) predicts the system state at the future time of the system, and predicts the output of the system through the relationship between output and state y(k)=c T x(k), and sends the output to the controller to carry out the system. scrolling optimization.

系统的滚动优化具体包括以下步骤:The rolling optimization of the system includes the following steps:

在k时刻的状态优化问题表述为确定从k时刻起的M个控制量u(k),u(k+1,…,u(k+M-1),使被控对象在M个控制量作用下未来P个时刻的状态得到镇定,趋近于x=0,优化性能指标表达为向量形式:The state optimization problem at time k is expressed as determining M control variables u(k), u(k+1,..., u(k+M-1) from time k, so that the controlled object is in the M control variables Under the action, the state of the next P moments is stabilized, approaching x=0, and the optimized performance index is expressed in the form of a vector:

Figure BDA0001705909400000051
Figure BDA0001705909400000051

其中,Qx,Rx是状态加权矩阵和控制加权矩阵;在不考虑约束时,结合状态预测模型求出最优解的解析表达式:J(k)表k时刻的性能指标;Among them, Q x , R x are the state weighting matrix and the control weighting matrix; when the constraints are not considered, the analytical expression of the optimal solution is obtained in combination with the state prediction model: J(k) represents the performance index at time k;

Figure BDA0001705909400000052
Figure BDA0001705909400000052

由此求出即时控制量:From this, the immediate control quantity is obtained:

Figure BDA0001705909400000053
Figure BDA0001705909400000053

其中反馈增益

Figure BDA0001705909400000057
where feedback gain
Figure BDA0001705909400000057

Figure BDA0001705909400000054
Figure BDA0001705909400000054

Figure BDA0001705909400000055
是u(k)的系数矩阵Gx的转置。
Figure BDA0001705909400000055
is the transpose of the coefficient matrix G x of u(k).

较优地,步骤(2)具体包括以下步骤Preferably, step (2) specifically includes the following steps

具有Q个训练样本的训练集输入矩阵X和输出矩阵Y分别为:The training set input matrix X and output matrix Y with Q training samples are:

Figure BDA0001705909400000056
Figure BDA0001705909400000056

Figure BDA0001705909400000061
Figure BDA0001705909400000061

xij表示第i个输入层第j个样本的输入值,yij表示第i个输出层第j个样本的输出值;x ij represents the input value of the j-th sample of the ith input layer, and y ij represents the output value of the j-th sample of the ith output layer;

隐含层神经元的激活函数为g(x),将训练样本进行归一化处理后作为神经网络的输入,同时预测输出信号作为系统模型的输入:The activation function of the neurons in the hidden layer is g(x), the training samples are normalized as the input of the neural network, and the predicted output signal is used as the input of the system model:

u=[u1 u2…ui…uQ]n×Q(6)u=[u 1 u 2 ... u i ... u Q ] n×Q (6)

其中,in,

Figure BDA0001705909400000062
Figure BDA0001705909400000062

式(7)中,ui表示第i个输入层样本,uij表示第i个输入层第j个输入样本的输入;In formula (7), ui represents the ith input layer sample, and u ij represents the input of the jth input sample of the ith input layer;

通过ELM结构图得神经网络的输出T为:The output T of the neural network obtained through the ELM structure diagram is:

T=[t1 t2…tj…tQ]m×Q (8)T=[t 1 t 2 …t j …t Q ] m×Q (8)

Figure BDA0001705909400000063
Figure BDA0001705909400000063

其中,wi=[wi1,wi2,…win];xj=[u1j,u2j,…,unj]TWherein, w i =[w i1 , w i2 ,...w in ]; x j =[u 1j , u 2j ,..., u nj ] T ;

tj表示第j个样本的输出,tmj表示第m个输出层第j个样本的输出; tj represents the output of the jth sample, and tmj represents the output of the jth sample of the mth output layer;

式(9)表示为:Formula (9) is expressed as:

Hβ=T′(10)Hβ=T′(10)

其中,T′为矩阵T的转置;H是神经网络的隐含层输出矩阵;Among them, T' is the transpose of the matrix T; H is the output matrix of the hidden layer of the neural network;

Figure BDA0001705909400000071
Figure BDA0001705909400000071

较优地,步骤(3)计算输出层权值

Figure BDA0001705909400000072
具体包括以下步骤:Preferably, step (3) calculates the weights of the output layer
Figure BDA0001705909400000072
Specifically include the following steps:

固定随机选择的输入权值w和隐含层的阈值b,则训练网络等同于求线性系统Hβ=T′的最小二乘解β,Fixing the randomly selected input weight w and the hidden layer threshold b, then training the network is equivalent to finding the least squares solution β of the linear system Hβ=T′,

Figure BDA0001705909400000073
Figure BDA0001705909400000073

解为:The solution is:

Figure BDA0001705909400000074
Figure BDA0001705909400000074

其中,H+为隐含层输出矩阵H的Moor-Penrose广义逆。where H + is the Moor-Penrose generalized inverse of the hidden layer output matrix H.

本发明的有益效果包括:The beneficial effects of the present invention include:

本发明公开一种直流伺服电机控制乱序消除方法,解决电机控制过程中的乱序问题,加入了一个基于极限学习机的预测控制器对系统输入进行预测,利用预测所得结果保证系统的运行,以解决因为数据包乱序而导致的系统空闲等待问题,学习速度快、泛化性能好。The invention discloses a method for eliminating out-of-order control of a DC servo motor, which solves the out-of-order problem in the motor control process. In order to solve the problem of system idle waiting caused by out-of-order data packets, the learning speed is fast and the generalization performance is good.

附图说明Description of drawings

下面结合附图和实施例对本发明进一步说明;The present invention will be further described below in conjunction with the accompanying drawings and embodiments;

图1为直流伺服电机控制中乱序消除系统结构图;Fig. 1 is the structure diagram of the out-of-order elimination system in the control of the DC servo motor;

图2为ELM单隐含层前馈神经网络结构图。Figure 2 shows the structure of the ELM single hidden layer feedforward neural network.

具体实施方式Detailed ways

下面结合附图并通过具体实施例对本发明作进一步详述,以下实施例只是描述性的,不是限定性的,不能以此限定本发明的保护范围。The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. The following embodiments are only descriptive, not restrictive, and cannot limit the protection scope of the present invention.

为了使本发明的技术手段、创作特征、工作流程、使用方法达成目的与功效,且为了使该评价方法易于明白了解,下面结合具体实施例,进一步阐述本发明。In order to achieve the purpose and effect of the technical means, creation features, work flow, and use method of the present invention, and in order to make the evaluation method easy to understand, the present invention is further described below in conjunction with specific embodiments.

如图1所示,一种直流伺服电机控制乱序消除方法,在网络控制系统的基础上加入时间戳生成器、逻辑比较器和预测控制器,实现对乱序数据包重新排序,解决乱序带来的不利影响,改善电机的控制性能;具体包括以下步骤:As shown in Figure 1, a method for eliminating out-of-order control of DC servo motor, adding timestamp generator, logic comparator and predictive controller on the basis of network control system to realize reordering of out-of-order data packets and solve out-of-order data packets To improve the control performance of the motor, it includes the following steps:

步骤S1,时间戳生成器设置在传感器端用来对传感器采集到的数据进行标记,以方便后续进行乱序判断;Step S1, the time stamp generator is set at the sensor end to mark the data collected by the sensor, so as to facilitate subsequent out-of-order judgment;

步骤S2,在控制器和执行器两端分别设置逻辑比较器;两个逻辑比较器分别对控制器和执行器接收到的数据的时间戳进行比较,将新到达的数据的时间戳与存储在寄存器中的数据的时间戳进行比较,判断是否发生乱序;若新到达的数据包的时间戳新于原来的数据包的时间戳,则没有发生乱序,否则发生乱序;如果判断结果没有发生乱序则更新寄存器中的数据,否则寄存器中的数据保持不变;当寄存器更新后,则控制器把控制信号发送给执行器,执行器将控制信号应用到直流伺服电机的控制;In step S2, logical comparators are respectively set at both ends of the controller and the executor; the two logical comparators respectively compare the timestamps of the data received by the controller and the executor, and compare the timestamps of the newly arrived data with those stored in the executor. Compare the timestamps of the data in the register to determine whether out of order occurs; if the timestamp of the newly arrived packet is newer than the timestamp of the original packet, no disorder occurs, otherwise disorder occurs; if the judgment result is no If the order is out of order, the data in the register will be updated, otherwise the data in the register will remain unchanged; when the register is updated, the controller will send the control signal to the actuator, and the actuator will apply the control signal to the control of the DC servo motor;

步骤S3,预测控制器设置在控制器端,预测控制器的通过预测算法获取预测输出信号u并发送到控制器端,生成控制信号供执行器使用,保证整个系统的连续性;预测输出信号u为状态方程描述的电机系统模型的输入,对系统进行滚动优化。Step S3, the prediction controller is set at the controller end, the prediction controller obtains the prediction output signal u through the prediction algorithm and sends it to the controller end, generates a control signal for the actuator to use, and ensures the continuity of the whole system; the prediction output signal u Rolling optimization of the system is performed as input to the motor system model described by the equation of state.

预测算法为基于极限学习机(ELM)的预测算法,具体包括以下步骤:The prediction algorithm is a prediction algorithm based on extreme learning machine (ELM), which specifically includes the following steps:

(1)、采用单隐含层前馈神经网络结构(如图2所示),确定隐含层的神经元个数,随机设置并固定输入层与隐含层间的连接权值w与隐含层神经元阈值b;(1) Using a single hidden layer feedforward neural network structure (as shown in Figure 2), determine the number of neurons in the hidden layer, randomly set and fix the connection weight w between the input layer and the hidden layer and the hidden layer containing layer neuron threshold b;

输入层与隐含层、隐含层与输出层神经元间全连接,输入层有n个神经元,对应n个输入量;隐含层有为单层,共有l个神经元;输出层有m个神经元,对应m个输出量;输入层与隐含层之间的连接权值w为:The input layer and the hidden layer, the hidden layer and the output layer are fully connected. The input layer has n neurons, corresponding to n inputs; the hidden layer is a single layer, with a total of l neurons; the output layer has m neurons, corresponding to m outputs; the connection weight w between the input layer and the hidden layer is:

Figure BDA0001705909400000091
Figure BDA0001705909400000091

式(1)中,wij表示第i个输入层神经元与第j个隐含层神经元之间的连接权值;In formula (1), w ij represents the connection weight between the i-th input layer neuron and the j-th hidden layer neuron;

隐含层与输出层之间的连接权值β为:The connection weight β between the hidden layer and the output layer is:

Figure BDA0001705909400000101
Figure BDA0001705909400000101

其中βjk表示隐含层第j个神经元与输出层第k个神经元之间的连接权值;l表示隐含层的神经元个数;where β jk represents the connection weight between the jth neuron in the hidden layer and the kth neuron in the output layer; l represents the number of neurons in the hidden layer;

隐含层神经元的阈值b为:The threshold b of the hidden layer neurons is:

Figure BDA0001705909400000102
Figure BDA0001705909400000102

其中bi表示第i个隐含层神经元的阈值;where b i represents the threshold of the ith hidden layer neuron;

(2)、确定隐含层神经元的激活函数g(x),计算输出矩阵H;(2), determine the activation function g(x) of the neurons in the hidden layer, and calculate the output matrix H;

具有Q个训练样本的训练集输入矩阵X和输出矩阵Y分别为:The training set input matrix X and output matrix Y with Q training samples are:

Figure BDA0001705909400000103
Figure BDA0001705909400000103

Figure BDA0001705909400000104
Figure BDA0001705909400000104

xij表示第i个输入层第j个样本的输入值,yij表示第i个输出层第j个样本的输出值;x ij represents the input value of the j-th sample of the ith input layer, and y ij represents the output value of the j-th sample of the ith output layer;

隐含层神经元的激活函数为g(x),将训练样本进行归一化处理后作为神经网络的输入,同时预测输出信号作为系统模型的输入:The activation function of the neurons in the hidden layer is g(x), the training samples are normalized as the input of the neural network, and the predicted output signal is used as the input of the system model:

u=[u1 u2…ui…uQ]n×Q (6)u=[u 1 u 2 ... u i ... u Q ] n×Q (6)

其中,in,

Figure BDA0001705909400000111
Figure BDA0001705909400000111

式(7)中,ui表示第i个输入层样本,uij表示第i个输入层第j个输入样本的输入;In formula (7), ui represents the ith input layer sample, and u ij represents the input of the jth input sample of the ith input layer;

如图2所示,通过ELM结构图得神经网络的输出T为:As shown in Figure 2, the output T of the neural network obtained through the ELM structure diagram is:

T=[t1 t2…tj…tQ]m×Q (8)T=[t 1 t 2 …t j …t Q ] m×Q (8)

Figure BDA0001705909400000112
Figure BDA0001705909400000112

其中,wi=[wi1,wi2,…,win];xj=[u1j,u2j,…,unj]TWherein, w i =[w i1 , w i2 ,...,w in ]; x j =[u 1j , u 2j ,..., u nj ] T ;

tj表示第j个样本的输出,tmj表示第m个输出层第j个样本的输出; tj represents the output of the jth sample, and tmj represents the output of the jth sample of the mth output layer;

式(9)表示为:Formula (9) is expressed as:

Hβ=T′ (10)Hβ=T′ (10)

其中,T′为矩阵T的转置(TT);H是神经网络的隐含层输出矩阵;Among them, T' is the transpose (T T ) of the matrix T; H is the output matrix of the hidden layer of the neural network;

Figure BDA0001705909400000121
Figure BDA0001705909400000121

(3)、计算输出层权值

Figure BDA0001705909400000122
(3) Calculate the weights of the output layer
Figure BDA0001705909400000122

固定随机选择的输入权值w和隐含层的阈值b,则训练网络等同于求线性系统Hβ=T′的最小二乘解β,Fixing the randomly selected input weight w and the hidden layer threshold b, then training the network is equivalent to finding the least squares solution β of the linear system Hβ=T′,

Figure BDA0001705909400000123
Figure BDA0001705909400000123

解为:The solution is:

Figure BDA0001705909400000124
Figure BDA0001705909400000124

其中,H+为隐含层输出矩阵H的Moor-Penrose广义逆;Among them, H + is the Moor-Penrose generalized inverse of the hidden layer output matrix H;

(4)、对已知的控制信号(预测输出信号u)进行分组处理,归一化作为神(4) Group the known control signal (predicted output signal u), and normalize it as a

经网络的输入矩阵;The input matrix through the network;

(5)、预测下一步的控制信号;(5), predict the next control signal;

(6)、将预测结果作为系统模型的输入。(6), take the prediction result as the input of the system model.

以状态方程描述的电机系统模型:The motor system model described by the equation of state:

Figure BDA0001705909400000125
Figure BDA0001705909400000125

式中x(k)∈Rn是状态变量且实时可测,u(k)和y(k)分别为系统输入和输出,矩阵A、B和cT是维数为n×n的常矩阵;从k时刻起系统的输入发生了M步变化(M=0,1,2…),预测在作用下未来u(k)、u(k+1)…u(k+i)…u(k+M-1)个时刻的系统状态,u(k+i)由ELM算法预测得到;系统状态预测表示为:where x(k) ∈Rn is a state variable and can be measured in real time, u(k) and y(k) are the system input and output, respectively, and matrices A, B and c T are constant matrices with dimensions n×n ; The input of the system has changed M steps since time k (M=0, 1, 2...), and the prediction is under the action of future u(k), u(k+1)...u(k+i)...u( The system state at k+M-1) moments, u(k+i) is predicted by the ELM algorithm; the system state prediction is expressed as:

X(K)=Fxx(κ)+GxU(κ) (15)X(K)=F x x(κ)+G x U(κ) (15)

其中,in,

Figure BDA0001705909400000131
Figure BDA0001705909400000131

Figure BDA0001705909400000132
Figure BDA0001705909400000132

Figure BDA0001705909400000133
Figure BDA0001705909400000133

Figure BDA0001705909400000134
Figure BDA0001705909400000134

其中Fx和Gx分别是x(k)和u(k)的系数矩阵,由A和B组成;P表示未来P个时刻的系统状态,即对未来P个采样周期的时刻点做P次预测;Among them, F x and G x are the coefficient matrices of x(k) and u(k) respectively, which are composed of A and B; P represents the system state at P times in the future, that is, the time points of the next P sampling periods are performed P times predict;

式(15)预测得到了系统未来时刻的系统状态,通过输出和状态的关系式y(k)=cTx(k)来预测出系统的输出,并将输出发送到控制器端,进行系统的滚动优化。Equation (15) predicts the system state at the future time of the system, and predicts the output of the system through the relationship between output and state y(k)=c T x(k), and sends the output to the controller to carry out the system. scrolling optimization.

系统的滚动优化具体包括以下步骤:The rolling optimization of the system includes the following steps:

在k时刻的状态优化问题表述为确定从k时刻起的M个控制量u(k),u(k+1),…,u(k+M-1),使被控对象在M个控制量作用下未来P个时刻的状态得到镇定,趋近于x=0,优化性能指标表达为向量形式:The state optimization problem at time k is expressed as determining M control quantities u(k), u(k+1), ..., u(k+M-1) from time k, so that the controlled object is controlled in M Under the action of the quantity, the state of P moments in the future is stabilized, approaching x=0, and the optimized performance index is expressed in the form of a vector:

Figure BDA0001705909400000141
Figure BDA0001705909400000141

其中,Qx,Rx是状态加权矩阵和控制加权矩阵;在不考虑约束时,结合状态预测模型求出最优解的解析表达式:J(k)表示k时刻的性能指标Among them, Q x , R x are the state weighting matrix and the control weighting matrix; when the constraints are not considered, the analytical expression of the optimal solution is obtained by combining the state prediction model: J(k) represents the performance index at time k

Figure BDA0001705909400000142
Figure BDA0001705909400000142

Figure BDA0001705909400000143
是u(k)的系数矩阵Gx的转置;
Figure BDA0001705909400000143
is the transpose of the coefficient matrix G x of u(k);

由此求出即时控制量:From this, the immediate control quantity is obtained:

Figure BDA0001705909400000144
Figure BDA0001705909400000144

其中反馈增益

Figure BDA0001705909400000145
where feedback gain
Figure BDA0001705909400000145

Figure BDA0001705909400000146
Figure BDA0001705909400000146

本领域内的技术人员可以对本发明进行改动或变型的设计但不脱离本发明的思想和范围。因此,如果本发明的这些修改和变型属于本发明权利要求及其等同的技术范围之内,则本发明也意图包含这些改动和变型在内。Those skilled in the art can make changes or modifications to the present invention without departing from the spirit and scope of the present invention. Therefore, if these modifications and variations of the present invention fall within the technical scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.

Claims (6)

1. A method for eliminating control disorder of a DC servo motor is characterized in that,
adding a timestamp generator, a logic comparator and a prediction controller to a network control system to realize the reordering of the out-of-order data packets; the method specifically comprises the following steps:
step S1, the time stamp generator is arranged at the sensor end for marking the data collected by the sensor;
step S2, setting logic comparators at two ends of the controller and the actuator respectively; the two logic comparators respectively compare the time stamps of the data received by the controller and the actuator, compare the time stamp of the newly arrived data with the time stamp of the data stored in the register and judge whether disorder occurs; if the timestamp of the newly arrived data packet is newer than the timestamp of the original data packet, no disorder occurs, otherwise, disorder occurs; if the judgment result is out of order, updating the data in the register, otherwise, keeping the data in the register unchanged; when the register is updated, the controller sends a control signal to the actuator, and the actuator applies the control signal to the control of the direct current servo motor;
step S3, the prediction controller is arranged at the controller end, the prediction controller obtains the prediction output signal u through the prediction algorithm and sends the prediction output signal u to the controller end, and a control signal is generated for the actuator to use; and the predicted output signal u is input into a motor system model described by a state equation, and the system is subjected to rolling optimization.
2. The method of claim 1, wherein the step of eliminating the control disorder of the DC servo motor,
the prediction algorithm is based on an extreme learning machine and specifically comprises the following steps:
(1) determining the number of neurons of the hidden layer by adopting a single hidden layer feedforward neural network structure, and randomly setting and fixing a connection weight w between an input layer and the hidden layer and a hidden layer neuron threshold b;
the input layer is fully connected with the hidden layer and the neuron of the output layer, and the input layer is provided with n neurons and corresponds to n input quantities; the hidden layer is a single layer, and the number of the neurons is l; the output layer is provided with m neurons and corresponds to m output quantities; the connection weight w between the input layer and the hidden layer is:
Figure FDA0002979489420000021
in the formula (1), wijRepresenting the connection weight between the ith input layer neuron and the jth hidden layer neuron, wherein l represents the number of the neurons of the hidden layer; to represent
The connection weight β between the hidden layer and the output layer is:
Figure FDA0002979489420000022
wherein beta isjkRepresenting the connection weight between the jth neuron of the hidden layer and the kth neuron of the output layer; l represents the number of neurons in the hidden layer; m represents the number of neurons in the output layer;
the threshold b for hidden layer neurons is:
Figure FDA0002979489420000023
wherein b isiA threshold value representing the ith hidden layer neuron;
(2) determining an activation function g (x) of the hidden layer neuron, and calculating an output matrix H;
(3) calculating the weight of the output layer
Figure FDA0002979489420000031
T' is the transposition of the matrix T; h is the hidden layer output matrix of the neural network;
(4) grouping the known control signals, and normalizing the control signals to be used as an input matrix of the neural network;
(5) predicting a control signal of the next step;
(6) and taking the prediction result as the input of the system model.
3. The method of claim 1, wherein the step of eliminating the control disorder of the DC servo motor,
the motor system model described in the equation of state:
Figure FDA0002979489420000032
wherein x (k) is ∈ RnIs a state variable, u (k) and y (k) are the system input and output, respectively, the matrix A,B and cTIs a constant matrix with dimension n × n; m-step change occurs to the input of the system from the moment k, the system state at the future P moments under the action of prediction inputs u (k), u (k +1) … u (k + i) … u (k + M-1) is calculated, and u (k + i) is predicted by an ELM algorithm;
the system state prediction is expressed as:
X(k)=Fx·x(k)+Gx·U(k) (15)
wherein,
Figure FDA0002979489420000033
Figure FDA0002979489420000041
Figure FDA0002979489420000042
Figure FDA0002979489420000043
wherein FxAnd GxA matrix of coefficients for x (k) and u (k), respectively, consisting of A and B; p represents that P times of prediction is carried out on P future sampling moments;
equation (15) predicts the system state at the future time of the system, and outputs the system state according to the relational expression y (k) cTx (k) to predict the output of the system and send the output to the controller for the rolling optimization of the system.
4. The method of claim 1, wherein the step of eliminating the control disorder of the DC servo motor,
the system rolling optimization specifically comprises the following steps:
the state optimization problem at the time k is expressed by determining M control quantities u (k), u (k +1), … and u (k + M-1) from the time k, so that the states of a controlled object at the future P times under the action of the M control quantities are stabilized, x is close to 0, and the optimization performance index is expressed in a vector form:
Figure FDA0002979489420000044
wherein Q isx,RxIs a state weighting matrix and a control weighting matrix; and when the constraint is not considered, solving an analytical expression of an optimal solution by combining a state prediction model: j (k) performance index at the moment of table k;
Figure FDA0002979489420000051
from this, the instantaneous control amount:
Figure FDA0002979489420000052
wherein the feedback gain
Figure FDA0002979489420000053
Figure FDA0002979489420000054
Figure FDA0002979489420000055
A matrix G of coefficients of u (k)xThe transposing of (1).
5. The method according to claim 2, wherein the step of eliminating the control disorder of the DC servo motor,
the step (2) specifically comprises the following steps
The input matrix X and the output matrix Y of the training set with Q training samples are respectively as follows:
Figure FDA0002979489420000056
Figure FDA0002979489420000057
xijrepresenting the input value, y, of the jth sample of the ith input layerijRepresenting an output value of a jth sample of an ith output layer;
the activation function of hidden layer neuron is g (x), the training sample is normalized and then used as the input of the neural network, and simultaneously the output signal is predicted and used as the input of the system model:
u=[u1 u2 …ui…uQ]n×Q (6)
wherein,
Figure FDA0002979489420000061
in the formula (7), uiRepresents the ith input layer sample, uijRepresenting the input of the jth input sample of the ith input layer;
obtaining the output T of the neural network through an ELM structure diagram as follows:
T=[t1 t2 …tj… tQ]m×Q (8)
Figure FDA0002979489420000062
wherein, wi=[wi1,wi2,…win];xj=[u1j,u2j,…unj]T
tjRepresents the output of the jth sample, tmjIs shown asThe output of the jth sample of the m output layers;
formula (9) is represented as:
Hβ=T′ (10)
wherein T' is the transposition of the matrix T; h is the hidden layer output matrix of the neural network;
Figure FDA0002979489420000063
6. the method according to claim 2, wherein the step of eliminating the control disorder of the DC servo motor,
step (3) calculating the weight of the output layer
Figure FDA0002979489420000071
The method specifically comprises the following steps:
fixing the randomly selected input weight w and the threshold b of the hidden layer, the training network is equivalent to solving the least square solution β of the linear system H β ═ T',
Figure FDA0002979489420000072
the solution is:
Figure FDA0002979489420000073
wherein H+The Moor-Penrose generalized inverse of the hidden layer output matrix H.
CN201810657507.2A 2018-06-25 2018-06-25 Method for eliminating control disorder of direct current servo motor Active CN108803335B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810657507.2A CN108803335B (en) 2018-06-25 2018-06-25 Method for eliminating control disorder of direct current servo motor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810657507.2A CN108803335B (en) 2018-06-25 2018-06-25 Method for eliminating control disorder of direct current servo motor

Publications (2)

Publication Number Publication Date
CN108803335A CN108803335A (en) 2018-11-13
CN108803335B true CN108803335B (en) 2021-05-11

Family

ID=64084857

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810657507.2A Active CN108803335B (en) 2018-06-25 2018-06-25 Method for eliminating control disorder of direct current servo motor

Country Status (1)

Country Link
CN (1) CN108803335B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114237042B (en) * 2021-11-25 2022-06-03 季华实验室 Pulse diagnosis and pre-pressure control method and system

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101437239A (en) * 2008-12-11 2009-05-20 吉林大学 Real time sensor signal network transmission method based on linear prediction filtering
CN105353622A (en) * 2015-11-30 2016-02-24 浙江工业大学 Dynamic matrix control method for networked system having time delay and packet loss
CN107122790A (en) * 2017-03-15 2017-09-01 华北电力大学 Non-intrusion type load recognizer based on hybrid neural networks and integrated study
CN107145935A (en) * 2017-05-12 2017-09-08 东华大学 A Smith Predictive Control Method Based on Improved Neural Network

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8144611B2 (en) * 2009-02-10 2012-03-27 Microsoft Corporation Network coordinate systems using IP information

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101437239A (en) * 2008-12-11 2009-05-20 吉林大学 Real time sensor signal network transmission method based on linear prediction filtering
CN105353622A (en) * 2015-11-30 2016-02-24 浙江工业大学 Dynamic matrix control method for networked system having time delay and packet loss
CN107122790A (en) * 2017-03-15 2017-09-01 华北电力大学 Non-intrusion type load recognizer based on hybrid neural networks and integrated study
CN107145935A (en) * 2017-05-12 2017-09-08 东华大学 A Smith Predictive Control Method Based on Improved Neural Network

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Daniel L'opez-Echevarr'ıa等.Neural Network and Observer-Based Compensation of Networked Control Systems with Packet Dropout.《IFAC》.2013, *
网络控制系统中的时戳预测函数控制;张奇智 等;《控制理论与应用》;20060228;第23卷(第1期);第126-130页 *

Also Published As

Publication number Publication date
CN108803335A (en) 2018-11-13

Similar Documents

Publication Publication Date Title
CN108944930B (en) A LSTM-based automatic vehicle following method and system for simulating driver characteristics
Yin et al. Data-driven models for train control dynamics in high-speed railways: LAG-LSTM for train trajectory prediction
CN102096373B (en) Microwave drying PID (proportion integration differentiation) control method based on increment improved BP (back propagation) neural network
CN112053560B (en) Short-time traffic flow prediction method, system and storage medium based on neural network
US11543787B2 (en) Networked control system time-delay compensation method based on predictive control
CN105376097A (en) Hybrid prediction method for network traffic
CN106022521A (en) Hadoop framework-based short-term load prediction method for distributed BP neural network
CN110163436A (en) Intelligent workshop production optimization method based on bottleneck prediction
CN104238366A (en) Predictive control method and device of piezoelectric ceramic actuator on basis of neural network
CN106707764B (en) RBF model reference adaptive control method for EMU braking process based on multi-level switching
Tian et al. Time-delay compensation method for networked control system based on time-delay prediction and implicit PIGPC
CN114548368A (en) Modeling method, prediction model and prediction method of lithium battery temperature field prediction model based on multilayer nuclear overrun learning machine
CN108170029B (en) Parameter self-tuning method based on partial derivative information for MIMO full-format model-free controller
CN111190429A (en) Unmanned aerial vehicle active fault-tolerant control method based on reinforcement learning
CN112949894B (en) A water BOD prediction method based on simplified long short-term memory neural network
Zou et al. Model predictive control based on particle swarm optimization of greenhouse climate for saving energy consumption
CN108803335B (en) Method for eliminating control disorder of direct current servo motor
CN109143853B (en) Self-adaptive control method for liquid level of fractionating tower in petroleum refining process
CN112949930A (en) PA-LSTM network-based road motor vehicle exhaust high-emission early warning method
CN105259754B (en) A kind of plate thickness intelligent control method based on Active Learning
CN105511263A (en) Distributed model predictive control method based on hierarchical decomposition
CN108873691A (en) Bullet train Generalized Prediction tuning control method
CN115180461A (en) Tension data drive control method for new energy vehicle compressor motor production equipment
CN113326962B (en) Subway train ATO speed curve prediction method based on BP neural network
CN114415507A (en) Method for building and training dexterous hand grasping process dynamic model based on deep neural network

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant