当前位置: 首页>>代码示例>>Python>>正文


Python Data.angle_of_attack方法代码示例

本文整理汇总了Python中SUAVE.Core.Data.angle_of_attack方法的典型用法代码示例。如果您正苦于以下问题:Python Data.angle_of_attack方法的具体用法?Python Data.angle_of_attack怎么用?Python Data.angle_of_attack使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在SUAVE.Core.Data的用法示例。


在下文中一共展示了Data.angle_of_attack方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: __defaults__

# 需要导入模块: from SUAVE.Core import Data [as 别名]
# 或者: from SUAVE.Core.Data import angle_of_attack [as 别名]
    def __defaults__(self):
        """
        OUTPUTS:
        	- 'aerodynamic' (CL, CD, CM)
        	- 'body derivatives' (CMa,CNb,Clb,
        	- 'stability derivatives' (

        """

        self.index = 0		# Will be overwritten when passed to an AVL_Callable object
        self.tag   = 'case'
        self.mass  = 0.0

        self.conditions = Data()
        self.stability_and_control = Data()
        free = Data()
        aero = Data()

        free.mach     = 0.0
        free.velocity = 0.0
        free.density  = 1.225
        free.gravitational_acceleration = 9.81

        aero.parasite_drag    = 0.0
        aero.angle_of_attack  = 0.0
        aero.side_slip_angle  = 0.0

        self.stability_and_control.control_deflections = None
        self.conditions.freestream = free
        self.conditions.aerodynamics = aero

        self.result_filename = None
开发者ID:Aircraft-Design-UniNa,项目名称:SUAVE,代码行数:34,代码来源:Cases.py

示例2: call_SU2

# 需要导入模块: from SUAVE.Core import Data [as 别名]
# 或者: from SUAVE.Core.Data import angle_of_attack [as 别名]
def call_SU2(conditions,settings,geometry):
    """Calculates lift and drag using SU2

    Assumptions:
    None

    Source:
    N/A

    Inputs:
    conditions.
      mach_number        [-]
      angle_of_attack    [radians]
    settings.
      half_mesh_flag     <boolean> Determines if a symmetry plane is used
      parallel           <boolean>
      processors         [-]
      maximum_iterations [-]
    geometry.
      tag
      reference_area     [m^2]

    Outputs:
    CL                   [-]
    CD                   [-]

    Properties Used:
    N/A
    """      

    half_mesh_flag = settings.half_mesh_flag
    tag            = geometry.tag
    parallel       = settings.parallel
    processors     = settings.processors 
    iters          = settings.maximum_iterations
    
    SU2_settings = Data()
    if half_mesh_flag == False:
        SU2_settings.reference_area  = geometry.reference_area
    else:
        SU2_settings.reference_area  = geometry.reference_area/2.
    SU2_settings.mach_number     = conditions.aerodynamics.mach
    SU2_settings.angle_of_attack = conditions.aerodynamics.angle_of_attack / Units.deg
    SU2_settings.maximum_iterations = iters
    
    # Build SU2 configuration file
    write_SU2_cfg(tag, SU2_settings)
    
    # Run SU2
    CL, CD = call_SU2_CFD(tag,parallel,processors)
        
    return CL, CD
开发者ID:suavecode,项目名称:SUAVE,代码行数:54,代码来源:SU2_inviscid.py

示例3: __defaults__

# 需要导入模块: from SUAVE.Core import Data [as 别名]
# 或者: from SUAVE.Core.Data import angle_of_attack [as 别名]
    def __defaults__(self):
        """Defines the data structure and defaults of aerodynamics coefficients, 
        body derivatives and stability derivatives   

        Assumptions:
            None
    
        Source:
            None
    
        Inputs:
            None
    
        Outputs:
            None
    
        Properties Used:
            N/A
        """ 

        self.index                      = 0		# Will be overwritten when passed to an AVL_Callable object
        self.tag                        = 'case'
        self.mass                       = 0.0

        self.conditions                 = Data()
        self.stability_and_control      = Data()
        free                            = Data()
        aero                            = Data()

        free.mach                       = 0.0
        free.velocity                   = 0.0
        free.density                    = 1.225
        free.gravitational_acceleration = 9.81

        aero.parasite_drag              = 0.0
        aero.angle_of_attack            = 0.0
        aero.side_slip_angle            = 0.0

        self.stability_and_control.control_deflections  = None
        self.stability_and_control.number_control_surfaces = 0
        self.conditions.freestream      = free
        self.conditions.aerodynamics    = aero

        self.result_filename            = None
        self.eigen_result_filename      = None
开发者ID:michK,项目名称:SUAVE,代码行数:47,代码来源:Cases.py


注:本文中的SUAVE.Core.Data.angle_of_attack方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。