Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
M
MSA Toolkit
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Aerodynamics and Flight Dynamics
Mission Analysis
MSA Toolkit
Commits
4725f94d
Commit
4725f94d
authored
1 month ago
by
Marco Luigi Gaibotti
Browse files
Options
Downloads
Patches
Plain Diff
[alpha-phi][Automatrices] Added option to override saveVars and computeHighAOA as argument
parent
9d0cd8a5
Branches
alpha-phi
No related tags found
1 merge request
!19
Draft: Implementation of Alpha phi
Pipeline
#11402
failed
1 month ago
Changes
3
Pipelines
2
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
autoMatricesProtub/autoMatProtubConfig.m
+7
-2
7 additions, 2 deletions
autoMatricesProtub/autoMatProtubConfig.m
autoMatricesProtub/mainAutoMatProtub.m
+10
-7
10 additions, 7 deletions
autoMatricesProtub/mainAutoMatProtub.m
common
+1
-1
1 addition, 1 deletion
common
with
18 additions
and
10 deletions
autoMatricesProtub/autoMatProtubConfig.m
+
7
−
2
View file @
4725f94d
...
@@ -22,11 +22,15 @@ set(groot,'defaultAxesTickLabelInterpreter','latex');
...
@@ -22,11 +22,15 @@ set(groot,'defaultAxesTickLabelInterpreter','latex');
set
(
groot
,
'defaulttextinterpreter'
,
'latex'
);
set
(
groot
,
'defaulttextinterpreter'
,
'latex'
);
set
(
groot
,
'defaultLegendInterpreter'
,
'latex'
);
set
(
groot
,
'defaultLegendInterpreter'
,
'latex'
);
flags
.
saveVars
=
true
;
flags
.
computeHighAOA
=
false
;
%% STATES
%% STATES
% State values in which the aerodynamic coefficients will be computed
% State values in which the aerodynamic coefficients will be computed
vars
.
mach
=
0.05
:
0.05
:
1
;
vars
.
mach
=
0.05
:
0.05
:
1
;
vars
.
alpha
=
[
-
22
-
15
-
10
-
7.5
-
5
-
2.5
-
1
-
0.5
-
0.1
0
0.1
0.5
1
2.5
5
7.5
10
15
22
];
vars
.
alpha
=
[
0
0.1
0.5
1
2.5
5
7.5
10
15
22
35
60
90.1
115
130
170
];
vars
.
beta
=
[
-
13
-
8
-
5
-
2.5
-
0.1
0
0.1
2.5
5
8
13
];
vars
.
beta
=
[];
vars
.
phi
=
[
0
:
12
:
120
];
vars
.
alt
=
(
0
:
400
:
4000
);
% above local ground (env.z0 will be added in main)
vars
.
alt
=
(
0
:
400
:
4000
);
% above local ground (env.z0 will be added in main)
% xcg discretization
% xcg discretization
...
@@ -36,6 +40,7 @@ vars.Nxcg = 3; % Number of wanted xcgs in order to generate N
...
@@ -36,6 +40,7 @@ vars.Nxcg = 3; % Number of wanted xcgs in order to generate N
varsHighAOA
.
mach
=
0.05
:
0.05
:
0.7
;
varsHighAOA
.
mach
=
0.05
:
0.05
:
0.7
;
varsHighAOA
.
alpha
=
[
-
170
-
130
-
115
-
90.1
-
60
-
35
-
10
-
5
-
1
0
1
5
10
35
60
90.1
115
130
170
];
varsHighAOA
.
alpha
=
[
-
170
-
130
-
115
-
90.1
-
60
-
35
-
10
-
5
-
1
0
1
5
10
35
60
90.1
115
130
170
];
varsHighAOA
.
beta
=
[
-
170
-
130
-
115
-
90.1
-
60
-
35
-
10
-
5
-
1
0
1
5
10
35
60
90.1
115
130
170
];
varsHighAOA
.
beta
=
[
-
170
-
130
-
115
-
90.1
-
60
-
35
-
10
-
5
-
1
0
1
5
10
35
60
90.1
115
130
170
];
varsHighAOA
.
phi
=
[];
varsHighAOA
.
alt
=
(
0
:
400
:
4000
);
% above local ground (env.z0 will be added in main)
varsHighAOA
.
alt
=
(
0
:
400
:
4000
);
% above local ground (env.z0 will be added in main)
%% FINS CN partial output
%% FINS CN partial output
...
...
This diff is collapsed.
Click to expand it.
autoMatricesProtub/mainAutoMatProtub.m
+
10
−
7
View file @
4725f94d
...
@@ -3,7 +3,8 @@ arguments
...
@@ -3,7 +3,8 @@ arguments
rocket
=
[];
% Empty by default
rocket
=
[];
% Empty by default
environment
Environment
=
Environment
.
empty
environment
Environment
=
Environment
.
empty
settings
Settings
=
Settings
.
empty
settings
Settings
=
Settings
.
empty
options
.
saveVars
logical
=
true
options
.
saveVars
logical
=
[]
options
.
computeHighAOA
=
[]
end
end
%% PATH
%% PATH
currentPath
=
fileparts
(
mfilename
(
"fullpath"
));
currentPath
=
fileparts
(
mfilename
(
"fullpath"
));
...
@@ -19,6 +20,8 @@ if isempty(rocket), rocket = Rocket(mission, [], "loadCoefficients", false); end
...
@@ -19,6 +20,8 @@ if isempty(rocket), rocket = Rocket(mission, [], "loadCoefficients", false); end
if
isempty
(
environment
),
environment
=
Environment
(
mission
,
rocket
.
motor
);
end
if
isempty
(
environment
),
environment
=
Environment
(
mission
,
rocket
.
motor
);
end
if
isempty
(
settings
),
autoMatSettings
=
Settings
(
'autoMatProtub'
);
end
if
isempty
(
settings
),
autoMatSettings
=
Settings
(
'autoMatProtub'
);
end
Settings
.
read
(
autoMatSettings
,
options
,
'flags'
);
%% FINALIZE CONFIG (with data not directly editable)
%% FINALIZE CONFIG (with data not directly editable)
% correcting altitudes
% correcting altitudes
autoMatSettings
.
vars
.
alt
=
autoMatSettings
.
vars
.
alt
+
environment
.
z0
;
autoMatSettings
.
vars
.
alt
=
autoMatSettings
.
vars
.
alt
+
environment
.
z0
;
...
@@ -88,11 +91,11 @@ input = createDissileInput(rocket, autoMatSettings.vars);
...
@@ -88,11 +91,11 @@ input = createDissileInput(rocket, autoMatSettings.vars);
coeffsOut
=
exportVars
(
...
coeffsOut
=
exportVars
(
...
autoMatSettings
.
vars
,
rocket
,
mission
,
coeffsTot
,
finsCN
,
chosenXcg
,
...
autoMatSettings
.
vars
,
rocket
,
mission
,
coeffsTot
,
finsCN
,
chosenXcg
,
...
autoMatSettings
.
saveFinsCN
,
option
s
.
saveVars
,
'aeroCoefficients.mat'
);
autoMatSettings
.
saveFinsCN
,
autoMatSettings
.
flag
s
.
saveVars
,
'aeroCoefficients.mat'
);
%% COMPUTE AND EXPORT HIGH AOA AERODYNAMIC COEFFICIENTS
%% COMPUTE AND EXPORT HIGH AOA AERODYNAMIC COEFFICIENTS
coeffsOutHighAOA
=
[]
;
coeffsOutHighAOA
=
Coefficient
()
;
if
autoMatSettings
.
computeHighAOA
if
autoMatSettings
.
flags
.
computeHighAOA
fprintf
(
'Generating new coefficients: High AoA...\n'
);
fprintf
(
'Generating new coefficients: High AoA...\n'
);
autoMatSettings
.
varsHighAOA
.
xcg
=
rocket
.
xcg
(
end
);
autoMatSettings
.
varsHighAOA
.
xcg
=
rocket
.
xcg
(
end
);
if
length
(
autoMatSettings
.
varsHighAOA
.
alpha
)
>
20
||
...
if
length
(
autoMatSettings
.
varsHighAOA
.
alpha
)
>
20
||
...
...
@@ -106,7 +109,7 @@ if autoMatSettings.computeHighAOA
...
@@ -106,7 +109,7 @@ if autoMatSettings.computeHighAOA
coeffsOutHighAOA
=
exportVars
(
...
coeffsOutHighAOA
=
exportVars
(
...
autoMatSettings
.
varsHighAOA
,
rocket
,
mission
,
coeffsTotHighAOA
,
finsCNHighAOA
,
chosenXcg
,
...
autoMatSettings
.
varsHighAOA
,
rocket
,
mission
,
coeffsTotHighAOA
,
finsCNHighAOA
,
chosenXcg
,
...
autoMatSettings
.
saveFinsCN
,
option
s
.
saveVars
,
'aeroCoefficientsHighAOA.mat'
);
autoMatSettings
.
saveFinsCN
,
autoMatSettings
.
flag
s
.
saveVars
,
'aeroCoefficientsHighAOA.mat'
);
end
end
AMtime
=
toc
;
AMtime
=
toc
;
...
...
This diff is collapsed.
Click to expand it.
common
@
01ad3737
Compare
1bc8c371
...
01ad3737
Subproject commit
1bc8c371f3852dab849aa6db901c8f275dfe025f
Subproject commit
01ad37374e485282e37e3e35917d233f22e6bc53
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment