Skip to content
Snippets Groups Projects
Verified Commit 422dc457 authored by Thomas Lambert's avatar Thomas Lambert :helicopter:
Browse files

feat(coax,WIP): add options for contraction

parent 8ad23625
No related branches found
No related tags found
No related merge requests found
......@@ -290,7 +290,7 @@ classdef ElemPerf < handle
calcforces(self) % Calculate forces, torque and power
[cl, cd] = getclcd(self, aoaVect, reyVect, i) % Get values of cl and cd
plotveltriangles(self, nTriangles, varargin)
updateupstreamvel(self, PrevOpRot)
updateupstreamvel(self, PrevOpRot, Mod)
end
end
......@@ -53,6 +53,11 @@ Mod.solvers = {'all'}; % BEMT Solver ('leishman', 'indfact', 'indvel', 'stahlh
% Extensions/corrections
Mod.Ext.losses = 'all'; % Include losses using Prandtl formula ('none', 'hub', 'tip', 'both')
% [COAXIAL ONLY] Contraction model
Mod.coax.model = 'mst'; % Type of contraction ('none', 'sst', 'smst', 'mst')
Mod.coax.contraType = 'farfield'; % (opt) Type of contraction ('farfield', 'value')
Mod.coax.contraVal = 1 / 2; % (opt) Contraction ratio between upper disk and lower rotor, [-]
% Numerical parameters
Mod.Num.convCrit = 1e-4; % Convergence criterion value,
Mod.Num.maxIter = 500; % Maximum number of iterations for convergence calculations
......
......@@ -48,6 +48,11 @@ Mod.solvers = {'indvel'}; % BEMT Solver ('leishman', 'indfact', 'indvel', 'sta
% Extensions/corrections
Mod.Ext.losses = 'all'; % Include losses using Prandtl formula ('none', 'hub', 'tip', 'both')
% [COAXIAL ONLY] Contraction model
Mod.coax.model = 'mst'; % Type of contraction ('none', 'sst', 'smst', 'mst')
Mod.coax.contraType = 'farfield'; % (opt) Type of contraction ('farfield', 'value')
Mod.coax.contraVal = 1 / 2; % (opt) Contraction ratio between upper disk and lower rotor, [-]
% Numerical parameters
Mod.Num.convCrit = 1e-4; % Convergence criterion value,
Mod.Num.maxIter = 500; % Maximum number of iterations for convergence calculations
......
......@@ -85,6 +85,11 @@ Mod.solvers = 'all'; % BEMT Solver ('leishman', 'indfact', 'indvel', 'stahlhut'
% Extensions/corrections
Mod.Ext.losses = 'none'; % Include losses using Prandtl formula ('none', 'hub', 'tip', 'both')
% [COAXIAL ONLY] Contraction model
Mod.coax.model = 'mst'; % Type of contraction ('none', 'sst', 'smst', 'mst')
Mod.coax.contraType = 'farfield'; % Type of contraction ('farfield', 'value')
Mod.coax.contraVal = 1 / 2; % (opt) Contraction ratio between upper disk and lower rotor, [-]
% Numerical parameters
Mod.Num.convCrit = 1e-4; % Convergence criterion value,
Mod.Num.maxIter = 500; % Maximum number of iterations for convergence calculations
......
......@@ -41,6 +41,7 @@ for i = 2:N_ROTORS
% ================================ Blade and rotor geometry ====================================
Blade(i) = Blade(1); % Make second rotor identical to first one
Blade(i).spinDir = -1 * Blade(i - 1).spinDir; % Invert spin direction for each rotor
Blade(i).nElem = round(Blade(i - 1).nElem * 1);
% Shift second rotor w.r.t the application type
if strcmp(Sim.Misc.appli, 'heli')
......
......@@ -39,7 +39,7 @@ function bemt(OpRot, Mod)
bemtsinglerot(OpRot(1), Mod);
for i = 2:length(OpRot)
OpRot(i).ElPerf.updateupstreamvel(OpRot(i - 1)); % Update upstream velocity
OpRot(i).ElPerf.updateupstreamvel(OpRot(i - 1), Mod); % Update upstream velocity
bemtsinglerot(OpRot(i), Mod); % Calculate BEMT as usual, with new upstream vel distribution
end
......
......@@ -74,6 +74,8 @@ function [Sim, Mod, Flow, Op, Airfoil, Blade] = validateconfig(configFile)
DEF.NONDIM = {'US', 'EU'};
DEF.VERBOSITY = {'min', 'all'};
DEF.SOLVERS = {'leishman', 'indfact', 'indvel', 'stahlhut', 'all'};
DEF.CONTRACTION_TYPE = {'farfield', 'value'};
DEF.CONTRACTION_MODEL = {'none', 'sst', 'smst', 'mst'};
DEF.FLUID = {'air', 'seawater', 'freshwater'};
DEF.LOSSES = {'none', 'hub', 'tip', 'both', 'all'};
DEF.POLARS = {'polynomial', 'file'};
......@@ -88,12 +90,12 @@ function [Sim, Mod, Flow, Op, Airfoil, Blade] = validateconfig(configFile)
% Input checks
Sim = checksim(Sim, configFile, DEF); % Simulation parameters
Mod = checkmod(Mod, configFile, DEF); % Models, solvers, etc.
Flow.fluid = validatestring(Flow.fluid, DEF.FLUID, configFile, 'Flow.fluid'); % Fluid
Airfoil = checkairfoil(Airfoil, configFile, DEF); % Airfoils data
Blade = checkblade(Blade, configFile, length(Airfoil), DEF); % Blade
Op = checkop(Op, configFile, DEF, numel(Blade), Flow.fluid); % Operating points
Mod = checkmod(Mod, configFile, numel(Blade), DEF); % Models, solvers, etc.
% ===========================================
% Extra warnings
......@@ -169,7 +171,7 @@ end
% ==================================================================================================
% ==================================== Models and solvers ==========================================
% ==================================================================================================
function Mod = checkmod(Mod, configFile, DEF)
function Mod = checkmod(Mod, configFile, nRotors, DEF)
% Solvers
Mod.solvers = cellstr(Mod.solvers);
......@@ -195,6 +197,21 @@ function Mod = checkmod(Mod, configFile, DEF)
{'scalar', 'positive'}, ...
configFile, 'Mod.Num.maxIter');
if nRotors > 1
Mod.coax.model = validatestring(Mod.coax.model, DEF.CONTRACTION_MODEL, ...
configFile, 'Mod.coax.model');
if ~strcmpi(Mod.coax.model, 'none')
Mod.coax.contraType = validatestring(Mod.coax.contraType, DEF.CONTRACTION_TYPE, ...
configFile, 'Mod.coax.contraType');
end
if strcmp(Mod.coax.contraType, 'value')
validateattributes(Mod.coax.contraVal, ...
{'double'}, ...
{'scalar', 'positive'}, ...
configFile, 'Mod.Num.convCrit');
end
end
end
% ==================================================================================================
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment