Skip to content

Commit 8ab5e87

Browse files
authored
Merge pull request #85 from byuflowlab/robust
minor naming convention change
2 parents 22a0d31 + ad9e092 commit 8ab5e87

File tree

12 files changed

+46
-25
lines changed

12 files changed

+46
-25
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
[![Code Style: Blue](https://img.shields.io/badge/code%20style-blue-4495d1.svg)](https://github.com/invenia/BlueStyle)
77

88
DuctAPE is a code for the aerodynamic evaluation of axisymmetric ducted rotors designed for incompressible (low mach) applications.
9-
It is strongly influenced by the underlying [theory](https://web.mit.edu/drela/Public/web/dfdc/DFDCtheory12-31.pdf) of Ducted Fan Design Code [(DFDC)](https://web.mit.edu/drela/Public/web/dfdc/), utilizing a linear axisymmetric vortex panel method for duct and center body, blade element lifting line rotor representation, and psuedo wake-screw wake model axisymmetrically smeared onto an elliptic grid for efficient computation.
9+
It is strongly influenced by the underlying [theory](https://web.mit.edu/drela/Public/web/dfdc/DFDCtheory12-31.pdf) of Ducted Fan Design Code [(DFDC)](https://web.mit.edu/drela/Public/web/dfdc/), utilizing a linear axisymmetric vortex panel method for duct and center body, blade element actuator line rotor representation, and psuedo wake-screw wake model axisymmetrically smeared onto an elliptic grid for efficient computation.
1010

1111
DuctAPE has been developed specifically for applications in gradient-based optimization settings. <!-- add citations later -->
1212
The default solver methods have been chosen to balance code efficiency as well as robustness while simultaneously allowing for efficient automatic differentiation through DuctAPE employing [ImplicitAD.jl](https://flow.byu.edu/ImplicitAD.jl/dev/).

docs/latex/model_validation.tex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ \subsection{Verification Compared to DFDC}
260260
\centering
261261
\tikzsetnextfilename{verification/verification_geometry}
262262
\input{figures/verification/verification_geometry.tikz}%\hspace*{5em}
263-
\caption{Single rotor verification case geometry generated by DuctAPE. Duct and center body geometry in \primary{blue}, rotor lifting line location in \secondary{red}, and approximate wake streamlines in \tertiary{green}, where markers indicate panel egdes.}
263+
\caption{Single rotor verification case geometry generated by DuctAPE. Duct and center body geometry in \primary{blue}, rotor actuator line location in \secondary{red}, and approximate wake streamlines in \tertiary{green}, where markers indicate panel egdes.}
264264
\label{fig:singlerotorgeom}
265265
\end{figure}
266266

docs/src/DuctAPE/theory_latex/ductape/vandv.tex

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ \subsection{Verification Against DFDC}
3232
\centering
3333
%\tikzsetnextfilename{verification/verification_geometry}
3434
\input{./ductape/figures/verification/verification_geometry.tikz}%\hspace*{5em}
35-
\caption[DuctAPE verification geometry.]{Single rotor verification case geometry generated in DuctAPE. Duct and center body geometry in blue, rotor lifting line location in red, and approximate wake streamlines in green, where markers indicate panel egdes.}
35+
\caption[DuctAPE verification geometry.]{Single rotor verification case geometry generated in DuctAPE. Duct and center body geometry in blue, rotor actuator line location in red, and approximate wake streamlines in green, where markers indicate panel egdes.}
3636
\label{fig:singlerotorgeom}
3737
\end{figure}
3838

@@ -129,7 +129,7 @@ \subsection{Validation with Experimental Data}
129129
\centering
130130
%\tikzsetnextfilename{validation/high_speed_validation_geometry}
131131
\setlength{\sidecapraise}{-2.5cm}
132-
\begin{sidecaption}[DuctAPE validation geometry.]{High-speed validation case geometry generated in DuctAPE. Duct and center body geometry in blue, rotor lifting line location in red, and approximate wake streamlines in green, where markers indicate panel edges.}[fig:highspeedgeom]
132+
\begin{sidecaption}[DuctAPE validation geometry.]{High-speed validation case geometry generated in DuctAPE. Duct and center body geometry in blue, rotor actuator line location in red, and approximate wake streamlines in green, where markers indicate panel edges.}[fig:highspeedgeom]
133133
\input{./ductape/figures/validation/high_speed_validation_geometry.tikz}%\hspace*{5em}
134134
\end{sidecaption}
135135
\vskip -3cm
@@ -140,15 +140,15 @@ \subsection{Validation with Experimental Data}
140140
% \centering
141141
% %\tikzsetnextfilename{validation/validation_geometry}
142142
% \input{ductape/figures/validation/validation_geometry.tikz}%\hspace*{5em}
143-
% \caption{Low-speed validation case geometry generated in DuctAPE. Duct and center body geometry in blue, rotor lifting line location in red, and approximate wake streamlines in green, where markers indicate panel edges.}
143+
% \caption{Low-speed validation case geometry generated in DuctAPE. Duct and center body geometry in blue, rotor actuator line location in red, and approximate wake streamlines in green, where markers indicate panel edges.}
144144
% \label{fig:lowspeedgeom}
145145
% \end{figure}
146146
%
147147
% \begin{figure}[h!]
148148
% \centering
149149
% %\tikzsetnextfilename{validation/reduced_exit_validation_geometry}
150150
% \input{ductape/figures/validation/reduced_exit_validation_geometry.tikz}%\hspace*{5em}
151-
% \caption{Validation case geometry generated in DuctAPE. Duct and center body geometry in blue, rotor lifting line location in red, and approximate wake streamlines in green, where markers indicate panel edges.}
151+
% \caption{Validation case geometry generated in DuctAPE. Duct and center body geometry in blue, rotor actuator line location in red, and approximate wake streamlines in green, where markers indicate panel edges.}
152152
% \label{fig:lowspeedgeom}
153153
% \end{figure}
154154

docs/src/DuctAPE/theory_latex/rotor_wake_method/figures/absolute_reference_frame.tikz

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
\draw[secondary, thick] (Orplus)-- (Orminus);
3232
\draw[-{Stealth[length=2pt,width=2pt]}, secondary, thick] (O)-- (Ozplus);
3333

34-
% blade lifting line
34+
% blade actuator line
3535
\coordinate (rhub) at (0.0,0.5);
3636
\coordinate (rtip) at (0.0,2.0);
3737
\draw[tertiary,ultra thick] (rhub) -- (rtip);
@@ -49,7 +49,7 @@
4949

5050
% circulations
5151

52-
% blade lifting line label
52+
% blade actuator line label
5353

5454
% blade circulations label
5555
\end{tikzpicture}

docs/src/DuctAPE/theory_latex/rotor_wake_method/referece_frames.tex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ \subsection{Absolute Frame}
4646
\centering
4747
\input{./rotor_wake_method/figures/absolute_reference_frame.tikz}
4848
% \includegraphics[width=\textwidth]{./rotor_wake_method/figures/duct_frame}
49-
\caption[Absolute reference frame.]{Meridional view showing the absolute reference frame. Example duct and center body geometry is shown in blue, the origin location is shown in red, and an example blade lifting line location is shown in green.}
49+
\caption[Absolute reference frame.]{Meridional view showing the absolute reference frame. Example duct and center body geometry is shown in blue, the origin location is shown in red, and an example blade actuator line location is shown in green.}
5050
\label{fig:absolutecoordinatesystem}
5151
\end{figure}
5252

@@ -64,7 +64,7 @@ \subsection{Relative Frame}
6464
%
6565
We can use this cascade view to understand the various velocity decompositions through which we can relate the absolute and relative reference frames.
6666
%
67-
The blade rotates in the positive \(\theta\) direction, and the \(m\) axis (where \(dm^2 = dz^2+dr^2\)) is along a streamline passing through the lifting line representing the blade.
67+
The blade rotates in the positive \(\theta\) direction, and the \(m\) axis (where \(dm^2 = dz^2+dr^2\)) is along a streamline passing through the actuator line representing the blade.
6868
%
6969
That is to say, the \(m\) axis is the meridional axis, which may or may not be orthogonal to \(r\) for a given blade element.
7070

docs/src/DuctAPE/theory_latex/rotor_wake_method/rotor_aero.tex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,12 +69,12 @@ \section{A Blade Element Model}
6969
\subsection{Blade Circulation}
7070
\label{ssec:bladecirculation}
7171

72-
To get circulation for each blade element, we treat the rotor blade as a lifting line and assume that:
72+
To get circulation for each blade element, we treat the rotor blade as an actuator line and assume that:
7373

7474
\begin{assumption}
7575
\label{asm:liftingline}
7676

77-
\asm{The rotor can reasonably be modeled as a lifting line such that local blade circulation can be expressed according to the Kutta-Joukowski theorem, which states:}
77+
\asm{The rotor can reasonably be modeled as an actuator line such that local blade circulation can be expressed according to the Kutta-Joukowski theorem, which states:}
7878

7979
\[ \vect{F} = \rho \vect{W} \times \vect{\Gamma} \]
8080

@@ -84,7 +84,7 @@ \subsection{Blade Circulation}
8484

8585
\end{assumption}
8686

87-
Modeling the rotor blades as lifting lines, if we take the velocity to be the local inflow velocity magnitude, \(W=\left[W_z^2+W_\theta^2\right]^{1/2}\) at the radial point of interest, we can take the perpendicular component of the force to be lift also at the radial point of interest.
87+
Modeling the rotor blades as actuator lines, if we take the velocity to be the local inflow velocity magnitude, \(W=\left[W_z^2+W_\theta^2\right]^{1/2}\) at the radial point of interest, we can take the perpendicular component of the force to be lift also at the radial point of interest.
8888
%
8989
We can then rearrange the expression for the Kutta-Joukowski theorem in \cref{asm:liftingline} for the local circulation magnitude, \(\Gamma(r)\), along the blade as
9090

docs/src/DuctAPE/theory_latex/rotor_wake_method/wake_aero.tex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ \subsection{Starting with a Standard Wake Screw}
9494

9595
\limit{This is a simplified modeling approach that ignores the some of the flow turning of the blade.}
9696

97-
\why{By using this lifting line approach rather than some other approach, such as a lifting surface, we (like many of our other assumptions) simplify the model, allowing for simpler implementation and faster computation.}
97+
\why{By using this actuator line approach rather than some other approach, such as a lifting surface, we (like many of our other assumptions) simplify the model, allowing for simpler implementation and faster computation.}
9898

9999
\end{assumption}
100100

@@ -160,7 +160,7 @@ \subsection{Starting with a Standard Wake Screw}
160160
%
161161
On the other hand, \(\gamma_\theta\) would only be generally applicable if we assumed that the \(\Omega r\) component of \(W_\theta\) (see \cref{eqn:relativevelocities}) was constant in the entire wake.
162162
%
163-
In actuality, we only know \(\Omega r\) right at the rotor lifting line, but not generally in the remainder of the wake.
163+
In actuality, we only know \(\Omega r\) right at the rotor actuator line, but not generally in the remainder of the wake.
164164
%
165165
We therefore want to develop a more general expression for \(\gamma_\theta\) based on requiring the wake to be force-free, or in other words, we demand static pressure continuity across the vortex sheets.
166166
%
@@ -790,7 +790,7 @@ \subsection{Piece 4: Disk and Sheet Jumps}
790790
\Delta h_{\text{disk}} = w_c = \Omega \Delta(r C_\theta).
791791
\end{equation}
792792

793-
\noindent We can relate the jump in enthalpy to the circulation by applying our lifting line assumption (\cref{asm:liftingline}),
793+
\noindent We can relate the jump in enthalpy to the circulation by applying our actuator line assumption (\cref{asm:liftingline}),
794794
which means that there is no radial deviation in flow across the blade, as well as substituting in for \(C_\theta\) from \cref{eqn:vtheta} (for a single disk).
795795

796796
% \begin{equation}

docs/src/DuctAPE/theory_latex/rotor_wake_method/wake_geometry.tex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ \section{A Streamlined Elliptic Grid}
1111
%
1212
By so doing, we complete a large portion of the computation related to the wake outside of the iterative solver, greatly reducing computational cost.
1313
%
14-
We utilize a method from \citeauthor{thompson_1974} to determine approximate streamline locations based on the duct and centerbody geometries and blade element positions along the rotor lifting line.
14+
We utilize a method from \citeauthor{thompson_1974} to determine approximate streamline locations based on the duct and centerbody geometries and blade element positions along the rotor actuator line.
1515

1616
In the method of \citeauthor{thompson_1974} a transformation is defined between rectangular and arbitrary shaped regions, with the arbitrary shaped region lying on a physical plane.\scite{thompson_1974}
1717
%
@@ -437,7 +437,7 @@ \subsection{Discretizing the Wake into Panels}
437437
% %
438438
% By Helmholtz` theorems, we cannot just have the vortex filaments of the wake (smeared or otherwise) simply end.
439439
% %
440-
% On the rotor blades, we have lines of circulation [(reference one of the figures)] from which the wake filaments are shed (as would be expected from a lifting line method).
440+
% On the rotor blades, we have lines of circulation [(reference one of the figures)] from which the wake filaments are shed (as would be expected from an actuator line method).
441441
% %
442442
% We have not, however, defined those shed wake filaments to be semi-infinite, but rather to be discretized into smeared vortex panels.
443443
% %

docs/src/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
[![Code Style: Blue](https://img.shields.io/badge/code%20style-blue-4495d1.svg)](https://github.com/invenia/BlueStyle)
77

88
DuctAPE is a code for the aerodynamic evaluation of axisymmetric ducted rotors designed for incompressible (low mach) applications.
9-
It is strongly influenced by the underlying [theory](https://web.mit.edu/drela/Public/web/dfdc/DFDCtheory12-31.pdf) of Ducted Fan Design Code [(DFDC)](https://web.mit.edu/drela/Public/web/dfdc/), utilizing a linear axisymmetric vortex panel method for duct and center body, blade element lifting line rotor representation, and psuedo wake-screw wake model axisymmetrically smeared onto an elliptic grid for efficient computation.
9+
It is strongly influenced by the underlying [theory](https://web.mit.edu/drela/Public/web/dfdc/DFDCtheory12-31.pdf) of Ducted Fan Design Code [(DFDC)](https://web.mit.edu/drela/Public/web/dfdc/), utilizing a linear axisymmetric vortex panel method for duct and center body, blade element actuator line rotor representation, and psuedo wake-screw wake model axisymmetrically smeared onto an elliptic grid for efficient computation.
1010

1111
DuctAPE has been developed specifically for applications in gradient-based optimization settings.
1212
The default solver methods have been chosen to balance code efficiency as well as robustness while simultaneously allowing for efficient automatic differentiation through DuctAPE employing [ImplicitAD.jl](https://flow.byu.edu/ImplicitAD.jl/dev/).

src/preprocess/geometry/body_geometry.jl

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,10 @@ function reinterpolate_bodies!(
8181

8282
# repaneled casing inlet nodes
8383
casing_inlet_z = scaled_cosine_spacing(
84-
num_duct_inlet_panels + 1, 2 * duct_inlet_length, duct_le_coordinates[1]; mypi=pi / 2.0
84+
num_duct_inlet_panels + 1,
85+
2 * duct_inlet_length,
86+
duct_le_coordinates[1];
87+
mypi=pi / 2.0,
8588
)
8689
casing_inlet_r = finterp(casing_z, casing_r, casing_inlet_z)
8790

@@ -98,7 +101,10 @@ function reinterpolate_bodies!(
98101

99102
# repaneled nacelle inlet nodes
100103
nacelle_inlet_z = scaled_cosine_spacing(
101-
num_duct_inlet_panels + 1, 2 * duct_inlet_length, duct_le_coordinates[1]; mypi=pi / 2.0
104+
num_duct_inlet_panels + 1,
105+
2 * duct_inlet_length,
106+
duct_le_coordinates[1];
107+
mypi=pi / 2.0,
102108
)
103109
nacelle_inlet_r = finterp(nacelle_z, nacelle_r, nacelle_inlet_z)
104110

@@ -114,11 +120,26 @@ function reinterpolate_bodies!(
114120

115121
center_body_inlet_length = center_body_in_wake_z[1] - center_body_z[1]
116122
center_body_inlet_z = scaled_cosine_spacing(
117-
num_center_body_inlet_panels + 1, 2 * center_body_inlet_length, center_body_z[1]; mypi=pi / 2.0
123+
num_center_body_inlet_panels + 1,
124+
2 * center_body_inlet_length,
125+
center_body_z[1];
126+
mypi=pi / 2.0,
118127
)
119128
center_body_inlet_r = finterp(center_body_z, center_body_r, center_body_inlet_z)
120129

121130
# assemble new duct coordinates
131+
132+
@assert (
133+
size(rp_duct_coordinates) == size(
134+
hcat(
135+
[reverse(casing_in_wake_z)'; reverse(casing_in_wake_r)'],
136+
[reverse(casing_inlet_z)[2:end]'; reverse(casing_inlet_r)[2:end]'],
137+
[nacelle_inlet_z[2:end]'; nacelle_inlet_r[2:end]'],
138+
[nacelle_in_wake_z[2:end]'; nacelle_in_wake_r[2:end]'],
139+
),
140+
)
141+
) "Duct Repaneling Error: check that the 'dte_minus_cbte' and `num_panels` inputs in the `paneling_constants` are correct"
142+
122143
rp_duct_coordinates .= hcat(
123144
[reverse(casing_in_wake_z)'; reverse(casing_in_wake_r)'],
124145
[reverse(casing_inlet_z)[2:end]'; reverse(casing_inlet_r)[2:end]'],

0 commit comments

Comments
 (0)