版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進(jìn)行舉報(bào)或認(rèn)領(lǐng)
文檔簡介
1、一、 控制系統(tǒng)的模型與轉(zhuǎn)換1 請將下面的傳遞函數(shù)模型輸入到matlab環(huán)境。 ,T=0.1s s=tf(s); G=(s3+4*s+2)/(s3*(s2+2)*(s2+1)3+2*s+5); G Transfer function: s3 + 4 s + 2-s11 + 5 s9 + 9 s7 + 2 s6 + 12 s5 + 4 s4 + 12 s3 num=1 0 0.56; den=conv(1 -1,1 -0.2 0.99); H=tf(num,den,Ts,0.1) Transfer function: z2 + 0.56-z3 - 1.2 z2 + 1.19 z - 0.992 請
2、將下面的零極點(diǎn)模型輸入到matlab環(huán)境。請求出上述模型的零極點(diǎn),并繪制其位置。 ,T=0.05sz=-1-j -1+j; p=0 0 -5 -6 -j j; G=zpk(z,p,8) Zero/pole/gain: 8 (s2 + 2s + 2)-s2 (s+5) (s+6) (s2 + 1)pzmap(G) z=0 0 0 0 0 -1/3.2 -1/2.6; p=1/8.2; H=zpk(z,p,1,Ts,0.05) Zero/pole/gain:z5 (z+0.3125) (z+0.3846)- (z-0.122) Sampling time: 0.05pzmap(H)二、 線性系統(tǒng)分
3、析1. 請分析下面?zhèn)鬟f函數(shù)模型的穩(wěn)定性。 num=1;den=1 2 1 2;G=tf(num,den);eig(G)ans =-2.0000 0.0000 - 1.0000i 0.0000 + 1.0000i可見,系統(tǒng)有兩個(gè)特征根在虛軸上,一個(gè)特征根在虛軸左側(cè),所以系統(tǒng)是臨界穩(wěn)定的。 num=3 1;den=300 600 50 3 1;G=tf(num,den);eig(G)ans = -1.9152 -0.14140.0283 - 0.1073i 0.0283 + 0.1073i可見,有兩個(gè)特征根在虛軸右側(cè),所以系統(tǒng)是不穩(wěn)定的。2. 請判定下面離散系統(tǒng)的穩(wěn)定性。 num=-3 2; de
4、n=1 -0.2 -0.25 0.05; H=tf(num,den,Ts,0.1); eig(H) abs(eig(H) ans = -0.5000 0.5000 0.5000 0.50000.2000 0.2000可以看出,由于各個(gè)特征根的模均小于1,所以可以判定閉環(huán)系統(tǒng)是穩(wěn)定的。 z=tf(z,0.1); H=(2.12*z-2+11.76*z-1+15.91)/;(z-5-7.368*z-4-20.15*z-3+102.4*z-2+80.39*z-1-340); eig(H) abs(eig(H) ans = 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
5、 0 0 0 0 4.1724 4.1724 0.3755 + 0.1814i 0.4170 0.3755 - 0.1814i 0.4170 -0.5292 0.5292 -0.2716 0.2716 0.1193 0.1193 可以看出,由于4.1724這個(gè)特征根的模大于1,所以可以判定閉環(huán)系統(tǒng)是不穩(wěn)定的。3. 設(shè)描述系統(tǒng)的傳遞函數(shù)為,假定系統(tǒng)具有零初始狀態(tài),請求出單位階躍響應(yīng)曲線和單位脈沖響應(yīng)曲線。 num=18 514 5982 36380 122664 22088 185760 40320; den=1 36 546 4536 22449 67284 118124 109584 403
6、20; G=tf(num,den) Transfer function: 18 s7 + 514 s6 + 5982 s5 + 36380 s4 + 122664 s3 + 22088 s2 + 185760 s + 40320-s8 + 36 s7 + 546 s6 + 4536 s5 + 22449 s4 + 67284 s3 + 118124 s2 + 109584 s + 40320 step(G,10) impulse(G,10)單位階躍響應(yīng):單位脈沖響應(yīng):三、 線性系統(tǒng)Simulink仿真應(yīng)用1. 請分析下面?zhèn)鬟f函數(shù)模型階躍響應(yīng)。 利用Simulink建模,建立系統(tǒng)仿真模型如下:單
7、擊啟動(dòng)仿真按鈕,雙擊示波器得到系統(tǒng)的階躍響應(yīng)如下:2. 請分析下面離散系統(tǒng)的脈沖響應(yīng)。 利用Simulink建模,建立系統(tǒng)仿真模型如下:單擊啟動(dòng)仿真按鈕,雙擊示波器得到系統(tǒng)的脈沖響應(yīng)如下:3. 對離散采樣系統(tǒng)進(jìn)行分析,并求出其階躍響應(yīng)。 其中:利用Simulink建模,建立系統(tǒng)仿真模型如下:單擊啟動(dòng)仿真按鈕,雙擊示波器得到系統(tǒng)的階躍響應(yīng)如下:4. 設(shè)計(jì)控制器,使得下列系統(tǒng)穩(wěn)定。 利用Simulink建模,未連入控制器時(shí),仿真模型和響應(yīng)如下:利用Simulink建模,設(shè)計(jì)控制器:從響應(yīng)輸出圖形可以看出,連入控制器后系統(tǒng)穩(wěn)定,性能明顯提高。四、 基于MATLAB的PID 控制器設(shè)計(jì)設(shè)計(jì)題目:1.
8、應(yīng)用Ziegler Nichols算法設(shè)計(jì)PID控制器,實(shí)現(xiàn)系統(tǒng)的閉環(huán)穩(wěn)定,并比較對各個(gè)系統(tǒng)的控制效果。 未連入PID控制器時(shí)的系統(tǒng)仿真及其性能指標(biāo)如下: 可見,未調(diào)節(jié)時(shí)的系統(tǒng)性能有待提高,需設(shè)計(jì)PID控制器連入。輸入: num=1; den=conv( 1,1,conv( 1,1,1,1 ); Step(num,den); K=dcgain (num,den)得出:K =1根據(jù)圖形,得出:L=1.86 T=4.4利用自定義的Ziegler_std函數(shù)求出Kp、Ti、Td輸入: K=1; L=1.86; T=4.4; num,den,Kp,Ti,Td=Ziegler_std (3,K,L,T)
9、得出:num = 2.6400 2.8387 1.5262den =1 0Kp =2.8387Ti =3.7200Td =0.9300根據(jù)得出的Kp、Ti、Td值,設(shè)計(jì)PID控制器,并利用利用Simulink仿真建模。仿真模型及其響應(yīng)如下:可見,加入PID控制器調(diào)節(jié)后,系統(tǒng)性能明顯改善。未連入PID控制器時(shí)的系統(tǒng)仿真及其性能指標(biāo)如下: 可見,未調(diào)節(jié)時(shí)的系統(tǒng)性能有待提高,需設(shè)計(jì)PID控制器連入。輸入: num=1; den=conv(1,1,conv(1,1,;conv( 1,1,conv( 1,1,1,1 ); Step(num,den); K=dcgain (num,den)得出:K = 1
10、根據(jù)圖形,得出:L=3.4 T=6.8利用自定義的Ziegler_std函數(shù)求出Kp、Ti、Td輸入: K=1; L=3.4; T=6.8; num,den,Kp,Ti,Td=Ziegler_std (3,K,L,T)得出:num = 4.0800 2.4000 0.7059den = 1 0Kp = 2.4000Ti = 6.8000Td =1.7000根據(jù)得出的Kp、Ti、Td值,設(shè)計(jì)PID控制器,并利用利用Simulink仿真建模。仿真模型及其響應(yīng)如下:可見,加入PID控制器調(diào)節(jié)后,系統(tǒng)性能明顯改善。利用Simulink建模,未連入控制器時(shí),仿真模型和響應(yīng)如下:可見,未調(diào)節(jié)時(shí)的系統(tǒng)性能有
11、待提高,需設(shè)計(jì)PID控制器連入。輸入:num=-1.5 1; den=conv( 1,1,conv( 1,1,1,1 ); Step(num,den); K=dcgain (num,den)得出:K =1根據(jù)圖形,得出:L=1.8 T=5.7利用自定義的Ziegler_std函數(shù)求出Kp、Ti、Td輸入: K=1; L=1.8 T=5.7; num,den,Kp,Ti,Td=Ziegler_std (3,K,L,T)得出:num = 3.4200 3.8000 2.1111den =1 0Kp =3.8000Ti =3.6000Td =0.9000根據(jù)得出的Kp、Ti、Td值,設(shè)計(jì)PID控制器
12、,并利用利用Simulink仿真建模。仿真模型及其響應(yīng)如下:可見,加入PID控制器調(diào)節(jié)后,系統(tǒng)性能明顯改善。五、 模糊控制器設(shè)計(jì)設(shè)計(jì)任務(wù):試設(shè)計(jì)一個(gè)模糊控制器,實(shí)現(xiàn)對室內(nèi)溫度的控制的模擬。參考輸入:(1)溫度18-40范圍內(nèi)分為七個(gè)論域,NB NM NS ZE PS PM PB;隸屬度函數(shù)滿足高斯分布;(2)溫度變化率-2 2范圍內(nèi)分為七個(gè)論域,NB NM NS ZE PS PM PB;隸屬度函數(shù)滿足高斯分布;參考輸出:變頻空調(diào)輸出的控制信號(hào)。在一定范圍內(nèi)分為七個(gè)論域,NB NM NS ZE PS PM PB,隸屬度函數(shù)為常數(shù)1。模糊推理過程,output=輸入隸屬度函數(shù)值*輸出論域的中心值。
13、注:本模糊程序采用PAM控制方式的壓縮機(jī),則其輸出的轉(zhuǎn)速范圍為:010500轉(zhuǎn)/分??刂埔?guī)則:% % if input is NB and errorinput is NB, then output is NB;% % if input is NB and errorinput is NM, then output is NB;% % if input is NB and errorinput is NS, then output is NB;% % if input is NB and errorinput is ZE, then output is NM;% % if input is N
14、B and errorinput is PS, then output is NM;% % if input is NB and errorinput is PM, then output is NM;% % if input is NB and errorinput is PB, then output is NS;% % if input is NM and errorinput is NB, then output is NB;% % if input is NM and errorinput is NM, then output is NM;% % if input is NM and
15、 errorinput is NS, then output is NM;% % if input is NM and errorinput is ZE, then output is NM;% % if input is NM and errorinput is PS, then output is NM;% % if input is NM and errorinput is PM, then output is NS;% % if input is NM and errorinput is PB, then output is NS;% % if input is NS and erro
16、rinput is NB, then output is NM;% % if input is NS and errorinput is NM, then output is NS;% % if input is NS and errorinput is NS, then output is NS;% % if input is NS and errorinput is ZE, then output is NS;% % if input is NS and errorinput is PS, then output is NS;% % if input is NS and errorinpu
17、t is PM, then output is ZE;% % if input is NS and errorinput is PB, then output is ZE;% % if input is ZE and errorinput is NB, then output is NS;% % if input is ZE and errorinput is NM, then output is ZE;% % if input is ZE and errorinput is NS, then output is ZE;% % if input is ZE and errorinput is
18、ZE, then output is ZE;% % if input is ZE and errorinput is PS, then output is ZE;% % if input is ZE and errorinput is PM, then output is PS;% % if input is ZE and errorinput is PB, then output is PS;% % if input is PS and errorinput is NB, then output is ZE;% % if input is PS and errorinput is NM, t
19、hen output is PS;% % if input is PS and errorinput is NS, then output is PS;% % if input is PS and errorinput is ZE, then output is PS;% % if input is PS and errorinput is PS, then output is PS;% % if input is PS and errorinput is PM, then output is PM;% % if input is PS and errorinput is PB, then o
20、utput is PM;% % if input is PM and errorinput is NB, then output is PS;% % if input is PM and errorinput is NM, then output is PS;% % if input is PM and errorinput is NS, then output is PM;% % if input is PM and errorinput is ZE, then output is PM;% % if input is PM and errorinput is PS, then output
21、 is PM;% % if input is PM and errorinput is PM, then output is PM;% % if input is PM and errorinput is PB, then output is PB;% % if input is PB and errorinput is NB, then output is PS;% % if input is PB and errorinput is NM, then output is PM;% % if input is PB and errorinput is NS, then output is P
22、M;% % if input is PB and errorinput is ZE, then output is PM;% % if input is PB and errorinput is PS, then output is PB;% % if input is PB and errorinput is PM, then output is PB;% % if input is PB and errorinput is PB, then output is PB;1.輸入為:程序?yàn)椋?x1 = (18:0.1:40);y0 = gaussmf(x1, 1 18);y1 = gaussm
23、f(x1, 1 21);y2 = gaussmf(x1, 1 25);y3 = gaussmf(x1, 1 29);y4 = gaussmf(x1, 1 33);y5 = gaussmf(x1, 1 37);y6 = gaussmf(x1, 1 40);plot(x1,y0 y1 y2 y3 y4 y5 y6)2.誤差圖:程序?yàn)椋?x1 = (-2:0.1:2);y0 = gaussmf(x1, 0.5 -2);y1 = gaussmf(x1, 0.5 -1.3);y2 = gaussmf(x1, 0.5 -0.7);y3 = gaussmf(x1, 0.5 0);y4 = gaussmf(x
24、1, 0.5 0.7);y5 = gaussmf(x1, 0.5 1.3);y6 = gaussmf(x1, 0.5 2);plot(x1,y0 y1 y2 y3 y4 y5 y6)3.程序?yàn)?;x=35;ex=-0.8;% define input type in fuzzy zoney0 = gaussmf(x, 1 18);y1 = gaussmf(x, 1 21);y2 = gaussmf(x, 1 25);y3 = gaussmf(x, 1 29);y4 = gaussmf(x, 1 33);y5 = gaussmf(x, 1 37);y6 = gaussmf(x, 1 40);a=y
25、0 y1 y2 y3 y4 y5 y6;b=max(a);% caculate input in fuzzy zone,get input_type and input_authorityvalueif x=18 if b=a(1) type=NB; authorityvalue=y0; elseif b=a(2) type=NM; authorityvalue=y1; elseif b=a(3) type=NS; authorityvalue=y2; elseif b=a(4) type=ZE; authorityvalue=y3;elseif b=a(5) type=PS; authorityvalue=y4;elseif b=a(6) type=PM; authorityvalue=y5;elseif b
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲(chǔ)空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 2025年北師大版九年級歷史下冊階段測試試卷含答案
- 2025年新科版八年級地理上冊月考試卷
- 2025年華師大新版一年級語文下冊階段測試試卷含答案
- 2025年人教A新版九年級歷史下冊月考試卷含答案
- 2025年粵教新版高三英語上冊月考試卷含答案
- 2025年北師大版選擇性必修3歷史下冊階段測試試卷含答案
- 公民教育理論與實(shí)踐知到智慧樹章節(jié)測試課后答案2024年秋西華大學(xué)
- 2025年度定制衣柜設(shè)計(jì)制作合同樣本4篇
- 技術(shù)部合同范本(2篇)
- 房建工程監(jiān)理合同(2篇)
- 定額〔2025〕1號(hào)文-關(guān)于發(fā)布2018版電力建設(shè)工程概預(yù)算定額2024年度價(jià)格水平調(diào)整的通知
- 2024年城市軌道交通設(shè)備維保及安全檢查合同3篇
- 【教案】+同一直線上二力的合成(教學(xué)設(shè)計(jì))(人教版2024)八年級物理下冊
- 湖北省武漢市青山區(qū)2023-2024學(xué)年七年級上學(xué)期期末質(zhì)量檢測數(shù)學(xué)試卷(含解析)
- 單位往個(gè)人轉(zhuǎn)賬的合同(2篇)
- 電梯操作證及電梯維修人員資格(特種作業(yè))考試題及答案
- 科研倫理審查與違規(guī)處理考核試卷
- GB/T 44101-2024中國式摔跤課程學(xué)生運(yùn)動(dòng)能力測評規(guī)范
- 鍋爐本體安裝單位工程驗(yàn)收表格
- 高危妊娠的評估和護(hù)理
- 2024年山東鐵投集團(tuán)招聘筆試參考題庫含答案解析
評論
0/150
提交評論