Hi~

The differential equations that describe the movement of a robotic arm can be written in the following form:

M(q) * q_ddot + C(q,q_dot) * q_dot + G(q) = τ

Can the inertia matric M , coriolis and centripedal forces matrix C and the gravity vector G be set in V-REP?

And then I use MATLAB to input a torque which is a function of time.

According to the above equation,the robot in V-REP will move.

Finally I can record the joint angle by the function vrep.simxGetJointPosition() in MATLAB.

## Can V-REP simulate a robot dynamics equation?

### Re: Can V-REP simulate a robot dynamics equation?

Hello,

for each shape, you can set a mass and an inertia matrix in this dialog. Beware however that the principal moment of inertia or the inertia is divided by the mass in the dialog (to have mass and inertia independent).

The gravity vector can be adjusted in this dialog.

Above values can also be adjusted programmatically.

Cheers

for each shape, you can set a mass and an inertia matrix in this dialog. Beware however that the principal moment of inertia or the inertia is divided by the mass in the dialog (to have mass and inertia independent).

The gravity vector can be adjusted in this dialog.

Above values can also be adjusted programmatically.

Cheers

### Re: Can V-REP simulate a robot dynamics equation?

Thanks~

What about the torque?How can I set it by MATLAB?

The above code seems to have only set the maximum joint torque.

What about the torque?How can I set it by MATLAB?

Code: Select all

`vrep.simxSetJointForce(clientID,joint1,force,vrep.simx_opmode_oneshot);`

The above code seems to have only set the maximum joint torque.

### Re: Can V-REP simulate a robot dynamics equation?

simxSetJointForce is the function you should use. For torque control, make sure that the target joint velocity is quite high (simxSetJointTargetVelocity).

Cheers

Cheers

### Who is online

Users browsing this forum: Baidu [Spider], Yahoo [Bot] and 4 guests