A '(' might be missing a closing ')', causing invalid syntax at '.'. Error located at bracket between 'thetadot2omega' & 'obj.thetadot'. thetadot2omega ( obj.thetadot
이전 댓글 표시
% Take input from our controller.
omega = thetadot2omega(obj.thetadot, obj.theta);
% Compute linear and angular accelerations.
a = acceleration (obj.i, obj.theta, obj.xdot, obj.m, obj.g, obj.k, obj.kd );
omega = omega + (obj.time_interval * omegadot);
omegadot = angular_acceleration(obj.i, omega, obj.inertiamatrix, obj.L, obj.b, obj.k);
obj.theta = obj.theta + obj.time_interval * obj.thetadot;
obj.thetadot = omega2thetadot(omega, obj.theta);
obj.theta = obj.theta + obj.time_interval * obj.thetadot;
obj.xdot = obj.xdot + obj.time_interval * a;
obj.pos = obj.pos + obj.time_interval * obj.xdot;
댓글 수: 1
There aren't any open scopes here.
The code you posted works without any syntax errors, provided I go to the trouble of writing a bunch of placeholder functions and defining variables. It's hard to say what's wrong without seeing the rest. I imagine that the problem is in the preceding code.
답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Language Support에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!