-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathp_param.m
137 lines (111 loc) · 3.4 KB
/
p_param.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
% P_PARAM
%
% Sluzi na vypocet parametrov P regulatora pomocou vybranej experimentalnej
% metody
% METODY
%
% ZIEGLER-NICHOLS
if typy_ns==1
z_r =((1/K)*(Tn/Tu));
t_i=1e10;
t_d=0;
close
simul_param
% STREJC
elseif typy_ns==2
% Testovanie vhodnosti radu, aby sa predislo deleniu nulou
if (n<2)
pth_fig = ptg_error('reg_v',ptg_string(11,9,ptv_str_lang),ptv_str_lang);
else
z_r =(1/K)*(1/(n-1));
t_i=1e10;
t_d=0;
close
simul_param
end
% COHEN-COON
elseif typy_ns==3
z_r =(1/K)*(Tn/Tu)*(1+((1/3)*(Tu/Tn)));
t_i=1e10;
t_d=0;
close
simul_param
% CHIEN,HRONES,RESWICK (0% PREREG.)
elseif typy_ns==4
figure('Color','blue',...
'Resize','off',...
'Numbertitle','off',...
'Menubar',ptv_fig_menubar,...
'Name',ptg_string(1,2,ptv_str_lang), ...
'Position',[120 200 360 150]);
sposob_navrhu= uicontrol(gcf,...
'Style','push',...
'Position',[30 100 300 30],...
'String',ptg_string(11,13,ptv_str_lang),...
'Fontsize',[11],...
'Fontweight','bold',...
'ForegroundColor','black',...
'CallBack','close,z_r =0.3*(Tn/(K*Tu));t_i=1e10;t_d=0;simul_param');
sposob_navrhu= uicontrol(gcf,...
'Style','push',...
'Position',[30 60 300 30],...
'String',ptg_string(11,14,ptv_str_lang),...
'Fontsize',[11],...
'Fontweight','bold',...
'ForegroundColor','black',...
'CallBack','close,z_r =0.3*(Tn/(K*Tu));t_i=1e10;t_d=0;simul_param');
navrat = uicontrol(gcf,...
'Style','push',...
'Position',[30 15 60 30],...
'Fontweight','bold',...
'Fontsize',[12],...
'String',ptg_string(3,2,ptv_str_lang),...
'ForegroundColor','black',...
'Callback','close,reg_v');
% CHIEN,HRONES,RESWICK (20% PREREG.)
elseif typy_ns==5
figure('Color','blue',...
'Resize','off',...
'Numbertitle','off',...
'Menubar',ptv_fig_menubar,...
'Name',ptg_string(1,2,ptv_str_lang), ...
'Position',[120 200 360 150]);
sposob_navrhu= uicontrol(gcf,...
'Style','push',...
'Position',[30 100 300 30],...
'String',ptg_string(11,13,ptv_str_lang),...
'Fontsize',[11],...
'Fontweight','bold',...
'ForegroundColor','black',...
'CallBack','close,z_r =0.7*(Tn/(K*Tu));t_i=1e10;t_d=0;simul_param');
sposob_navrhu= uicontrol(gcf,...
'Style','push',...
'Position',[30 60 300 30],...
'String',ptg_string(11,14,ptv_str_lang),...
'Fontsize',[11],...
'Fontweight','bold',...
'ForegroundColor','black',...
'CallBack','close,z_r =0.7*(Tn/(K*Tu));t_i=1e10;t_d=0;simul_param');
navrat = uicontrol(gcf,...
'Style','push',...
'Position',[30 15 60 30],...
'Fontweight','bold',...
'Fontsize',[12],...
'String',ptg_string(3,2,ptv_str_lang),...
'ForegroundColor','black',...
'Callback','close,reg_v');
% ITAE METHOD (ODSTRANENIE VPLYVU PORUCHY)
%
elseif typy_ns == 6
[z_r, t_i, t_d] = pte_itaem(1,K,Tu,Tn,2);
close
simul_param
% LOPEZ IAE-ISE METHOD
%
elseif typy_ns == 7
[z_r,t_i,t_d] = pte_iaeisem(1,K,Tu,Tn);
close
simul_param
% ------------------- %
%
end