pfh.glidersim.foil_aerodynamics#
Models for estimating the aerodynamics of a 3D foil from its sections.
Classes
|
Interface for classes that implement a FoilAerodynamics model. |
|
A non-linear numerical lifting-line method. |
Exceptions
The estimator failed to converge on a solution. |
- class pfh.glidersim.foil_aerodynamics.FoilAerodynamics(*args, **kwargs)#
Bases:
Protocol
Interface for classes that implement a FoilAerodynamics model.
Methods
__call__
(ai, v_W2f, rho_air, **kwargs)Estimate the forces and moments on a foil.
r_CP2LE
()Compute the control points for the section aerodynamics.
- abstract __call__(ai, v_W2f, rho_air, **kwargs)#
Estimate the forces and moments on a foil.
- Parameters
- aiarray_like of float
Airfoil indices. The shape must be able to broadcast to (K,), where K is the number of control points being used by the estimator.
- v_W2farray_like of float [m/s]
The velocity of the wind relative to the control points in foil frd coordinates. The shape must be able to broadcast to (K, 3), where K is the number of control points being used by the estimator.
- rho_airarray_like of float [kg/m^3]
Air density
- abstract r_CP2LE()#
Compute the control points for the section aerodynamics.
- Returns
- ndarray of float, shape (K,3) [m]
Control points relative to the central leading edge LE. Coordinates are in canopy frd, and K is the number of points being used by the estimation method.
- __init__(*args, **kwargs)#
- exception pfh.glidersim.foil_aerodynamics.ConvergenceError#
Bases:
RuntimeError
The estimator failed to converge on a solution.
- __init__(*args, **kwargs)#
- args#
- with_traceback()#
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- class pfh.glidersim.foil_aerodynamics.Phillips(foil: SimpleFoil, v_ref_mag, alpha_ref: float, s_nodes, s_clamp: float | None = None)#
Bases:
pfh.glidersim.foil_aerodynamics.FoilAerodynamics
A non-linear numerical lifting-line method.
Uses a set of spanwise bound vortices instead of a single, uniform lifting line. Unlike the Prandtl’s classic lifting-line theory, this method allows for wing sweep and dihedral.
- Parameters
- foilSimpleFoil
Defines the lifting-line and section coefficients.
- v_ref_magfloat [m/s]
The reference solution airspeed
- alpha_reffloat [degrees]
The reference solution angle of attack
- s_nodesarray_like of floats, shape (K+1,)
Section indices of the K + 1 section nodes (wing segment endpoints). The K >= 1 aerodynamic control points are centered between the nodes. Two common point distributions are:
Linear:
np.linspace(-1, 1, K + 1)
Cosine:
np.cos(np.linspace(np.pi, 0, K + 1))
- s_clampfloat, optional
Section index to enable clamped output of the aerodynamic coefficients for section indices abs(s) >= s_clamp. Instead of returning nan, clamping uses the value of the largest alpha that produces a non-nan coefficient for the given (ai, Re) pair.
This option is experimental and should be used with caution. Its purpose is to mitigate the fictitious, large angles of attack induced at the wing tips due to the control points being placed on the lifting line. The theory is that if the induced velocity is indeed fictious, then the true angle of attack is likely much closer to the standard range. By limiting clamping to just the outer s > s_clamp, if the wing is experiencing a genuinely large angle of attack, then the other non-clamped sections will still fail, thus signalling stall conditions. If the segments are small the error introduced should be negligible.
Notes
This implementation uses a single distribution for the entire span, which is suitable for parafoils, which is a continuous lifting surface, but for wings with left and right segments separated by some discontinuity at the root you should distribute the points across each semispan independently. See _[1] for a related discussion.
This method does suffer an issue where induced velocity goes to infinity as the segment lengths tend toward zero (as the number of segments increases, or for a poorly chosen point distribution). See _[2], section 8.2.3.
References
- 1
Phillips and Snyder, “Modern Adaptation of Prandtl’s Classic Lifting-Line Theory”, Journal of Aircraft, 2000
- 2
Hunsaker and Snyder, “A lifting-line approach to estimating propeller/wing interactions”, 2006
- 3
McLeanauth, “Understanding Aerodynamics - Arguing from the Real Physics”, 2013, p382
Methods
__call__
(ai, v_W2f, rho_air, *[, ...])Estimate the forces and moments on a foil.
r_CP2LE
()Compute the control points for the section aerodynamics.
- __init__(foil: SimpleFoil, v_ref_mag, alpha_ref: float, s_nodes, s_clamp: float | None = None) None #
- r_CP2LE()#
Compute the control points for the section aerodynamics.
- Returns
- ndarray of float, shape (K,3) [m]
Control points relative to the central leading edge LE. Coordinates are in canopy frd, and K is the number of points being used by the estimation method.
- __call__(ai, v_W2f, rho_air, *, reference_solution: Optional[dict] = None, max_splits: int = 10)#
Estimate the forces and moments on a foil.
- Parameters
- aiarray_like of float
Airfoil indices. The shape must be able to broadcast to (K,), where K is the number of control points being used by the estimator.
- v_W2farray_like of float [m/s]
The velocity of the wind relative to the control points in foil frd coordinates. The shape must be able to broadcast to (K, 3), where K is the number of control points being used by the estimator.
- rho_airarray_like of float [kg/m^3]
Air density