单级倒立摆系统中模糊控制理论的应用 下载本文

如果x1是正且x2是负,则u是零; 如果x1是负且x2是正,则u是零; 如果x1是负且x2是负,则u是正最大值。

模糊集“正”、“负”、“负最大值”、“零”和“正最大值”的隶属函数分别为:

?正?x??11?e?30x2,?负?x??11?e30x,?负最大值?u??e??u?5?2,?零?u??e?u2,

?正最大值?u??e??u?5?。

要设计监督控制器,首先要确定边界fU和gL。对本系统,本文要求x1??9,

2mlx2cosx1sinx10.1?0.5?0.5sin?2x1?2gsinx1?9.8?x2mc?m1?0.1f?x1,x2???2?4mcosx1??40.1cos2x1?0.5??l??3?1?0.1???3?m?m????c??则有

0.02529.8?x221.1??15.78?0.0366x2?fU?x1,x2?20.05?31.1cosx1cos??9?mc?m0.1?1g?x1,x2???2?4mcosx1??40.12?0.5?cosx1???l??3?m?m???31.1? c???cos??9??1.1?gL?x1,x2??20.05?1.1???cos2???31.1?控制的目标能将任意初始角度x1????9,?9?的倒立摆控制到平衡点,并同时保证

?x1,x2?2??

9?Mx。

采用乘积推理机、单值模糊器和中性平均解模糊器,根据

M?N1?N2?N1?2,N2?2?条规则来构造模糊控制器ufuzz。由4条规则的结论克制:

y??5,y?0,y?0,y?5。则由式(3-2)得模糊控制器为

11122122ufuzz?y?正?x1??正?x2??y?负?x1??正?x2??y?正?x1??负?x2??y?负?x1??负?x2?11211222?正?x1??正?x2???负?x1??正?x2???正?x1??负?x2???负?x1??负?x2??5?正?x1??正?x2??5?负?x1??负?x2???正?x1??正?x2???负?x1??正?x2???正?x1??负?x2???负?x1??负?x2??5?111?e?30x1?e?30x1111?1?e?30x1?e?30x1?e30x1?e30x111111???1?e30x1?e?30x1?e?30x1?e30x1?e30x1?e30x

根据隶属函数设计程序,可得到隶属函数图,如图5-2和图5-3所示。位置指令

?100?k1?2,为xd?t??0,倒立摆初始状态为??60,0?,采用控制律式(3-3)。取Q???,010???155?k2?1,则求解Lyapunov方程得:P??。由于Mx??9,取a??18,仿真结??55?果如图5-4至图5-6所示

10.90.8Membership function degree of x0.70.60.50.40.30.20.10-0.4-0.3-0.2-0.10x0.10.20.30.4

图5-2 加速度x1的隶属函数

10.90.80.70.60.50.40.30.20.10-5-4-3-2-10u12345Membership function degree of u

图5-3 控制输入u的隶属函数

0.060.050.04Position response0.030.020.010-0.010246810time(s)1214161820

图5-4 位置响应

0.060.050.04Speed response0.030.020.010-0.010246810time(s)1214161820

图5-5 速度响应

Control input ufuzz0-1-20246810time(s)1214161820Control input us-14-16-180246810time(s)1214161820Control input ut0-1-20246810time(s)1214161820

图5-6 控制输入信号u