Repository navigation
v6.0.0
VortexStepMethod v6.0.0
Added
stability_derivativesgives 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 aboutsolver.reference_point,
andtrim_anglethe angles of attack at whichCMychanges 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, asset_va!(body_aero, settings)sets it.Solver(settings)andSolver(n_panels, n_unrefined_sections)build a solver without
aBodyAerodynamics; 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 laterset_va!,reinit!
andlinearizecalls 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, insolve!,solveandlinearize. Opt-in
viais_with_viscous_drag_correction(defaultfalse) on the solver settings. plot_section_polars(body_aero; panels, alphas, delta)draws cl, cd and cm against α
per panel throughcalculate_cl/calculate_cd/calculate_cm, for every aero model
and at flap deflectiondelta, in one figure instead of one coefficient per call.linearizetakes aBodyAerodynamicswith more than one wing;theta_idxsand
delta_idxsthen run over the unrefined sections of all wings in order.table_format=:arrowwrites the polars as.arrow, like the per-nodeCp/cf
tables:write_polarandwrite_polar_matrixwrite Arrow for an.arrowpath and
load_polar_datareads it.resolve_aero_geometrytakestable_formattoo, for the
polars it generates.obj_to_yamlandsurfplan_to_aero_yamlconvert a reused
dataset's polars and node tables totable_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_csviswrite_polarandwrite_polar_matrix_csvis
write_polar_matrix. The geometry YAML names the polarpolar_file_path; the old
keycsv_file_pathis still read, andobj_to_yamlrewrites it when it migrates a
dataset. - BREAKING: artificial damping is removed: the
is_with_artificial_dampingand
artificial_dampingkeyword arguments ofSolver, and theartificial_damping,k2
andk4solver settings.k2andk4had 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_tensorand
calc_inertia_y_rotationare removed. Mesh mass properties are computed by
SymbolicAWEModels, which reads the mesh withread_faces. - BREAKING: the apparent wind follows one naming rule.
vais its speed [m/s], a_vec
suffix makes it the 3-vector [m/s] in the body frame, and a_distsuffix gives one
value per panel, sova_vec_distis a 3-vector per panel.v_relis the local flow a
panel sees, induced velocity included. Public names that break:
body_aero.vaand theva=keyword ofBodyAerodynamicsandreinit!(now
va_vec),VSMSolution._va_distandva_unrefined_dist(nowva_vec_distand
va_vec_unrefined_dist),BodyAerodynamics.v_a_dist(nowv_rel_dist), the
linearizekeywordva_idxs(nowva_vec_idxs), thecalculate_resultskey
"va_ref"(now"va_ref_vec"), thev_akeyword ofplot_polarsand
plot_combined_analysis(nowva), and the settings keyscondition.wind_speedand
airfoil.v_app(nowva). 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 aPanelor aBodyAerodynamicsreturn a
Vector{Makie.AbstractPlot}instead of aVector{Any}; for aBodyAerodynamics
drawn as flat panels it is one flat list rather than a list per panel. Solver(body_aero; kwargs...)andSolver(body_aero, settings)are deprecated and warn
on use; build the solver withSolver(settings)or
Solver(n_panels, n_unrefined_sections)instead.shrink_wrapsplits 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 polarsobj_to_yamlgenerates from Kulfan contours move slightly.- BREAKING:
obj_to_yamlandperpendicular_sectionsspread the sections evenly over
the span, measured along the quarter-chord line without its chordwise component,
instead of over leading-edge arc length, andwingtip_distanceis 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_distanceand any geometry generated from one have to be redone.
march_edgesno longer returnsarclen.
Fixed
deform_sectionre-wraps a section with the rolling ball it was first wrapped with,
passed aswrap_method(also taken bygenerate_airfoils,generate_airfoil_aero,
generate_aero_matricesandgenerate_polar_from_coordinates), at zero clearance.
shrink_wrapwarns when the contour it returns crosses itself. A thin wrapped section
came back with its surfaces crossing.shrink_wrapcuts out the loops itsclearanceoffset makes on a thin canopy, so a
V3 section wrapped at the defaultMeshSettingsis 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!,solveandlinearizetake each panel's lift, drag and side directions
from its own wing'sspanwise_direction, not the first wing's.solvecomputes
wing_spanandaspect_ratio_projectedfrom the extent of all wings along the
first wing's span, through the newcalculate_span(wings, spanwise_direction). perpendicular_sectionsandobj_to_yamlorient 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.ELLIPTICinitial circulation works on a body with more than one wing, where it threw
anArgumentError: each wing gets an ellipse over its own span, along its own
spanwise_directionand centred on its own mid-span, also for a single wing off y = 0.get_lower_upper, and with it the flap hinge indeform_section, takes the lower and
upper surface heights where the contour crossesx = crease_frac. It took the nearest
points below and abovey = 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 anArgumentErrorfor a contour that crosses that line fewer than twice.write_polarforSectionSolutions,write_polar_matrixandwrite_aero_matrix
write coefficients at 16 significant digits instead of 4 decimals, so aPOLAR_MATRICES
table carries the drag response to a small flap deflection. Regenerate existing tables
to benefit.solve!andsolvethrow aDimensionMismatchnaming both sizes for abody_aerowhose
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)appliescondition.yaw_rateas a turn rate about the
body z axis; it was read from the settings file and ignored.- The
VSMSolutiondocstring giveslift_dist,drag_distandpanel_moment_distin
the per-unit-span units they hold, [N/m] and [Nm/m], instead of [N] and [Nm]. fit_kulfan_parameterswithLeastSquaresFitdrops singular values below1e-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_axestakes the panel normal from the quarter-chord step, so the frame
closes asz_airf = x_airf × y_airfandz_airfis square to the bound
vortex.alphais measured against that normal, socl,cdandcmwere
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
*_arraylocals 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
csvfrom 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
*_arraylocals to say whether they are a vector or a... (#336) - One name per apparent-wind quantity:
va,v_a,_vaandva_*... (#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)