geometry¶
class description¶
-
class
geometry.
Geometry
(**kwargs)[source]¶ Bases:
openmdao.core.explicitcomponent.ExplicitComponent
Compute geometrical parameters and ambient parameters along the trajectory.
The Geometry component requires the following inputs:
inputs['x']
: aircraft x-position [m]inputs['y']
: aircraft y-position [m]inputs['z']
: aircraft z-position [m]inputs['alpha']
: aircraft angle of attack [deg]inputs['gamma']
: aircraft climb angle [deg]inputs['c_0']
: ambient speed of sound [m/s]inputs['T_0']
: ambient temperature [K]inputs['t_s']
: source time [s]
The Geometry component computes the following outputs:
outputs['r']
: distance source to observer [m]outputs['theta']
: polar directivity angle [deg]outputs['phi']
: azimuthal directivity angle [deg]outputs['beta']
: elevation angle [deg]outputs['t_o']
: observer time [s]outputs['c_bar']
: average speed of sound between source and observer [m/s]
The Geometry component has the following options :
settings
: pyna settingsn_t
: number of time steps in the noise time seriesmode
: mode for geometry calculations: “time_series” / “distribution”
-
compute
(inputs: openmdao.vectors.default_vector.DefaultVector, outputs: openmdao.vectors.default_vector.DefaultVector)[source]¶ Compute outputs given inputs. The model is assumed to be in an unscaled state.
- Parameters
inputs (Vector) – Unscaled, dimensional input variables read via inputs[key].
outputs (Vector) – Unscaled, dimensional output variables read via outputs[key].
discrete_inputs (dict or None) – If not None, dict containing discrete input values.
discrete_outputs (dict or None) – If not None, dict containing discrete output values.
Warning
The Julia version of the Geometry component, geometry.jl
, is not documented yet. However, it is very similar to the Python version, geometry.py
. More information and examples on how OpenMDAO.jl components work can be found here.
theory¶
Given the aircraft position along the flight trajectory as a function of source time, i.e. \((x,y,z)(t_{s})\), the direction between the source and observer, \(\overrightarrow{r} = [x_{obs,x}, x_{obs,y}, -x_{obs,z}]^T-[x,y,-z]^T\), with magnitude \(r = || \overrightarrow{r} ||\). The normalized direction vector \(n_{so} = \frac{\overrightarrow{r}}{r}\). The elevation angle is given by:
Euler transformation angles are used to change the normalized source-observer vector from the Earth-fixed axis system to the aircraft-fixed axis system:
where \(\mathcal{T}_i\) is the Euler transformation matrix around the i-th axis. For straight, horizontal flight, the angles \(\Phi_B, \Psi_B = 0\) and \(\Theta_B = \alpha + \gamma\). The polar and azimuthal directivity angles are given by:
The average speed of sound between the source and the observer, \(\bar{c}\), is computed taking a numerical average of the speed of sound, \(c_0\), at 11 intermediate altitudes \(z_{intermediate}\) (including the endpoints). Finally, the observer time at each \(t_{o,i}\) is calculated using: