What does line number 4 is actually doing, i.e. obj = obj@CtrlAf​fineSys(pa​rams);

1 回表示 (過去 30 日間)
Pallov Anand
Pallov Anand 2022 年 11 月 15 日
コメント済み: Pallov Anand 2022 年 11 月 16 日
classdef ACC < CtrlAffineSys
methods
function obj = ACC(params)
obj = obj@CtrlAffineSys(params);
end
function Fr = getFr(obj, x)
v = x(2);
Fr = obj.params.f0 + obj.params.f1 * v + obj.params.f2 * v^2;
end
end
end

採用された回答

Matt J
Matt J 2022 年 11 月 15 日
It is calling the parent class constructor.
  3 件のコメント
Matt J
Matt J 2022 年 11 月 15 日
You're welcome, but please Accept-click the answer if your question has been addressed.
Pallov Anand
Pallov Anand 2022 年 11 月 16 日
oh...i forgot to do that, its done now :)

サインインしてコメントする。

その他の回答 (0 件)

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by