From c95c880da7f8d4175876313eda98461df41dcda6 Mon Sep 17 00:00:00 2001 From: Mauco03 <marco.gaibotti@skywarder.eu> Date: Sat, 27 Apr 2024 14:43:20 +0200 Subject: [PATCH] [refactoring-ode][functions] Changed state variable to MATLAB standard --- functions/miscellaneous/recallOdeFcn.m | 4 ++-- settings/odeConfig.m | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/functions/miscellaneous/recallOdeFcn.m b/functions/miscellaneous/recallOdeFcn.m index fc746c5..1a69a51 100644 --- a/functions/miscellaneous/recallOdeFcn.m +++ b/functions/miscellaneous/recallOdeFcn.m @@ -28,14 +28,14 @@ All rights reserved SPDX-License-Identifier: GPL-3.0-or-later %} -[~,firstStep] = fun(T(1),Y(1,:),varargin{:}); +[~,firstStep] = fun(T(1),Y(:,1),varargin{:}); namesFields = fieldnames(firstStep); NT = length(T); steps = cell(NT,1); for k = 1:NT - [~,steps{k}] = fun(T(k),Y(k,:),varargin{:}); + [~,steps{k}] = fun(T(k),Y(:,k),varargin{:}); end for i = 1:numel(namesFields) diff --git a/settings/odeConfig.m b/settings/odeConfig.m index 3515947..3d957cc 100644 --- a/settings/odeConfig.m +++ b/settings/odeConfig.m @@ -4,7 +4,6 @@ ode.finalTime = 2000; % [s] Final integration time ode.optAscent = odeset('Events', @eventApogee, 'InitialStep', 1); % ODE options for ascend ode.optAscentDelayPara= odeset('InitialStep', 1); % ODE options for due to the opening delay of the parachute -ode.optAscentMultipleAB = odeset('Events', @eventApogee, 'InitialStep', 1); % ODE options for opening of the airbrakes ode.optParachute = odeset('Events', @eventParaCut); % ODE options for the parachutes ode.optDescent = odeset('Events', @eventLanding,... 'RelTol', 1e-3, 'AbsTol', 1e-3); % ODE options for ballistic descent -- GitLab