资源简介
MATLAB实现的模糊自适应控制函数的源代码
代码片段和文件信息
clear % Clear all variables in memory
eold=0; % Intial condition used to calculate c
rold=0; % Intial condition used to calculate r
yeold=0; % Intial condition used to calculate yc
ymold=0; % Initial condition for the first order reference model
% Next initialize parameters for the fuzzy controller
nume=11; % Number of input membership functions for the e
% universe of discourse
numc=11; % Number of input membership functions for the c
% universe of discourse
ge=1/2;gc=1/2;gu=5;
% Scaling gains for tuning membership functions for
% universes of discourse for e c and u respectively
% These are tuned to improve the performance of the FMRLC
we=0.2*(1/ge);
% we is half the width of the triangular input membership
% function bases (note that if you change ge the base width
% will correspondingly change so that we always end
% up with uniformly distributed input membership functions)
% Note that if you change nume you will need to adjust the
% “0.2“ factor if you want membership functions that
% overlap in the same way.
wc=0.2*(1/gc);
% Similar to we but for the c universe of discourse
base=0.4*gu;
% base width of output membership fuctions of the fuzzy
% controller
% Place centers of membership functions of the fuzzy controller:
% Centers of input membership functions for the e universe of
% discourse for of fuzzy controller (a vector of centers)
ce=[-1 -0.8 -0.6 -0.4 -0.2 0 0.2 0.4 0.6 0.8 1]*(1/ge);
% Centers of input membership functions for the c universe of
% discourse for of fuzzy controller (a vector of centers)
cc=[-1 -0.8 -0.6 -0.4 -0.2 0 0.2 0.4 0.6 0.8 1]*(1/gc);
gf=0;
fuzzyrules=[-1 -1 -1 -1 -1 -1 -0.8 -0.6 -0.4 -0.2 0;
-1 -1 -1 -1 -1 -0.8 -0.6 -0.4 -0.2 0 0.2;
-1 -1 -1 -1 -0.8 -0.6 -0.4 -0.2 0 0.2 0.4;
-1 -1 -1 -0.8 -0.6 -0.4 -0.2 0 0.2 0.4 0.6;
-1 -1 -0.8 -0.6 -0.4 -0.2 0 0.2 0.4 0.6 0.8;
-1 -0.8 -0.6 -0.4 -0.2 0 0.2 0.4 0.6 0.8 1;
-0.8 -0.6 -0.4 -0.2 0 0.2 0.4 0.6 0.8 1 1;
-0.6 -0.4 -0.2 0 0.2 0.4 0.6 0.8 1 1 1;
-0.4 -0.2 0 0.2 0.4 0.6 0.8 1 1 1 1;
-0.2 0 0.2 0.4 0.6 0.8 1 1 1 1 1;
0 0.2 0.4 0.6 0.8 1 1 1 1 1 1]*gu*gf;
% Next we define some parameters for the fuzzy inverse model
gye=1/2;gyc=1/2;
% Scaling gains for the error and change in error for
% the inverse model
% These are tuned to improve the performance of the FMRLC
gp=0.2;
numye=11; % Number of input membership functions for the ye
% universe of discourse
numyc=11; % Number of input membership functions for the yc
% universe of discourse
wye=0.2*(1/gye); % Sets the width of the membership functions for
% ye from center to extremes
wyc=0.2*(1/gyc); % Sets the width of the membership functions for
% yc from center to extremes
invbase=0.4*gp; % Sets the base of
- 上一篇:matlab 全息图
- 下一篇:Matlab图像模板匹配算法
相关资源
- Matlab实现FCM算法
- 人脸识别及匹配的matlab实现
- [Matlab作品]matlab实现视频中动态目标跟
- 一维热传导方程数值解法及matlab实现
- svpwm的matlab实现
- gabor提取图像特征原理及其matlab实现
- Matlab实现图像风格化 倒影浮雕素描
- 课件《神经.模糊.预测控制及其MATLA
- Matlab实现无线传感器网络节点定位的
- 基于BP神经网络的水上交通事故预测及
- Matlab实现softmax分类
- 人脸目标检测的matlab实现论文
- MATLAB实现群体多目标优化算法MOALO蚁狮
- MATLAB实现基于Daugman的虹膜提取算法源
- 数字图像处理及MATLAB实现代码和图片
- 电磁场数值计算法与MATLAB实现 何红雨
- 行人检测的matlab实现
- 数字信号处理原理及其MATLAB实现
- 机械建模机械建模各章节课程作业、
- 基于K-means算法的遥感图像分类的mat
- UWB定位的MATLAB实现
- 数字图像处理车牌识别课程设计matl
- matlab实现的人体跟踪kalman滤波
- 简单的matlab实现的ransac平面拟合程序
- 基于Matlab实现的图像分割的常用算法
- TURBO码的MATLAB实现
- 差分蜂群优化算法MATLAB实现.rar
- 基于AdaBoost算法的人脸检测,matlab实现
- PSO负载均衡算法-matlab实现
- 纠错编码原理及MATLAB实现-刘爱莲课件
评论
共有 条评论