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

fix(Result): display op pts for multi-rotors (closes #15)

parent c8525bcb
No related branches found
No related tags found
No related merge requests found
......@@ -81,6 +81,13 @@ classdef Result < handle
% Note: A bug in Matlab prevents the use of variable names when size checks are added
% in the property definition. See: https://stackoverflow.com/q/48423003
self.operPts = val;
% Properly name and group operating points for multi rotors
% Must merge in that order to have correct indexes
nRots = (size(val, 2) - 2) / 2;
self.operPts = mergevars(self.operPts, 3 + nRots:size(val, 2));
self.operPts = mergevars(self.operPts, 3:3 + nRots - 1);
self.operPts.Properties.VariableNames = {'altitude', 'speed', 'rpm', 'collective'};
end
......
......@@ -141,7 +141,8 @@ function [Results] = rotare(configFile)
% Table that identifies the operating point for future reuse
operPoints(iOperPoint, :) = [Uop.altitude(iAlt), Uop.speed(iSpeed), ...
Uop.rpm(i, iRpm), Uop.collective(i, iColl)];
[Uop.rpm(:, iRpm)'], ...
[Uop.collective(:, iColl)']];
iOperPoint = iOperPoint + 1;
......
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