aerodynamic_coefficients
#
This module contains the factory functions for setting up the aerodynamic interface of artificial and celestial bodies in an environment.
Functions#

Factory function for creating aerodynamic interface model settings entirely from constant coefficients. 
Factory function for creating aerodynamic interface model settings from custom coefficients. 

Factory function for creating aerodynamic interface model settings from custom coefficients. 


Factory function for creating aerodynamic interface model settings from userdefined, 1d tabulated coefficients. 

Factory function for creating aerodynamic interface model settings from userdefined, 1d tabulated force coefficients. 
Factory function for creating aerodynamic interface model settings from tabulated force coefficients from files. 


Factory function for creating aerodynamic interface model settings from tabulated coefficients from files. 

Factory function for creating aerodynamic interface model settings by applying one constant scaling factor/value to all coefficients of an existing model settings object. 

Factory function for creating aerodynamic interface model settings by applying constant scaling factors/values to the coefficients of an existing model settings object. 

Factory function for creating aerodynamic interface model settings by applying custom scaling factors/values to the coefficients of an existing model settings object. 
Factory function for creating control surface aerodynamic model settings from custom coefficients. 

Factory function for creating control surface aerodynamic model settings from tabulated coefficients from files. 
 constant(reference_area: float, constant_force_coefficient: numpy.ndarray[numpy.float64[3, 1]], force_coefficients_frame: tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientFrames = <AerodynamicCoefficientFrames.negative_aerodynamic_frame_coefficients: 2>) tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings #
Factory function for creating aerodynamic interface model settings entirely from constant coefficients.
Factory function for settings object, defining aerodynamic interface model entirely from constant aerodynamic coefficients, i.e. coefficients are not a function of any independent variables.
 Parameters:
reference_area (float) – Reference area with which aerodynamic forces and moments are nondimensionalized.
constant_force_coefficient (numpy.ndarray) – Constant force coefficients.
force_coefficients_frame (AerodynamicCoefficientFrames, default = negative_aerodynamic_frame_coefficients) – Variable defining the frame in which the force coefficients are defined. By default, this is the negative aerodynamic frame, so that the coefficients are for drag, side force and lift
 Returns:
Instance of the
AerodynamicCoefficientSettings
derivedConstantAerodynamicCoefficientSettings
class Return type:
Examples
In this example, we create
AerodynamicCoefficientSettings
for the artificial body “Vehicle”, using only constant aerodynamic coefficients:# Define the reference area and constant aerodynamic coefficients reference_area = 20.0 drag_coefficient = 1.5 lift_coefficient = 0.3 # Create the aerodynamic interface settings aero_coefficient_settings = environment_setup.aerodynamic_coefficients.constant( reference_area, constant_force_coefficient=[drag_coefficient, 0, lift_coefficient], force_coefficients_frame=environment.negative_aerodynamic_frame_coefficients, ) # Assign aerodynamic interface to the vehicle environment_setup.add_aerodynamic_coefficient_interface(bodies, "Vehicle", aero_coefficient_settings)
 custom_aerodynamic_force_coefficients(force_coefficient_function: Callable[[list[float]], numpy.ndarray[numpy.float64[3, 1]]], reference_area: float, independent_variable_names: list[tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientsIndependentVariables], force_coefficients_frame: tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientFrames = <AerodynamicCoefficientFrames.negative_aerodynamic_frame_coefficients: 2>) tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings #
Factory function for creating aerodynamic interface model settings from custom coefficients.
Factory function for settings object, defining aerodynamic interface model via a custom force coefficient function (function of independent variable).
 Parameters:
force_coefficient_function (callable[[list[float]], numpy.ndarray[numpy.float64[3, 1]]]) – Function that is defining the aerodynamic coefficients as function of an independent variable (see arg independent_variable_names).
reference_area (float) – Reference area with which aerodynamic forces and moments are nondimensionalized.
independent_variable_name (list[environment.AerodynamicCoefficientsIndependentVariables]) – Vector with identifiers for the independent variable w.r.t. which the aerodynamic coefficients are defined.
force_coefficients_frame (AerodynamicCoefficientFrames, default = negative_aerodynamic_frame_coefficients) – Variable defining the frame in which the force coefficients are defined. By default, this is the negative aerodynamic frame, so that the coefficients are for drag, side force and lift (\(C_{D}, C_{S}, C_{L}\))
 Returns:
Instance of the
AerodynamicCoefficientSettings
derivedCustomAerodynamicCoefficientSettings
class Return type:
CustomAerodynamicCoefficientSettings
Examples
In this example, we create
AerodynamicCoefficientSettings
for the artificial body “Vehicle”, using a function based on the mach number:def force_coefficients(variables_list): # Extract the mach number mach_number = variables_list[0] # If the mach number is below 3, use fixed coefficients if mach_number <= 3: return [0.99, 0, 1.08] # Same if the mach number is above 10 elif mach_number >= 10: return [0.82, 0, 0.88] # Otherwise, vary linearly between the ones at M=3 and M=10 CD = 1.06670.02457*mach_number CL = 1.16360.02786*mach_number return [CD, 0, CL] # Create the aerodynamic interface settings aero_coefficient_settings = environment_setup.aerodynamic_coefficients.custom( force_coefficients, reference_area=1.50, independent_variable_names=[environment.AerodynamicCoefficientsIndependentVariables.mach_number_dependent] ) # Assign the aerodynamic coefficient interface to the vehicle environment_setup.add_aerodynamic_coefficient_interface(bodies, "Vehicle", aero_coefficient_settings)
 custom_aerodynamic_force_and_moment_coefficients(force_coefficient_function: Callable[[list[float]], numpy.ndarray[numpy.float64[3, 1]]], moment_coefficient_function: Callable[[list[float]], numpy.ndarray[numpy.float64[3, 1]]], reference_length: float, reference_area: float, independent_variable_names: list[tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientsIndependentVariables], force_coefficients_frame: tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientFrames = <AerodynamicCoefficientFrames.negative_aerodynamic_frame_coefficients: 2>, moment_coefficients_frame: tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientFrames = <AerodynamicCoefficientFrames.positive_body_fixed_frame_coefficients: 0>, moment_reference_point: numpy.ndarray[numpy.float64[3, 1]] = array([nan, nan, nan])) tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings #
Factory function for creating aerodynamic interface model settings from custom coefficients.
Factory function for settings object, defining aerodynamic interface model via a custom force and moment coefficient function (function of independent variable).
 Parameters:
force_coefficient_function (callable[[list[float]], numpy.ndarray[numpy.float64[3, 1]]]) – Function that is defining the aerodynamic force coefficients as function of an independent variable (see arg independent_variable_names).
moment_coefficient_function (callable[[list[float]], numpy.ndarray[numpy.float64[3, 1]]]) – Function that is defining the aerodynamic moment coefficients as function of an independent variable (see arg independent_variable_names).
reference_area (float) – Reference area with which aerodynamic forces and moments are nondimensionalized.
reference_length (float) – Reference length with which aerodynamic moments are nondimensionalized.
independent_variable_name (list[environment.AerodynamicCoefficientsIndependentVariables]) – Vector with identifiers for the independent variable w.r.t. which the aerodynamic coefficients are defined.
force_coefficients_frame (AerodynamicCoefficientFrames, default = negative_aerodynamic_frame_coefficients) – Variable defining the frame in which the force coefficients are defined. By default, this is the negative aerodynamic frame, so that the coefficients are for drag, side force and lift (\(C_{D}, C_{S}, C_{L}\))
moment_coefficients_frame (AerodynamicCoefficientFrames, default = positive_body_frame_coefficients) – Variable defining the frame in which the moment coefficients are defined. By default, this is the positive body frame, so that the coefficients are roll, pitch and yaw (\(C_{l}, C_{m}, C_{n}\))
moment_reference_point (numpy.ndarray[numpy.float64[3, 1]] = np.full([3, 1], np.nan)) – Point w.r.t. aerodynamic moment coefficients are defined. This variable is used to calculate the contribution of the aerodynamic force coefficients to the effective moment coefficients. See the
add_force_contribution_to_moments
attribute of theAerodynamicCoefficientSettings
for more details. If the present input is set to NaN (as is the default), the reference point is left undefined, and the aerodynamic moments are computed without computing any force coefficient contribution to the moment coefficients.
 Returns:
Instance of the
AerodynamicCoefficientSettings
derivedCustomAerodynamicCoefficientSettings
class Return type:
CustomAerodynamicCoefficientSettings
 tabulated(independent_variables: list[float], force_coefficients: list[numpy.ndarray[numpy.float64[3, 1]]], moment_coefficients: list[numpy.ndarray[numpy.float64[3, 1]]], reference_length: float, reference_area: float, independent_variable_name: tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientsIndependentVariables, force_coefficients_frame: tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientFrames = <AerodynamicCoefficientFrames.negative_aerodynamic_frame_coefficients: 2>, moment_coefficients_frame: tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientFrames = <AerodynamicCoefficientFrames.positive_body_fixed_frame_coefficients: 0>, moment_reference_point: numpy.ndarray[numpy.float64[3, 1]] = array([nan, nan, nan]), interpolator_settings: tudatpy.kernel.math.interpolators.InterpolatorSettings = None) tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings #
Factory function for creating aerodynamic interface model settings from userdefined, 1d tabulated coefficients.
Factory function for settings object, defining aerodynamic interface model via userdefined, 1dimensional, tabulated aerodynamic force and moment coefficients (tabulated w.r.t. independent variable).
 Parameters:
independent_variables (list[float]) – Values of independent variables at which the coefficients in the input multi vector are defined (size 1).
force_coefficients (list[numpy.ndarray[numpy.float64[3, 1]]]) – Values of force coefficients at independent variables defined by independent_variables.
moment_coefficients (list[numpy.ndarray[numpy.float64[3, 1]]]) – Values of moment coefficients at independent variables defined by independent_variables.
reference_length (float) – Reference length with which aerodynamic moments about x and z axes are nondimensionalized.
reference_area (float) – Reference area with which aerodynamic forces and moments are nondimensionalized.
independent_variable_name (list[environment.AerodynamicCoefficientsIndependentVariables]) – Vector with identifiers for the independent variable w.r.t. which the aerodynamic coefficients are defined.
force_coefficients_frame (AerodynamicCoefficientFrames, default = negative_aerodynamic_frame_coefficients) – Variable defining the frame in which the force coefficients are defined. By default, this is the negative aerodynamic frame, so that the coefficients are for drag, side force and lift (\(C_{D}, C_{S}, C_{L}\))
moment_coefficients_frame (AerodynamicCoefficientFrames, default = positive_body_frame_coefficients) – Variable defining the frame in which the moment coefficients are defined. By default, this is the positive body frame, so that the coefficients are roll, pitch yaw (\(C_{l}, C_{m}, C_{n}\))
moment_reference_point (numpy.ndarray[numpy.float64[3, 1]] = np.full([3, 1], np.nan)) – Point w.r.t. aerodynamic moment coefficients are defined. This variable is used to calculate the contribution of the aerodynamic force coefficients to the effective moment coefficients. See the
add_force_contribution_to_moments
attribute of theAerodynamicCoefficientSettings
for more details. If the present input is set to NaN (as is the default), the reference point is left undefined, and the aerodynamic moments are computed without computing any force coefficient contribution to the moment coefficients.interpolator_settings (math.interpolators.InterpolatorSettings, default = None) – Interpolator settings object, where the conditions for interpolation of tabulated inputs are saved.
 Returns:
Instance of the
AerodynamicCoefficientSettings
derivedTabulatedAerodynamicCoefficientSettings
class (viaTabulatedAerodynamicCoefficientSettingsBase
class) Return type:
TabulatedAerodynamicCoefficientSettings
Examples
In this example, aerodynamic force and moment coefficients are defined as multidimensional arrays. The values for the aerodynamic coefficients vary with Mach number, and are defined for Mach numbers of 3, 5, 10, and 15. This example also shows how to set the required reference point, lengths, and area.
# Define the aerodynamic force coefficients [CD, CS, CL] for different mach numbers aero_coefficients_array_force = [ [0.7647, 0, 0.9722], [0.6729, 0, 0.8461], [0.6240, 0, 0.7838], [0.6246, 0, 0.7841] ] # Define the aerodynamic moment coefficients for different mach numbers aero_coefficients_array_moment = [ [0.45, 0, 0], [0.50, 0, 0], [0.53, 0, 0], [0.55, 0, 0] ] # Create the aerodynamic interface settings aero_coefficient_settings = environment_setup.aerodynamic_coefficients.tabulated( independent_variables=[3, 5, 10, 15], # Mach number at which the coefficients are defined force_coefficients=aero_coefficients_array_force, moment_coefficients=aero_coefficients_array_moment, reference_length=0.25, reference_area=1.50, independent_variable_name=environment.AerodynamicCoefficientsIndependentVariables.mach_number_dependent ) # Assign the aerodynamic coefficient interface to the vehicle environment_setup.add_aerodynamic_coefficient_interface(bodies, "Vehicle", aero_coefficient_settings)
 tabulated_force_only(independent_variables: list[float], force_coefficients: list[numpy.ndarray[numpy.float64[3, 1]]], reference_area: float, independent_variable_name: tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientsIndependentVariables, force_coefficients_frame: tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientFrames = <AerodynamicCoefficientFrames.negative_aerodynamic_frame_coefficients: 2>, interpolator_settings: tudatpy.kernel.math.interpolators.InterpolatorSettings = None) tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings #
Factory function for creating aerodynamic interface model settings from userdefined, 1d tabulated force coefficients.
Factory function for settings object, defining aerodynamic interface model via userdefined, 1dimensional, tabulated aerodynamic force coefficients (tabulated w.r.t. independent variable).
 Parameters:
independent_variables (list[float]) – Values of independent variables at which the coefficients in the input multi vector are defined (size 1)
force_coefficients (list[numpy.ndarray[numpy.float64[3, 1]]]) – Values of force coefficients at independent variables defined by independent_variables.
reference_area (float) – Reference area with which aerodynamic forces and moments are nondimensionalized.
independent_variable_name (environment.AerodynamicCoefficientsIndependentVariables) – Identifier of the independent variable w.r.t. which the aerodynamic coefficients are defined.
force_coefficients_frame (AerodynamicCoefficientFrames, default = negative_aerodynamic_frame_coefficients) – Variable defining the frame in which the force coefficients are defined. By default, this is the negative aerodynamic frame, so that the coefficients are for drag, side force and lift (\(C_{D}, C_{S}, C_{L}\))
interpolator_settings (math.interpolators.InterpolatorSettings, default = None) – Interpolator settings object, where the conditions for interpolation of tabulated inputs are saved. Pointer to an interpolator settings object where the conditions for interpolation of tabulated inputs are saved.
 Returns:
Instance of the
AerodynamicCoefficientSettings
derivedTabulatedAerodynamicCoefficientSettings
class Return type:
TabulatedAerodynamicCoefficientSettings
Examples
In this example, aerodynamic force coefficients are defined as a multidimensional array. The values for the force coefficients vary with Mach number, and are defined for Mach numbers of 3, 5, 10, and 15.
# Define the aerodynamic coefficients [CD, CS, CL] for different mach numbers aero_coefficients_array = [ [0.7647, 0, 0.9722], [0.6729, 0, 0.8461], [0.6240, 0, 0.7838], [0.6246, 0, 0.7841] ] # Create the aerodynamic interface settings aero_coefficient_settings = environment_setup.aerodynamic_coefficients.tabulated_force_only( independent_variables=[3.0, 5.0, 10.0, 15.0], # Mach number at which the coefficients are defined force_coefficients=aero_coefficients_array, reference_area=1.50, independent_variable_name=environment.AerodynamicCoefficientsIndependentVariables.mach_number_dependent ) # Assign the aerodynamic coefficient interface to the vehicle environment_setup.add_aerodynamic_coefficient_interface(bodies, "Vehicle", aero_coefficient_settings)
 tabulated_force_only_from_files(force_coefficient_files: dict[int, str], reference_area: float, independent_variable_names: list[tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientsIndependentVariables], force_coefficients_frame: tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientFrames = <AerodynamicCoefficientFrames.negative_aerodynamic_frame_coefficients: 2>, interpolator_settings: tudatpy.kernel.math.interpolators.InterpolatorSettings = None) tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings #
Factory function for creating aerodynamic interface model settings from tabulated force coefficients from files.
Factory function for settings object, defining aerodynamic interface model via userdefined, tabulated aerodynamic force coefficients (tabulated w.r.t. independent variable), obtained from data files.
 Parameters:
force_coefficient_files (Dict[int, str]) – Path of the aerodynamic coefficient files corresponding to the force coefficient of the given dict key.
reference_area (float) – Reference area with which aerodynamic forces and moments are nondimensionalized.
independent_variable_names (list[environment.AerodynamicCoefficientsIndependentVariables]) – Vector with identifiers for the independent variable w.r.t. which the aerodynamic coefficients are defined.
force_coefficients_frame (AerodynamicCoefficientFrames, default = negative_aerodynamic_frame_coefficients) – Variable defining the frame in which the force coefficients are defined. By default, this is the negative aerodynamic frame, so that the coefficients are for drag, side force and lift (\(C_{D}, C_{S}, C_{L}\))
interpolator_settings (math.interpolators.InterpolatorSettings, default = None) – Interpolator settings object, where the conditions for interpolation of tabulated inputs are saved.
 Returns:
Instance of the
AerodynamicCoefficientSettings
derivedTabulatedAerodynamicCoefficientSettings
class Return type:
TabulatedAerodynamicCoefficientSettings
Examples
In this example, the drag and lift coefficients of the Space Transport System are defined from two data files. Both of these data files contain coefficient values dependent on both the angle of attack and the mach number, as shown in the example in the independent_variable_names input. This example is taken from the reentry trajectory example.
# Define the aerodynamic coefficient files (leave C_S empty) aero_coefficients_files = {0: "input/STS_CD.dat", 2:"input/STS_CL.dat"} # Setup the aerodynamic coefficients settings tabulated from the files coefficient_settings = environment_setup.aerodynamic_coefficients.tabulated_force_only_from_files( force_coefficient_files=aero_coefficients_files, reference_area=2690.0*0.3048*0.3048, independent_variable_names=[environment.angle_of_attack_dependent, environment.mach_number_dependent] ) # Add predefined aerodynamic coefficients database to the body environment_setup.add_aerodynamic_coefficient_interface(bodies, "STS", coefficient_settings)
 tabulated_from_files(force_coefficient_files: dict[int, str], moment_coefficient_files: dict[int, str], reference_length: float, reference_area: float, independent_variable_names: list[tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientsIndependentVariables], force_coefficients_frame: tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientFrames = <AerodynamicCoefficientFrames.negative_aerodynamic_frame_coefficients: 2>, moment_coefficients_frame: tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientFrames = <AerodynamicCoefficientFrames.positive_body_fixed_frame_coefficients: 0>, moment_reference_point: numpy.ndarray[numpy.float64[3, 1]] = array([nan, nan, nan]), interpolator_settings: tudatpy.kernel.math.interpolators.InterpolatorSettings = None) tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings #
Factory function for creating aerodynamic interface model settings from tabulated coefficients from files.
Factory function for settings object, defining aerodynamic interface model via userdefined, tabulated aerodynamic force and moment coefficients (tabulated w.r.t. independent variable), obtained from data files.
 Parameters:
force_coefficient_files (Dict[int, str]) – Path of the aerodynamic coefficient files corresponding to the force coefficient of the given dict key (0, 1 and 2 a are x, y and zaxis of force frame, respectively).
moment_coefficient_files (Dict[int, str]) – Path of the aerodynamic coefficient files corresponding to the moment coefficient of the given dict key (0, 1 and 2 a are x, y and zaxis of moment frame, respectively).
reference_length (float) – Reference length with which aerodynamic moments about x and z axes are nondimensionalized.
reference_area (float) – Reference area with which aerodynamic forces and moments are nondimensionalized.
independent_variable_names (list[environment.AerodynamicCoefficientsIndependentVariables]) – Vector with identifiers for the independent variable w.r.t. which the aerodynamic coefficients are defined.
force_coefficients_frame (AerodynamicCoefficientFrames, default = negative_aerodynamic_frame_coefficients) – Variable defining the frame in which the force coefficients are defined. By default, this is the negative aerodynamic frame, so that the coefficients are for drag, side force and lift (\(C_{D}, C_{S}, C_{L}\))
moment_coefficients_frame (AerodynamicCoefficientFrames, default = positive_body_frame_coefficients) – Variable defining the frame in which the moment coefficients are defined. By default, this is the positive body frame, so that the coefficients are roll, pitch yaw (\(C_{l}, C_{m}, C_{n}\))
moment_reference_point (numpy.ndarray[numpy.float64[3, 1]] = np.full([3, 1], np.nan)) – Point w.r.t. aerodynamic moment coefficients are defined. This variable is used to calculate the contribution of the aerodynamic force coefficients to the effective moment coefficients. See the
add_force_contribution_to_moments
attribute of theAerodynamicCoefficientSettings
for more details. If the present input is set to NaN (as is the default), the reference point is left undefined, and the aerodynamic moments are computed without computing any force coefficient contribution to the moment coefficients.interpolator_settings (math.interpolators.InterpolatorSettings, default = None) – Interpolator settings object, where the conditions for interpolation of tabulated inputs are saved.
 Returns:
Instance of the
AerodynamicCoefficientSettings
derivedTabulatedAerodynamicCoefficientSettings
class Return type:
TabulatedAerodynamicCoefficientSettings
Examples
This example is very similar to the one for tabulated_force_only_from_files, with the distinction that a pitching moment coefficient is added.
# Define the force coefficient files (leave C_S empty) force_coefficients_files = {0: "input/STS_CD.dat", 2:"input/STS_CL.dat"} # Define the moment coefficient files (leave C_S empty) moment_coefficients_files = {0: "input/STS_CM.dat"} # Setup the aerodynamic coefficients settings tabulated from the files coefficient_settings = environment_setup.aerodynamic_coefficients.tabulated_from_files( force_coefficient_files=force_coefficients_files, moment_coefficient_files=moment_coefficients_files, reference_length=11.9, reference_area=2690.0*0.3048*0.3048, independent_variable_names=[environment.angle_of_attack_dependent, environment.mach_number_dependent] ) # Add the predefined aerodynamic coefficients database to the body environment_setup.add_aerodynamic_coefficient_interface(bodies, "STS", coefficient_settings)
 scaled_by_constant(unscaled_coefficient_settings: tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings, force_scaling_constant: float, moment_scaling_constant: float, is_scaling_absolute: bool = False) tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings #
Factory function for creating aerodynamic interface model settings by applying one constant scaling factor/value to all coefficients of an existing model settings object.
Factory function for settings object, defining aerodynamic interface based on scaling the coefficients of an existing model settings object by one constant factor or value. Via the
is_scaling_absolute
boolean, the user can apply a constant scaling factor or an absolute value to the resulting force and moment coefficients (for instance for an uncertainty analysis). Parameters:
unscaled_coefficient_settings (AerodynamicCoefficientSettings) – Existing aerodynamic interface model settings object that is used as the base for the scaled settings object.
force_scaling_constant (float) – Constant scaling factor to be applied to all aerodynamic force coefficients.
moment_scaling_constant (float) – Constant scaling factor to be applied to all aerodynamic moment coefficients.
is_scaling_absolute (bool, default = False) – Boolean indicating whether aerodynamic coefficient scaling is absolute. Setting this boolean to true will add the scaling value to the base value, instead of the default behaviour of multiplying the base value by the scaling factor.
 Returns:
Instance of the
AerodynamicCoefficientSettings
derivedScaledAerodynamicCoefficientInterfaceSettings
class Return type:
ScaledAerodynamicCoefficientInterfaceSettings
Examples
In this example, we first set constant aerodynamic coefficients, like in the earlier example. Then, we use the scaled_by_constant function to scale the force coefficients by 1.1. Since the is_scaling_absolute equals False by default, the force coefficients are then increased by 10%.
# Define the reference area and constant aerodynamic coefficients reference_area = 20.0 drag_coefficient = 1.5 lift_coefficient = 0.3 # Create the aerodynamic interface settings aero_coefficient_settings = environment_setup.aerodynamic_coefficients.constant( reference_area, constant_force_coefficient=[drag_coefficient, 0, lift_coefficient] ) # Define scaled aerodynamic coefficient to increase the force coefficients by 10% scaled_aero_coefficient_settings = environment_setup.aerodynamic_coefficients.scaled_by_constant( unscaled_coefficient_settings=aero_coefficient_settings, force_scaling_constant=1.1, moment_scaling_constant=1.0 ) # Assign aerodynamic interface to the vehicle environment_setup.add_aerodynamic_coefficient_interface(bodies, "Vehicle", scaled_aero_coefficient_settings)
 scaled_by_vector(unscaled_coefficient_settings: tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings, force_scaling_vector: numpy.ndarray[numpy.float64[3, 1]], moment_scaling_vector: numpy.ndarray[numpy.float64[3, 1]], is_scaling_absolute: bool = False) tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings #
Factory function for creating aerodynamic interface model settings by applying constant scaling factors/values to the coefficients of an existing model settings object.
Factory function for settings object, defining aerodynamic interface based on scaling the coefficients of an existing model settings object by constant factors or values. Via the
is_scaling_absolute
boolean, the user can apply one constant scaling factor or an absolute value to each resulting force and moment coefficient (for instance for an uncertainty analysis). Parameters:
unscaled_coefficient_settings (AerodynamicCoefficientSettings) – Existing aerodynamic interface model settings object that is used as the base for the scaled settings object.
force_scaling_vector (numpy.ndarray[numpy.float64[3, 1]]) – Constant scaling factors to be applied to each aerodynamic force coefficient.
moment_scaling_vector (numpy.ndarray[numpy.float64[3, 1]]) – Constant scaling factors to be applied to each aerodynamic moment coefficient.
is_scaling_absolute (bool, default = False) – Boolean indicating whether aerodynamic coefficient scaling is absolute. Setting this boolean to true will add the scaling value to the base value, instead of the default behaviour of multiplying the base value by the scaling factor.
 Returns:
Instance of the
AerodynamicCoefficientSettings
derivedScaledAerodynamicCoefficientInterfaceSettings
class Return type:
ScaledAerodynamicCoefficientInterfaceSettings
Examples
In this example, we first set constant aerodynamic coefficients, like in the earlier example. Then, we use the scaled_by_vector function to scale the drag coefficient by 2.
# Define the reference area and constant aerodynamic coefficients reference_area = 20.0 drag_coefficient = 1.5 lift_coefficient = 0.3 # Create the aerodynamic interface settings aero_coefficient_settings = environment_setup.aerodynamic_coefficients.constant( reference_area, constant_force_coefficient=[drag_coefficient, 0, lift_coefficient] ) # Define scaled aerodynamic coefficient to increase CD by a factor of 2 scaled_aero_coefficient_settings = environment_setup.aerodynamic_coefficients.scaled_by_vector( unscaled_coefficient_settings=aero_coefficient_settings, force_scaling_vector=[2.0, 1.0, 1.0], moment_scaling_vector=[1.0, 1.0, 1.0] ) # Assign aerodynamic interface to the vehicle environment_setup.add_aerodynamic_coefficient_interface(bodies, "Vehicle", scaled_aero_coefficient_settings)
 scaled_by_vector_function(unscaled_coefficient_settings: tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings, force_scaling_vector_function: Callable[[float], numpy.ndarray[numpy.float64[3, 1]]], moment_scaling_vector_function: Callable[[float], numpy.ndarray[numpy.float64[3, 1]]], is_scaling_absolute: bool = False) tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings #
Factory function for creating aerodynamic interface model settings by applying custom scaling factors/values to the coefficients of an existing model settings object.
Factory function for settings object, defining aerodynamic interface based on scaling the coefficients of an existing model settings object by custom factors or values. Via the
is_scaling_absolute
boolean, the user can apply the scaling factors or absolute values to each resulting force and moment coefficient (for instance for an uncertainty analysis). Parameters:
unscaled_coefficient_settings (AerodynamicCoefficientSettings) – Existing aerodynamic interface model settings object that is used as the base for the scaled settings object.
force_scaling_vector_function (callable[[float], numpy.ndarray[numpy.float64[3, 1]]]) – Custom scaling factors to be applied to each aerodynamic force coefficient.
moment_scaling_vector_function (callable[[float], numpy.ndarray[numpy.float64[3, 1]]]) – Custom scaling factors to be applied to each aerodynamic moment coefficient.
is_scaling_absolute (bool, default = False) – Boolean indicating whether aerodynamic coefficient scaling is absolute. Setting this boolean to true will add the scaling value to the base value, instead of the default behaviour of multiplying the base value by the scaling factor.
 Returns:
Instance of the
AerodynamicCoefficientSettings
derivedScaledAerodynamicCoefficientInterfaceSettings
class Return type:
ScaledAerodynamicCoefficientInterfaceSettings
Examples
In this example, we first set constant aerodynamic coefficients, like in the earlier example. Then, we use the scaled_by_vector_function function to scale the drag and lift coefficients according to a function that varies with time. This scaling function essentially adds noise to the CD and CL following as a sin or cos function.
# Define the reference area and constant aerodynamic coefficients reference_area = 20.0 drag_coefficient = 1.5 lift_coefficient = 0.3 # Create the aerodynamic interface settings aero_coefficient_settings = environment_setup.aerodynamic_coefficients.constant( reference_area, constant_force_coefficient=[drag_coefficient, 0, lift_coefficient] ) # Define the aerodynamic coefficient scaling as a function of time def aero_coefficient_scaling(time): CD_scale = 1 + 0.25*np.sin(time/10) CL_scale = 1 + 0.25*np.cos(time/15) return [CD_scale, 1.0, CL_scale] # Define scaled aerodynamic coefficient to increase CD by a factor of 2 scaled_aero_coefficient_settings = environment_setup.aerodynamic_coefficients.scaled_by_vector_function( unscaled_coefficient_settings=aero_coefficient_settings, force_scaling_vector_function=aero_coefficient_scaling, moment_scaling_vector_function=lambda x: [1.0, 1.0, 1.0] ) # Assign aerodynamic interface to the vehicle environment_setup.add_aerodynamic_coefficient_interface(bodies, "Vehicle", scaled_aero_coefficient_settings)
 custom_control_surface(force_and_moment_coefficient_function: Callable[[list[float]], numpy.ndarray[numpy.float64[6, 1]]], independent_variable_names: list[tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientsIndependentVariables]) tudat::simulation_setup::CustomControlSurfaceIncrementAerodynamicCoefficientSettings #
Factory function for creating control surface aerodynamic model settings from custom coefficients.
Factory function for settings object, defining control surface aerodynamic interface model via a custom force and moment coefficient function (function of independent variable). This function is essentically the controlsurface equivalent of the
custom_aerodynamic_force_and_moment_coefficients()
function for body coefficient settings. Parameters:
force_and_moment_coefficient_function (callable[[list[float]], numpy.ndarray[numpy.float64[6, 1]]]) – Function that is defining the aerodynamic force (first three entries) and moment (last three entries) coefficients as function of an independent variables (see
independent_variable_names
).independent_variable_names (list[environment.AerodynamicCoefficientsIndependentVariables]) – Vector with identifiers for the independent variable w.r.t. which the control surface aerodynamic coefficients are defined. Typically, one entry from this list will be
control_surface_deflection_dependent
 Returns:
Instance of the
ControlSurfaceIncrementAerodynamicCoefficientSettings
derived class Return type:
ControlSurfaceIncrementAerodynamicCoefficientSettings
Examples
In this example, we create
ControlSurfaceIncrementAerodynamicCoefficientSettings
for the artificial body “Vehicle”, using a function based on the mach number:def force_and_moment_coefficients(variables_list): # Extract the mach number mach_number = variables_list[0] # If the mach number is below 3, use fixed coefficients if mach_number <= 3: return [0.99, 0, 1.08, 0.94, 0.35, 0, 0] # Same if the mach number is above 10 elif mach_number >= 10: return [0.82, 0, 0.88, 0.55, 0, 0] # Otherwise, vary linearly between the ones at M=3 and M=10 CD = 1.06670.02457*mach_number CL = 1.16360.02786*mach_number Cl = 0.35 + 0.02857*mach_number return [CD, 0, CL, Cl, 0, 0] # Create the aerodynamic interface settings aero_coefficient_settings = environment_setup.aerodynamic_coefficients.custom_control_surface( force_and_moment_coefficients, independent_variable_names=[environment.AerodynamicCoefficientsIndependentVariables.mach_number_dependent] ) # Assign the aerodynamic coefficient interface to the vehicle environment_setup.add_aerodynamic_coefficient_interface(bodies, "Vehicle", aero_coefficient_settings)
 tabulated_from_files_control_surface(force_coefficient_files: dict[int, str], moment_coefficient_files: dict[int, str], independent_variable_names: list[tudatpy.kernel.numerical_simulation.environment.AerodynamicCoefficientsIndependentVariables]) tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.ControlSurfaceIncrementAerodynamicCoefficientSettings #
Factory function for creating control surface aerodynamic model settings from tabulated coefficients from files.
Factory function for settings object, defining control surface aerodynamic interface model via userdefined, tabulated aerodynamic force and moment coefficients (tabulated w.r.t. independent variable), obtained from data files.. This function is essentically the controlsurface equivalent of the
tabulated_from_files()
function for body coefficient settings. Returns:
Instance of the
ControlSurfaceIncrementAerodynamicCoefficientSettings
derived class Return type:
ControlSurfaceIncrementAerodynamicCoefficientSettings
Classes#
Base class for providing settings for aerodynamic interface model. 

Class for defining model settings from constant aerodynamic coefficients. 
 class AerodynamicCoefficientSettings#
Base class for providing settings for aerodynamic interface model.
Functional (base) class for settings of aerodynamic interface models that require no information in addition to their type. Aerodynamic interface model settings requiring additional information must be defined using an object derived from this class.
 add_single_control_surface(self: tudatpy.kernel.numerical_simulation.environment_setup.aerodynamic_coefficients.AerodynamicCoefficientSettings, control_surface_settings: tudat::simulation_setup::ControlSurfaceIncrementAerodynamicCoefficientSettings, control_surface_name: str) None #
Function to add settings for a single control surface to the coefficient settings. Note that, in Tudat, the control surface aerodynamic database inherits the reference properties (length, area, moment reference point) from the
AerodynamicCoefficientSettings
to which it is assigned. Parameters:
control_surface_settings (ControlSurfaceIncrementAerodynamicCoefficientSettings) – Settings for aerodynamic coefficients of a control surface
control_surface_name (str) – Name by which the control surface will be identified
 property add_force_contribution_to_moments#
Variable that toggles whether to add the force contribution to the moment coefficients as:
\[\Delta \mathbf{C}_{M} = (\mathbf{r}_{ref}\mathbf{r}_{com})\times \Delta \mathbf{C}_{F}\]where \((\mathbf{r}_{ref}\mathbf{r}_{com})\) is the vector from the center of mass to the moment reference point, and \(\mathbf{C}_{F}\) and \(\mathbf{C}_{M}\) is the vector of forc and moment coefficients. Note that, if the force and moment coefficients afre defined in different frames, the relevant frame conversions are automatically performed. By default, his boolean is set to false, implicitly assuming that the moment coefficients are provided w.r.t. the (constant) center of mass.
 Type:
 property moment_reference_point#
No documentation found.
 class ConstantAerodynamicCoefficientSettings#
Class for defining model settings from constant aerodynamic coefficients.
AerodynamicCoefficientSettings derived class for aerodynamic interface model settings using only constant aerodynamic coefficients.