Is there a way to lock a prismatic joint during a SimScape simulation?

13 visualizaciones (últimos 30 días)
Toby
Toby el 23 de Feb. de 2017
Comentada: Tommaso Vannuccini el 23 de Sept. de 2022
Is there a way to lock a prismatic joint during a SimScape simulation?
I'm modeling a linear brake between two bodies connected by a prismatic joint in SimScape second generation. Until now, I've implemented this by applying an actuator force to the prismatic joint equal to F_act = F_n*Cf*tanh(k*v_rel), where F_n is the normal force, Cf is a kinetic coefficient of friction, v_rel is the relative velocity, and k is a coefficient such that the tanh function approximates the combined Coulomb and viscous friction effects.
This approach works, but when the brake is applied, the simulation solves very slowly, because it becomes an extremely stiff system. I would like to replace this formulation with something that locks the bodies together when the relative velocity is below a certain threshold.
I've tried putting a motion-actuation prismatic joint in parallel with the first joint. The idea was to switch the motion input between zeros (i.e. locked together) and the motion output of the first prismatic joint. But this results in algebraic loops, and the simulation freezes after a few seconds.
I'd welcome any better ideas.
Thanks.
PS I think what I'm trying to do is similar to the behavior of the Loaded-Contact Translational Friction block in Simscape Driveline. But I'd like to implement a solution that doesn't depend on another SimScape package.

Respuestas (1)

Mark Wang
Mark Wang el 17 de Jun. de 2020
In Sismscape Multibody, I just parallel the joint that we want to lock and unlock during the simulation with a weld joint. The weld joint's mode is set to "provided by input". And you can edit the input so as to make the weld joint works and lock your joint or disengage the weld joint and unlock your joint.
  3 comentarios
Mark Wang
Mark Wang el 22 de Oct. de 2020
I’m sorry for I ignore the matlab answers for some time. The model I built is like this.You may also see the model slx file. The model is in matlab2020a. The parallel was in the module Mysp1.
Tommaso Vannuccini
Tommaso Vannuccini el 23 de Sept. de 2022
Hi Mark!
I had the same idea as you. My problem is that instead of a Gimbal Joint I am using a Prismatic Joint. I am experiencing a problem when activating the Weld Joint. I control the Prismatic Joint with a Force control and then at a certain point I would like the Prismatic Joint to deactivate (and thus send a null force input to the prismatic joint) and activate the Weld Joint, and I would like this to lock the Prismatic Joint in the position it assumes when the Weld Joint is activated. The problem is that I get an error message from Matlab:
An error occurred while running the simulation and the simulation was terminated
Caused by:
  • ['prova_cilindro__2022/Solver Configuration']: The position components of the kinematic constraints of the mechanism cannot be satisfied when attempting to transition joints from disengaged to normal mode. This is more likely to occur for large rotation errors compared to large translation errors. Consider reducing the error in those joints before attempting the transition or consider increasing the joint mode transition nonlinear iterations parameter in the associated Mechanism Configuration block.
Component:Simulink | Category:Block erro
I understand the reason for the error.
My question is whether it would be possible to impose the position of the Weld Joint (in particular, to impose it equal to the position of the Prismatic Joint at the time of the switch) in such a way as to prevent it from bringing the two centres of gravity of the bodies connected by the Prismatic Joint back to coincide.
An alternative solution could be to mount two Prismatic Joints in parallel and control one in Force and one in Position, keeping the one controlled in Position disabled until the switch between the two Prismatic Joints is made. But this solution has two problems:
1) It does not seem to be possible to have a Prismatic Joint that has the command port in position (but the same error is also obtained with the command in force) while it is being disengaged
2) It is not accepted to communicate the position of the force-controlled Prismatic Joint as the position control input of the second Prismatic Joint
Thank ou for your time,
Tommaso

Iniciar sesión para comentar.

Categorías

Más información sobre Brakes and Detents en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by