Skip to content
Snippets Groups Projects
Verified Commit 3673efbb authored by Thomas Lambert's avatar Thomas Lambert :helicopter:
Browse files

fix(polar): CLslope calc when polar for single Re

parent 8493a6bb
No related branches found
No related tags found
No related merge requests found
......@@ -18,6 +18,8 @@ to [Semantic Versioning][sem_ver].
### Fixed
- Issue with zero lift angle calculation when polars provided for a single
Reynolds
- Issue with lift curve slope calculation when polars provided for a single
Reynolds
## [0.1.1] - 2023-02-13
......
......@@ -10,3 +10,5 @@ automatically generated and do not contain all dependencies.
This release features:
- **FIX**: Issue with zero lift angle calculation when polars provided for a
single Reynolds
- **FIX**: Issue with lift curve slope calculation when polars provided for a
single Reynolds
......@@ -133,10 +133,14 @@ function clSlope = getclslope(Af, iAf, reynolds)
clSlope = zeros(size(iAf));
for i = 1:length(Af)
clSlope(iAf == i) = interp1(Af(i).Polar.reynolds, ...
Af(i).Polar.Lin.slope, ...
reynolds(iAf == i), ...
'linear', 'extrap');
if numel(Af(i).Polar.reynolds) == 1
clSlope(iAf == i) = Af(i).Polar.Lin.slope;
else
clSlope(iAf == i) = interp1(Af(i).Polar.reynolds, ...
Af(i).Polar.Lin.slope, ...
reynolds(iAf == i), ...
'linear', 'extrap');
end
end
end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment