aerostructural.py

class openconcept.aerodynamics.openaerostruct.aerostructural.AerostructDragPolar(**kwargs)

Bases: Group

Drag polar and wing weight estimate generated using OpenAeroStruct’s aerostructural analysis capabilities and a surrogate model to decrease the computational cost.

This component cannot currently handle fuel loads on the wing, nor can it handle point loads applied to the structure.

Notes

The spanwise variables (twist, toverc, skin/spar thickness) are ordered starting at the tip and moving to the root; a twist of [-1, 0, 1] would have a tip twist of -1 deg and root twist of 1 deg

Set the OMP_NUM_THREADS environment variable to 1 for much better parallel training performance!

Inputs:
  • fltcond|CL (float) – Lift coefficient (vector, dimensionless)

  • fltcond|M (float) – Mach number (vector, dimensionless)

  • fltcond|h (float) – Altitude (vector, m)

  • fltcond|q (float) – Dynamic pressure (vector, Pascals)

  • ac|geom|wing|S_ref (float) – Full planform area (scalar, m^2)

  • ac|geom|wing|AR (float) – Aspect ratio (scalar, dimensionless)

  • ac|geom|wing|taper (float) – Taper ratio (must be >0 and <=1); tip chord / root chord (scalar, dimensionless)

  • ac|geom|wing|c4sweep (float) – Quarter chord sweep angle (scalar, degrees)

  • ac|geom|wing|twist (float) – List of twist angles at control points of spline (vector, degrees) NOTE: length of vector is num_twist (set in options), NOT num_nodes

  • ac|geom|wing|toverc (float) – List of thickness to chord ratios at control points of spline (vector, dimensionless) NOTE: length of vector is num_toverc (set in options)

  • ac|geom|wing|skin_thickness (float) – List of skin thicknesses at control points of spline (vector, m) NOTE: length of vector is num_skin (set in options)

  • ac|geom|wing|spar_thickness (float) – List of spar thicknesses at control points of spline (vector, m) NOTE: length of vector is num_spar (set in options)

  • ac|aero|CD_nonwing (float) – Drag coefficient of components other than the wing; e.g. fuselage, tail, interference drag, etc.; this value is simply added to the drag coefficient computed by OpenAeroStruct (scalar, dimensionless)

  • fltcond|TempIncrement (float) – Temperature increment for non-standard day (scalar, degC) NOTE: fltcond|TempIncrement is a scalar in this component but a vector in OC. This will be the case for the forseeable future because of the way the OASDataGen component is set up. To make it work, TempIncrement would need to be an input to the surrogate, which is not worth the extra training cost (at minimum a 2x increase).

Outputs:
  • drag (float) – Drag force (vector, Newtons)

  • failure (float) – KS aggregation quantity obtained by combining the failure criteria for each FEM node. Must be < 0 to constrain wingboxes stresses to be less than yield stress. Used to simplify the optimization problem by reducing the number of constraints (vector, dimensionless)

  • ac|weights|W_wing (float) – Weight of the wing (scalar, kg)

Options:
  • num_nodes (int) – Number of analysis points per mission segment (scalar, dimensionless)

  • num_x (int) – Number of panels in x (streamwise) direction (scalar, dimensionless)

  • num_y (int) – Number of panels in y (spanwise) direction for one wing because uses symmetry (scalar, dimensionless)

  • num_twist (int) – Number of spline control points for twist (scalar, dimensionless)

  • num_toverc (int) – Number of spline control points for thickness to chord ratio (scalar, dimensionless)

  • num_skin (int) – Number of spline control points for skin thickness (scalar, dimensionless)

  • num_spar (int) – Number of spline control points for spar thickness (scalar, dimensionless)

  • alpha_train (list or ndarray) – List of angle of attack values at which to train the model (ndarray, degrees)

  • Mach_train (list or ndarray) – List of Mach numbers at which to train the model (ndarray, dimensionless)

  • alt_train (list or ndarray) – List of altitude values at which to train the model (ndarray, m)

  • surf_options (dict) – Dictionary of OpenAeroStruct surface options; any options provided here will override the default ones; see the OpenAeroStruct documentation for more information. Because the geometry transformations are excluded in this model (to simplify the interface), the <transformation>_cp options are not supported. The input ac|geom|wing|twist is the same as modifying the twist_cp option in the surface dictionary. The mesh geometry modification is limited to adjusting the input parameters to this component.

class openconcept.aerodynamics.openaerostruct.aerostructural.OASDataGen(**kwargs)

Bases: ExplicitComponent

Generates a grid of OpenAeroStruct lift and drag data to train a surrogate model. The grid is defined by the options and the planform geometry by the inputs. This component will only recalculate the lift and drag grid when the planform shape changes.

Notes

The spanwise variables (twist, toverc, skin/spar thickness) are ordered starting at the tip and moving to the root; a twist of [-1, 0, 1] would have a tip twist of -1 deg and root twist of 1 deg

Inputs:
  • ac|geom|wing|S_ref (float) – Full planform area (scalar, m^2)

  • ac|geom|wing|AR (float) – Aspect ratio (scalar, dimensionless)

  • ac|geom|wing|taper (float) – Taper ratio (must be >0 and <=1); tip chord / root chord (scalar, dimensionless)

  • ac|geom|wing|c4sweep (float) – Quarter chord sweep angle (scalar, degrees)

  • ac|geom|wing|twist (float) – List of twist angles at control points of spline (vector, degrees) NOTE: length of vector is num_twist (set in options)

  • ac|geom|wing|toverc (float) – List of thickness to chord ratios at control points of spline (vector, dimensionless) NOTE: length of vector is num_toverc (set in options)

  • ac|geom|wing|skin_thickness (float) – List of skin thicknesses at control points of spline (vector, m) NOTE: length of vector is num_skin (set in options)

  • ac|geom|wing|spar_thickness (float) – List of spar thicknesses at control points of spline (vector, m) NOTE: length of vector is num_spar (set in options)

  • ac|aero|CD_nonwing (float) – Drag coefficient of components other than the wing; e.g. fuselage, tail, interference drag, etc.; this value is simply added to the drag coefficient computed by OpenAeroStruct (scalar, dimensionless)

  • fltcond|TempIncrement (float) – Temperature increment for non-standard day (scalar, degC)

Outputs:
  • CL_train (3-dim ndarray) – Grid of lift coefficient data to train structured surrogate model

  • CD_train (3-dim ndarray) – Grid of drag coefficient data to train structured surrogate model

  • failure_train (float) – Grid of KS structural failure constraint to train structured surrogate; constrain failure < 0

  • W_wing (float) – Wing structural weight (scalar, kg)

Options:
  • num_x (int) – Number of panels in x (streamwise) direction (scalar, dimensionless)

  • num_y (int) – Number of panels in y (spanwise) direction for one wing because uses symmetry (scalar, dimensionless)

  • num_twist (int) – Number of spline control points for twist (scalar, dimensionless)

  • num_toverc (int) – Number of spline control points for thickness to chord ratio (scalar, dimensionless)

  • num_skin (int) – Number of spline control points for skin thickness (scalar, dimensionless)

  • num_spar (int) – Number of spline control points for spar thickness (scalar, dimensionless)

  • Mach_train (list or ndarray) – List of Mach numbers at which to train the model (ndarray, dimensionless)

  • alpha_train (list or ndarray) – List of angle of attack values at which to train the model (ndarray, degrees)

  • alt_train (list or ndarray) – List of altitude values at which to train the model (ndarray, m)

  • surf_options (dict) – Dictionary of OpenAeroStruct surface options; any options provided here will override the default ones; see the OpenAeroStruct documentation for more information. Because the geometry transformations are excluded in this model (to simplify the interface), the <transformation>_cp options are not supported. The input ac|geom|wing|twist is the same as modifying the twist_cp option in the surface dictionary. The mesh geometry modification is limited to adjusting the input parameters to this component.

  • regen_tol (float) – Difference in input variable above which to regenerate the training data.

class openconcept.aerodynamics.openaerostruct.aerostructural.Aerostruct(**kwargs)

Bases: Group

Perform a coupled aerostructural analysis using OpenAeroStruct. This component currently does not support distributed fuel loads or point loads added to the structure.

Notes

The spanwise variables (twist, toverc, skin/spar thickness) are ordered starting at the tip and moving to the root; a twist of [-1, 0, 1] would have a tip twist of -1 deg and root twist of 1 deg

Inputs:
  • fltcond|alpha (float) – Angle of attack (scalar, degrees)

  • fltcond|M (float) – Mach number (scalar, dimensionless)

  • fltcond|h (float) – Altitude (scalar, m)

  • fltcond|TempIncrement (float) – Temperature increment for non-standard day (scalar, degC)

  • ac|geom|wing|S_ref (float) – Wing planform area (scalar, m^2)

  • ac|geom|wing|AR (float) – Wing aspect ratio (scalar, dimensionless)

  • ac|geom|wing|taper (float) – Wing taper ratio (scalar, dimensionless)

  • ac|geom|wing|c4sweep (float) – Wing sweep measured at quarter chord (scalar, degrees)

  • ac|geom|wing|twist (float) – List of twist angles at control points of spline (vector, degrees) NOTE: length of vector is num_twist (set in options)

  • ac|geom|wing|toverc (float) – List of thickness to chord ratios at control points of spline (vector, dimensionless) NOTE: length of vector is num_toverc (set in options)

  • ac|geom|wing|skin_thickness (float) – List of skin thicknesses at control points of spline (vector, m) NOTE: length of vector is num_skin (set in options)

  • ac|geom|wing|spar_thickness (float) – List of spar thicknesses at control points of spline (vector, m) NOTE: length of vector is num_spar (set in options)

Outputs:
  • fltcond|CL (float) – Lift coefficient of wing (scalar, dimensionless)

  • fltcond|CD (float) – Drag coefficient of wing (scalar, dimensionless)

  • failure (float) – KS structural failure constraint; constrain failure < 0 (scalar, dimensionless)

  • ac|weights|W_wing (float) – Wing structural weight (scalar, kg)

Options:
  • num_x (int) – Number of panels in x (streamwise) direction (scalar, dimensionless)

  • num_y (int) – Number of panels in y (spanwise) direction for one wing because uses symmetry (scalar, dimensionless)

  • num_twist (int) – Number of spline control points for twist (scalar, dimensionless)

  • num_toverc (int) – Number of spline control points for thickness to chord ratio (scalar, dimensionless)

  • num_skin (int) – Number of spline control points for skin thickness (scalar, dimensionless)

  • num_spar (int) – Number of spline control points for spar thickness (scalar, dimensionless)

  • surf_options (dict) – Dictionary of OpenAeroStruct surface options; any options provided here will override the default ones; see the OpenAeroStruct documentation for more information. Because the geometry transformations are excluded in this model (to simplify the interface), the <transformation>_cp options are not supported. The input ac|geom|wing|twist is the same as modifying the twist_cp option in the surface dictionary. The mesh geometry modification is limited to adjusting the input parameters to this component.

class openconcept.aerodynamics.openaerostruct.aerostructural.AerostructDragPolarExact(**kwargs)

Bases: Group

Warning

This component is far more computationally expensive than the AerostructDragPolar component, which uses a surrogate. For missions with many flight segments, many num_nodes, or wing models with high num_x and num_y values this component will result in a system that returns a memory error when solved with a DirectSolver linear solver because the Jacobian is too large to be factorized. Unless you know what you’re doing, this component should not be used (use AerostructDragPolar instead).

Drag polar and wing weight estimate generated using OpenAeroStruct’s aerostructural analysis capabilities directly, without a surrogate in the loop.

Inputs:
  • fltcond|CL (float) – Lift coefficient (vector, dimensionless)

  • fltcond|M (float) – Mach number (vector, dimensionless)

  • fltcond|h (float) – Altitude (vector, m)

  • fltcond|q (float) – Dynamic pressure (vector, Pascals)

  • ac|geom|wing|S_ref (float) – Full planform area (scalar, m^2)

  • ac|geom|wing|AR (float) – Aspect ratio (scalar, dimensionless)

  • ac|geom|wing|taper (float) – Taper ratio (must be >0 and <=1); tip chord / root chord (scalar, dimensionless)

  • ac|geom|wing|c4sweep (float) – Quarter chord sweep angle (scalar, degrees)

  • ac|geom|wing|twist (float) – List of twist angles at control points of spline (vector, degrees) NOTE: length of vector is num_twist (set in options), NOT num_nodes

  • ac|geom|wing|toverc (float) – List of thickness to chord ratios at control points of spline (vector, dimensionless) NOTE: length of vector is num_toverc (set in options)

  • ac|geom|wing|skin_thickness (float) – List of skin thicknesses at control points of spline (vector, m) NOTE: length of vector is num_skin (set in options)

  • ac|geom|wing|spar_thickness (float) – List of spar thicknesses at control points of spline (vector, m) NOTE: length of vector is num_spar (set in options)

  • ac|aero|CD_nonwing (float) – Drag coefficient of components other than the wing; e.g. fuselage, tail, interference drag, etc.; this value is simply added to the drag coefficient computed by OpenAeroStruct (scalar, dimensionless)

  • fltcond|TempIncrement (float) – Temperature increment for non-standard day (scalar, degC) NOTE: fltcond|TempIncrement is a scalar in this component but a vector in OC. This will be the case for the forseeable future because of the way the OASDataGen component is set up. To make it work, TempIncrement would need to be an input to the surrogate, which is not worth the extra training cost (at minimum a 2x increase).

Outputs:
  • drag (float) – Drag force (vector, Newtons)

  • failure (float) – KS aggregation quantity obtained by combining the failure criteria for each FEM node. Must be < 0 to constrain wingboxes stresses to be less than yield stress. Used to simplify the optimization problem by reducing the number of constraints (vector, dimensionless)

  • ac|weights|W_wing (float) – Weight of the wing (scalar, kg)

Options:
  • num_nodes (int) – Number of analysis points per mission segment (scalar, dimensionless)

  • num_x (int) – Number of panels in x (streamwise) direction (scalar, dimensionless)

  • num_y (int) – Number of panels in y (spanwise) direction for one wing because uses symmetry (scalar, dimensionless)

  • num_twist (int) – Number of spline control points for twist (scalar, dimensionless)

  • num_toverc (int) – Number of spline control points for thickness to chord ratio (scalar, dimensionless)

  • num_skin (int) – Number of spline control points for skin thickness (scalar, dimensionless)

  • num_spar (int) – Number of spline control points for spar thickness (scalar, dimensionless)

  • surf_options (dict) – Dictionary of OpenAeroStruct surface options; any options provided here will override the default ones; see the OpenAeroStruct documentation for more information. Because the geometry transformations are excluded in this model (to simplify the interface), the <transformation>_cp options are not supported. The input ac|geom|wing|twist is the same as modifying the twist_cp option in the surface dictionary. The mesh geometry modification is limited to adjusting the input parameters to this component.