Skip to content

Commit 1cba421

Browse files
committed
Make use of panel_width_array
1 parent 3a3d7fa commit 1cba421

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

src/solver.jl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ Struct for storing the solution of the [solve!](@ref) function. Must contain all
1515
- solver_status::SolverStatus: enum, see [SolverStatus](@ref)
1616
"""
1717
mutable struct VSMSolution{P}
18+
panel_width_array::Vector{Float64}
1819
gamma_distribution::Union{Nothing, Vector{Float64}}
1920
aero_force::MVec3
2021
aero_moments::MVec3
@@ -26,7 +27,7 @@ mutable struct VSMSolution{P}
2627
end
2728

2829
function VSMSolution(P)
29-
VSMSolution{P}(nothing, zeros(MVec3), zeros(MVec3), zeros(MVec3), zeros(MVec3), zeros(3), zeros(3), FAILURE)
30+
VSMSolution{P}(zeros(P), nothing, zeros(MVec3), zeros(MVec3), zeros(MVec3), zeros(MVec3), zeros(3), zeros(3), FAILURE)
3031
end
3132

3233
"""
@@ -120,7 +121,7 @@ function solve!(solver::Solver, body_aero::BodyAerodynamics, gamma_distribution=
120121
cl_array = zeros(n_panels)
121122
cd_array = zeros(n_panels)
122123
cm_array = zeros(n_panels)
123-
panel_width_array = zeros(n_panels)
124+
panel_width_array = solver.sol.panel_width_array
124125
solver.sol.moment_distribution = zeros(n_panels)
125126
solver.sol.moment_coefficient_distribution = zeros(n_panels)
126127
moment_distribution = solver.sol.moment_distribution

test/bench2.jl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
using LinearAlgebra
2-
using ControlPlots
32
using VortexStepMethod
43
using BenchmarkTools
54

0 commit comments

Comments
 (0)