Simulink's integrator gives weird output

6 次查看(过去 30 天)
Hello, I am trying to simulate when a robot grasps an object's end point, and calculate the object's center of mass' (COM) acceleration via the robot's end-effector's motion data. Then, I integrate the acceleration to obtain the velocity of the object's COM. The robot standing still untill 4 seconds, then starts to generate the motion.
However, the output of the integrator (velocity) does not match with the input ( calculated COM acceleration). First of all, the sign of the input and the output is different. The input goes to minus but the output goes to the plus.
When I used actual value of the COM acceleration as the input of the integrator, the sign of the output was same as the input. When I used lsim to integrate the calculated COM acceleration by using simulink's integrator model (https://kr.mathworks.com/help/simulink/slref/integrator.html), the sign of the input and the output were same. What made this difference and how can I solve it?
I'll attach the actual and calculated acceleration of COM and it's integration (velocity) of my simulation. Each data's 1st column is time, 2nd to 4th columns are x, y, z directional data, respectively. I used ode4 (Runge-Kutta) of Fixed-step.
  9 个评论
Jaeyoung Jang
Jaeyoung Jang 2023-1-1
编辑:Jaeyoung Jang 2023-1-2
  1. No, RecurDyn gives 'actual' acceleration of the COM. For 'calculated', I made MATLAB function to calculate the accleration of the COM with the linear and angular acceleration, angular velocity of the end-effector, and distance between the robot's grasping point and COM.
  2. Both acceleration are exactly same (of course there is some numerical error, but that is very small). The problem is velocity. If you are asking about the pertubation from t = 0 in 'actual' case and no pertubation in 'calculated' case, I just set the 'calculated' acceleration to 0 because the motion starts at t = 4, and you can see the 'actual' acceleration becomes 0 before t = 4.
  3. Yes. and I didn't change any setting of both of them.
Paul
Paul 2023-1-3
In short, the Simulink model has two integrators. Each integrator has identical settings. Each has a separate input, but the inputs are essentially identical functions of time. However, the outputs of each integrator are very different.
If that's the observation, I'm afraid I can't be of any more help. If you attach a .slx file that illustrates the observed behavior (not necessarily the entire model, just the two integrators and a means to generate the integrator inputs), someone might be willing to download that .slx file and try to replicate what you're seeing and offer a path forward.

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 General Applications 的更多信息

产品


版本

R2015a

Community Treasure Hunt

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

Start Hunting!

Translated by