Skip to content

v6.0.0

Choose a tag to compare

@github-actions github-actions released this 23 Sep 09:19
e9a84a5

VortexStepMethod v6.0.0

Diff since v5.1.1

Added

  • stability_derivatives gives the force and moment coefficients and their derivatives
    with respect to angle of attack, sideslip and the nondimensional roll, pitch and yaw
    rates p̂ = pb/2V, q̂ = q c_ref/2V, r̂ = rb/2V, turning about solver.reference_point,
    and trim_angle the angles of attack at which CMy changes sign, with the slope that
    says whether each trim is stable.
  • apparent_wind(alpha, beta, va) gives the body-frame inflow vector at an angle
    of attack and sideslip, as set_va!(body_aero, settings) sets it.
  • Solver(settings) and Solver(n_panels, n_unrefined_sections) build a solver without
    a BodyAerodynamics; keyword arguments override the settings.
  • set_va!(body_aero, va_vec, omega; reference_point) turns the body about
    reference_point [m] instead of the origin. The point is stored on
    BodyAerodynamics, starts at the origin, and is kept by later set_va!, reinit!
    and linearize calls until it is given again.
  • Spanwise-flow viscous drag correction (Gaunaa et al. 2024,
    doi:10.1088/1742-6596/2767/2/022068): each section gets a drag increment and a force
    along its span from the flow across it, in solve!, solve and linearize. Opt-in
    via is_with_viscous_drag_correction (default false) on the solver settings.
  • plot_section_polars(body_aero; panels, alphas, delta) draws cl, cd and cm against α
    per panel through calculate_cl/calculate_cd/calculate_cm, for every aero model
    and at flap deflection delta, in one figure instead of one coefficient per call.
  • linearize takes a BodyAerodynamics with more than one wing; theta_idxs and
    delta_idxs then run over the unrefined sections of all wings in order.
  • table_format=:arrow writes the polars as .arrow, like the per-node Cp/cf
    tables: write_polar and write_polar_matrix write Arrow for an .arrow path and
    load_polar_data reads it. resolve_aero_geometry takes table_format too, for the
    polars it generates. obj_to_yaml and surfplan_to_aero_yaml convert a reused
    dataset's polars and node tables to table_format. A CSV polar loads as before
    when every column is numeric; one with a non-numeric column warns and loads as
    INVISCID.

Changed

  • BREAKING: write_polar_csv is write_polar and write_polar_matrix_csv is
    write_polar_matrix. The geometry YAML names the polar polar_file_path; the old
    key csv_file_path is still read, and obj_to_yaml rewrites it when it migrates a
    dataset.
  • BREAKING: artificial damping is removed: the is_with_artificial_damping and
    artificial_damping keyword arguments of Solver, and the artificial_damping, k2
    and k4 solver settings. k2 and k4 had no effect; artificial_damping: true
    smoothed the circulation with fixed factors, so a solve that had it on now gives
    different results. A settings file that still sets these keys loads with a warning. The post-stall stabiliser is
    is_with_artificial_viscosity.
  • BREAKING: ObjAdapter.center_to_com!, calculate_inertia_tensor and
    calc_inertia_y_rotation are removed. Mesh mass properties are computed by
    SymbolicAWEModels, which reads the mesh with read_faces.
  • BREAKING: the apparent wind follows one naming rule. va is its speed [m/s], a _vec
    suffix makes it the 3-vector [m/s] in the body frame, and a _dist suffix gives one
    value per panel, so va_vec_dist is a 3-vector per panel. v_rel is the local flow a
    panel sees, induced velocity included. Public names that break:
    body_aero.va and the va= keyword of BodyAerodynamics and reinit! (now
    va_vec), VSMSolution._va_dist and va_unrefined_dist (now va_vec_dist and
    va_vec_unrefined_dist), BodyAerodynamics.v_a_dist (now v_rel_dist), the
    linearize keyword va_idxs (now va_vec_idxs), the calculate_results key
    "va_ref" (now "va_ref_vec"), the v_a keyword of plot_polars and
    plot_combined_analysis (now va), and the settings keys condition.wind_speed and
    airfoil.v_app (now va). The old names raise an error.
  • Requires Julia 1.12 or 1.13; 1.10 and 1.11 keep resolving v5.1.1.
  • The Makie plot! methods for a Panel or a BodyAerodynamics return a
    Vector{Makie.AbstractPlot} instead of a Vector{Any}; for a BodyAerodynamics
    drawn as flat panels it is one flat list rather than a list per panel.
  • Solver(body_aero; kwargs...) and Solver(body_aero, settings) are deprecated and warn
    on use; build the solver with Solver(settings) or
    Solver(n_panels, n_unrefined_sections) instead.
  • shrink_wrap splits the edges of a closed input to at most
    min(0.01, min_concave_radius/2) chord before wrapping it, so the deflected sections
    and polars obj_to_yaml generates from Kulfan contours move slightly.
  • BREAKING: obj_to_yaml and perpendicular_sections spread the sections evenly over
    the span, measured along the quarter-chord line without its chordwise component,
    instead of over leading-edge arc length, and wingtip_distance is that spanwise
    length. A tip whose leading edge runs aft no longer gathers sections into its last
    centimetres. The same mesh and settings give different section positions, so a tuned
    wingtip_distance and any geometry generated from one have to be redone.
    march_edges no longer returns arclen.

Fixed

  • deform_section re-wraps a section with the rolling ball it was first wrapped with,
    passed as wrap_method (also taken by generate_airfoils, generate_airfoil_aero,
    generate_aero_matrices and generate_polar_from_coordinates), at zero clearance.
    shrink_wrap warns when the contour it returns crosses itself. A thin wrapped section
    came back with its surfaces crossing.
  • shrink_wrap cuts out the loops its clearance offset makes on a thin canopy, so a
    V3 section wrapped at the default MeshSettings is a simple closed curve and no longer
    warns; 6 of 18 crossed themselves.
  • On a body whose wings span different directions, such as a wing and a vertical fin,
    solve!, solve and linearize take each panel's lift, drag and side directions
    from its own wing's spanwise_direction, not the first wing's. solve computes
    wing_span and aspect_ratio_projected from the extent of all wings along the
    first wing's span, through the new calculate_span(wings, spanwise_direction).
  • perpendicular_sections and obj_to_yaml orient each cut by the leading edge through
    the neighbouring stations, not by the step that reached the station, which near a
    closing tip grazed the surface and returned an 80%-thick section. Every section moves
    slightly; regenerate existing geometry to benefit.
  • ELLIPTIC initial circulation works on a body with more than one wing, where it threw
    an ArgumentError: each wing gets an ellipse over its own span, along its own
    spanwise_direction and centred on its own mid-span, also for a single wing off y = 0.
  • get_lower_upper, and with it the flap hinge in deform_section, takes the lower and
    upper surface heights where the contour crosses x = crease_frac. It took the nearest
    points below and above y = 0, which on a cambered section put the hinge near the
    chord line or on the wrong surface. Polars with a flap deflection change slightly.
    It throws an ArgumentError for a contour that crosses that line fewer than twice.
  • write_polar for SectionSolutions, write_polar_matrix and write_aero_matrix
    write coefficients at 16 significant digits instead of 4 decimals, so a POLAR_MATRICES
    table carries the drag response to a small flap deflection. Regenerate existing tables
    to benefit.
  • solve! and solve throw a DimensionMismatch naming both sizes for a body_aero whose
    panel or unrefined-section count differs from the solver's, where they failed on a
    broadcast partway through or silently left section results at zero.
  • set_va!(body_aero, settings) applies condition.yaw_rate as a turn rate about the
    body z axis; it was read from the settings file and ignored.
  • The VSMSolution docstring gives lift_dist, drag_dist and panel_moment_dist in
    the per-unit-span units they hold, [N/m] and [Nm/m], instead of [N] and [Nm].
  • fit_kulfan_parameters with LeastSquaresFit drops singular values below 1e-4
    times the largest and warns when it does, so a contour whose stations crowd into a
    narrow band of the chord gets bounded weights instead of ones that resample it to 1e4
    scale. Fits of well-spread stations are unchanged.
  • Inside its vortex core, velocity_3D_trailing_vortex! induces an azimuthal velocity
    instead of a radial one. Only points within the millimetre-scale Oseen core of a
    panel's chordwise trailing segment were affected.
  • panel_axes takes the panel normal from the quarter-chord step, so the frame
    closes as z_airf = x_airf × y_airf and z_airf is square to the bound
    vortex. alpha is measured against that normal, so cl, cd and cm were
    wrong on panels whose two sections have differently-directed chords — twist,
    sweep or dihedral, not taper alone.

Merged pull requests:

  • Take the panel normal from the quarter-chord step (#273) (@1-Bart-1)
  • Delete ObjAdapter's copy of the mesh inertia integral; SymbolicAWEModels owns it (#325) (@1-Bort-1)
  • Test and support Julia 1.12 and 1.13, drop 1.11 (#327) (@1-Bort-1)
  • Zero the damping correction when smooth_circulation! skips smoothing, and cover it and lei_poly_coeffs with unit tests (#328) (@1-Bort-1)
  • Test the solver against the references in the Python verification cases (#334) (@1-Bort-1)
  • Test that moments come out in N·m by scaling the wing's geometry (#335) (@1-Bort-1)
  • Give every untyped empty container its element type (#338) (@1-Bort-1)
  • Test solve! on a body built from two wings (#339) (@1-Bort-1)
  • Build a Solver from VSMSettings or from panel and section counts, deprecate the body_aero constructors, and check the sizes in solve! (#340) (@1-Bort-1)
  • Rename the *_array locals to _dist, matching the per-panel fields they hold (#341) (@1-Bort-1)
  • Truncate the SVD in the least-squares Kulfan fit, and warn when it does, so crowded stations give bounded weights (#342) (@1-Bort-1)
  • Add stability_derivatives (angle of attack, sideslip) and trim_angle, built on linearize (#346) (@1-Bort-1)
  • Name the apparent wind va, va_vec and va_dist everywhere except the public API (#349) (@1-Bort-1)
  • Spread sliced sections evenly over the span, not over leading-edge arc length (#350) (@1-Bort-1)
  • Bound and trailing vortices share one segment kernel, so the trailing core induces azimuthal velocity (#351) (@1-Bort-1)
  • Add the Gaunaa et al. 2024 spanwise-flow viscous drag correction as an opt-in solver setting (#352) (@1-Bort-1)
  • set_va! turns the body about a stored reference_point, and set_va!(body_aero, settings) applies yaw_rate (#353) (@1-Bort-1)
  • plot_section_polars draws cl, cd and cm against alpha per panel, for every aero model (#354) (@1-Bort-1)
  • linearize and make_dual_shadow take a BodyAerodynamics with several wings (#355) (@1-Bort-1)
  • stability_derivatives gives roll, pitch and yaw rate derivatives about solver.reference_point (#356) (@1-Bort-1)
  • Re-wrap a deformed section with the ball it was first wrapped with, and cut the loops out of the clearance offset (#365) (@1-Bort-1)
  • Start ELLIPTIC circulation on each wing's own ellipse, so multi-wing bodies solve (#366) (@1-Bort-1)
  • Each panel takes its own wing's spanwise direction in calc_forces! and calculate_results (#367) (@1-Bort-1)
  • BREAKING: name the public apparent wind va, va_vec and va_dist, with no deprecation aliases (#368) (@1-Bort-1)
  • Write polar CSV coefficients at 16 significant digits instead of 4 decimals (#369) (@1-Bort-1)
  • Take the flap hinge heights from where the contour crosses the crease line (#370) (@1-Bort-1)
  • Polars follow table_format through the node-table I/O, and lose csv from their names (#372) (@1-Bort-1)
  • Remove artificial damping, as the Python package did (#374) (@1-Bort-1)
  • Explain the va naming rule in the changelog instead of listing every rename (#375) (@1-Bort-1)
  • march_edges takes each station's tangent from its neighbours, so no cut near a closing tip grazes the surface (#376) (@1-Bort-1)
  • Hoist march_edges' cut, march and tip bisection to module-level functions (#380) (@1-Bort-1)
  • Release VortexStepMethod v6.0.0 (#385) (@1-Bort-1)

Closed issues:

  • Find 2D foil shape from 3D .obj file (#47)
  • Add unit tests for uncovered functions (#53)
  • Add test cases from the Python verification cases (#93)
  • Define file data format for the LEI kite geometry (#133)
  • Add test for multiple wings (#143)
  • Refactoring part III (#147)
  • Remove the parameter body_aero from the constructor of the Solver (#153)
  • 2D polar extrapolation is not realistic in lift (#208)
  • Add tests that check if moment have right units (#209)
  • Panel normal z_airf is built from the leading-edge step, not the quarter-chord step the bound vortex uses (#272)
  • Section slicing spreads stations by leading-edge arc length, which collapses to nothing in span at a raked tip (#275)
  • test_forwarddiff.jl's POLAR_MATRICES check flakes at ~4%, and the oper (#287)
  • The Kulfan least-squares fit has no rank guard, so a crowded resample writes an airfoil at 1e4 scale with a normal residual (#295)
  • Add before/after figures to #294 (doubly-wrapped contour fix) (#297)
  • deform_section's re-wrap turns a thin section into a contour whose surfaces cross (#321)
  • analyze_sweep on an XFoilSolver can end the Julia process, exit code 0 and no exception (#322)
  • Bring RamAirKite.jl onto SymbolicAWEModels v0.18: Delete the duplicated inertia integral from VortexStepMethod (#324)
  • Julia 1.13: VortexStepMethod.jl (#326)
  • set_va! rotates the body about the origin only, and condition.yaw_rate is read but never applied (#329)
  • Add rigid-body stability derivatives and a trim-angle search, as in the Python package (#330)
  • plot_section_polars covers only POLAR_VECTORS: plot cl, cd, cm against alpha per panel for every aero model (#331)
  • Add the optional spanwise-flow viscous drag correction (Gaunaa et al. 2024) from the Python solver (#332)
  • velocity_3D_trailing_vortex! projects onto the core azimuthally, so its in-core velocity is radial (#333)
  • Rename the *_array locals to say whether they are a vector or a... (#336)
  • One name per apparent-wind quantity: va, v_a, _va and va_*... (#337)
  • -h (#343)
  • linearize and make_dual_shadow accept a BodyAerodynamics with more... (#344)
  • stability_derivatives gives roll, pitch and yaw rate derivatives... (#345)
  • k2 and k4 in the artificial damping settings have had no effect since #45 (#347)
  • BREAKING: rename the public apparent-wind API to va / va_vec / va_dist (#348)
  • ELLIPTIC initial circulation for a body with more than one wing (#357)
  • calc_forces! and calculate_results use the first wing's spanwise_direction for the panels of every wing (#358)
  • march_edges gives each station the previous station's leading-edge step, so a cut near a closing tip grazes the surface and reports an 80%-thick section (#361)
  • POLAR_MATRICES tables are written with %.4f, so Cd carries no deflection dependence at small deltas (#362)
  • A wrap at the default clearance crosses itself on thin canopy sections (#363)
  • get_lower_upper puts the negative-flap hinge near the chord line on cambered sections (#364)
  • Write and read polar tables as Arrow when table_format is :arrow (#371)
  • Rename write_polar_csv, write_polar_matrix_csv and csv_file_path now that polars can be Arrow (#373)
  • cleanup: hoist march_edges' nested cut/march closures to module-level... (#377)