function [coord] = CST_airfoil(wl,wu,dz,N);
% Description : Create a set of airfoil coordinates using CST parametrization method
% Input : wl = CST weight of lower surface
% wu = CST weight of upper surface
% dz = trailing edge thickness
% Output : coord = set of x-y coordinates of airfoil generated by CST
% Create x coordinate
x=ones(N+1,1);y=zeros(N+1,1);zeta=zeros(N+1,1);
for i=1:N+1
zeta(i)=2*pi/N*(i-1);
x(i)=0.5*(cos(zeta(i))+1);
end
% N1 and N2 parameters (N1 = 0.5 and N2 = 1 for airfoil shape)
N1 = 0.5;
N2 = 1;
zerind = find(x(:,1) == 0); % Used to separate upper and lower surfaces
xl= x(1:zerind-1); % Lower surface x-coordinates
xu = x(zerind:end); % Upper surface x-coordinates
[yl] = ClassShape(wl,xl,N1,N2,-dz); % Call ClassShape function to determine lower surface y-coordinates
[yu] = ClassShape(wu,xu,N1,N2,dz); % Call ClassShape function to determine upper surface y-coordinates
y = [yl;yu]; % Combine upper and lower y coordinates
coord = [x y]; % Combine x and y into single output
%% Function to calculate class and shape function
function [y] = ClassShape(w,x,N1,N2,dz);
% Class function; taking input of N1 and N2
for i = 1:size(x,1)
C(i,1) = x(i)^N1*((1-x(i))^N2);
end
% Shape function; using Bernstein Polynomials
n = size(w,2)-1; % Order of Bernstein polynomials
for i = 1:n+1
K(i) = factorial(n)/(factorial(i-1)*(factorial((n)-(i-1))));
end
for i = 1:size(x,1)
S(i,1) = 0;
for j = 1:n+1
S(i,1) = S(i,1) + w(j)*K(j)*x(i)^(j-1)*((1-x(i))^(n-(j-1)));
end
end
% Calculate y output
for i = 1:size(x,1)
y(i,1) = C(i,1)*S(i,1) + x(i)*dz;
end

wouderw
- 粉丝: 347
- 资源: 2960
最新资源
- 超好用的卸载软件HibitUninstaller
- 2024年全国地区工程审计总监职位薪酬调查报告
- 物联网实时操作系统_RT-Thread_学习笔记_辅助教学_1741164527.zip
- 博创杯App_厨艺分享社交平台_1741163838.zip
- 2024年全国地区工程预决算工程师职位薪酬调查报告
- 微服务架构_社区团购_尚上优选_企业级应用_1741166080.zip
- Cron组件能设置能回填
- 永磁同步电机最大转矩电流比控制优化研究:基于高频信号注入法的仿真分析与实践探索,基于高频信号注入法的永磁同步电机最大转矩电流比控制算法的在线参数辨识与MATLAB Simulink仿真研究,永磁同步电
- 物联网_智能家居_BS_SmartHome_应用场景_1741164215.zip
- 物联网_智能硬件_数据采集_应用_1741164785.zip
- 物联网_万联平台_统一设备管理_业务系统构建_1741164869.zip
- 机器人开发教程&案例-2025.zip
- 基于模糊PID控制算法的双容水箱液位精确调控设计与Simulink仿真实验,基于模糊PID算法的双容水箱液位控制系统的设计与仿真实验报告,基于模糊pid的双容水箱设计 1.双容水箱液位控制系统 基于模
- C#实现三菱FX5U PLC通信控制:实例展示,包含辅助继电器读写、单双子读写、IO监控与报警显示功能,C#实现三菱FX5U PLC通信控制:实例展示,包含辅助继电器读写、单双子读写、IO监控与报警显
- delphi 实现的 走马灯效果.rar
- 标题:基于SVPWM技术的直接转矩控制(DTC-SVM)算法仿真研究及MATLAB Simulink模型构建 该标题满足了您的要求,涵盖了永磁同步电机控制算法的核心理念-空间电压矢量调制(SVPW
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈



- 1
- 2
- 3
- 4
- 5
- 6
前往页