-
Notifications
You must be signed in to change notification settings - Fork 2
/
AbstractDynamics.m
30 lines (26 loc) · 1.24 KB
/
AbstractDynamics.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
%---------------------------------------------------------------------------------------------------
% Copyright (c) Institute of Control Systems, Hamburg University of Technology. All rights reserved.
% Licensed under the GPLv3. See LICENSE in the project root for license information.
% Author(s): Christian Hespe
%---------------------------------------------------------------------------------------------------
classdef(Abstract) AbstractDynamics < handle
%ABSTRACTDYNAMICS Abstract class intended as superclass for all
%implementations of dynamic systems.
% This abstract class defines the interface that dynamic system
% objects should adhere to. As the overall simulation is performed in
% discrete timesteps, the dynamics are also evaluated in steps, even
% if the underlying system is formulated in continuous-time.
properties(GetAccess = public, SetAccess = protected)
x % Dynamic state of the system
end
methods
function obj = AbstractDynamics(x0)
%ABSTRACTDYNAMICS Construct an instance of this class
obj.x = x0;
end
end
methods(Abstract)
% Method to execute a single time step of the dynamics.
z = step(obj, w);
end
end