?? fblinit.m
字號(hào):
% ------------------------------> FBLINIT.M <------------------------------
% ---------- Switches -----------
regty ='fbl'; % Controller type (fbl, pid, none)
refty ='siggener'; % Reference signal (siggener/<var. name>)
simul ='simulink'; % Control object spec. (simulink/matlab/nnet)
% ------ General Initializations -------
Ts = 0.20; % Sampling period (in seconds)
samples = 300 ; % Number of samples to be simulated
% -- System to be Controlled (SIMULINK) --
sim_model = 'spm1'; % Name of SIMULINK model
% --- System to be Controlled (MATLAB) --
mat_model = 'springm'; % Name of MATLAB model
model_out = 'smout'; % Output equation (function of the states)
x0 = [0;0]; % Initial states
% ----- Neural Network Specification ------
% "nnfile" must contain the following variables which together define
% the network model:
% NN, NetDeff, NetDefg, W1f, W2f, W1g, W2g
% (i.e. regressor structure, architecture definitions, and weight matrices)
nnfile = 'forward3'; % Name of file
% ---- Desired characteristic polynomial ---
Am = [1 -1.4 0.49]; % Characteristic polynomial
% ------------ Reference signal ------------
dc = 0; % DC-level
sq_amp = 1; % Amplitude of square signals (row vector)
sq_freq = 0.05; % Frequency of square signals (column vector)
sin_amp = [0]; % Amplitude of sine signals (row vector)
sin_freq= [0]'; % Frequency of sine signals (column vector)
Nvar = 0'; % Variance white noise signal
% -------- Linear Controller Parameters ---------
K=8; % PID parameters
Td=0.8; % PID
alf=0.1; % PID
Wi=0.2; % PID (1/Ti)
% ------- Specify data vectors to plot --------
% Notice that all strings in plot_a and plot_b resp. MUST have the same length
plot_a(1,:) = 'ref_data ';
plot_a(2,:) = 'ym_data ';
plot_a(3,:) = 'y_data ';
plot_b(1,:) = 'u_data';
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -