function [stewart] = initializeStrutDynamics(stewart, args)
% initializeStrutDynamics - Add Stiffness and Damping properties of each strut
%
% Syntax: [stewart] = initializeStrutDynamics(args)
%
% Inputs:
%    - args - Structure with the following fields:
%        - K [6x1] - Stiffness of each strut [N/m]
%        - C [6x1] - Damping of each strut [N/(m/s)]
%
% Outputs:
%    - stewart - updated Stewart structure with the added fields:
%      - actuators.type = 1
%      - actuators.K [6x1] - Stiffness of each strut [N/m]
%      - actuators.C [6x1] - Damping of each strut [N/(m/s)]

arguments
    stewart
    args.type char {mustBeMember(args.type,{'classical', 'amplified'})} = 'classical'
    args.K (6,1) double {mustBeNumeric, mustBeNonnegative} = 20e6*ones(6,1)
    args.C (6,1) double {mustBeNumeric, mustBeNonnegative} = 2e1*ones(6,1)
    args.k1 (6,1) double {mustBeNumeric} = 1e6
    args.ke (6,1) double {mustBeNumeric} = 5e6
    args.ka (6,1) double {mustBeNumeric} = 60e6
    args.c1 (6,1) double {mustBeNumeric} = 10
    args.ce (6,1) double {mustBeNumeric} = 10
    args.ca (6,1) double {mustBeNumeric} = 10
    args.me (6,1) double {mustBeNumeric} = 0.05
    args.ma (6,1) double {mustBeNumeric} = 0.05
end

if strcmp(args.type, 'classical')
    stewart.actuators.type = 1;
elseif strcmp(args.type, 'amplified')
    stewart.actuators.type = 2;
end

stewart.actuators.K = args.K;
stewart.actuators.C = args.C;

stewart.actuators.k1 = args.k1;
stewart.actuators.c1 = args.c1;

stewart.actuators.ka = args.ka;
stewart.actuators.ca = args.ca;

stewart.actuators.ke = args.ke;
stewart.actuators.ce = args.ce;

stewart.actuators.ma = args.ma;
stewart.actuators.me = args.me;