You are on page 1of 2

function [z,g] = RTS_MASS_OPTI(s);

%Load R (Blade Station), mpl (Station Masses per unit length), EI (Station
Stiffness)
load blade.mat
%Linearly Interpolate Blade Data
[R,EI,mpl,MB] = expand(R,EI,mpl);
% Shorten Blade to proper length
[a,b] = min(abs(R-29));
R = R(1:b);

%Number of Bending Moments Constraints(Mean, Alternating)


numcon=1;
% initial guess and bounds
s = zeros(numvar,1);
su = zeros(numvar,1);
sl = zeros(numvar,1);
%Set Optimization Variable Bounds
%Mass of Stationary Weight in kg
sl = [1 1001 1];
su = [1000 1500 1000];
%Set Initial Optimization Variables
SI = sl/2+su/2;
% evaluation of initial design
[z,g]=RTS_MASS_OPTI(SI)
s = SI;
% sequential convex program
s = scp('RTS_MASS_OPTI','gradient',s',su',sl');
[z,g]=RTS_MASS_OPTI(s)
save stmp
freq
s
for ii = 1:360
% pa = Phase Angle
pa = ii;
% Blade Cross-Section 1
% Load Unit-Load Results from FEM
load edge1;
sze = sz/21000;
load flap1;
szf = sz/21000;
t = [0:.01:2*pi+.01];
fm = 12500;
fm = 0;
fa = 15000;
f = fm+fa*sin(t);
em = 0;
ea = 13000;
e = em+ea*sin(t+pa/180*pi);
szt = sze*e+szf*f;

fm = 0;
fa = 15000;
f = fm+fa*sin(t);
em = 0;
ea = 13000;
e = em+ea*sin(t+pa/180*pi);
szt = sze*e+szf*f;
sz_peak(ii,:) = max(szt');
sz_val(ii,:) = min(szt');
[d(ii,:)]=strain_dam(nx,ny,szt);
end

You might also like