%% Create Basic System Object
% This example shows how to author a basic System object called AddOne.
%
% In MATLAB, select New > System object > Basic. A new editor window opens with default syntax and comments for a new System object.
%
% Rename the class AddOne. Modify the default template so your class looks like this:
% classdef AddOne < matlab.System
% % ADDONE Compute an output value that increments the input by one
%
%     methods (Access = protected)
%        % Implement algorithm. Calculate y as a function of input x.
%        function y = stepImpl(~,x)
%           y = x + 1;
%        end
%     end
% end
%
% Use this object by creating an instance of AddOne and running the object with input.

addingObject = AddOne;
x = 5;
addingObject(x)

%
% Copyright 2019 The MathWorks, Inc.