Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Declaration LoopConstraint #326

Open
AnaisFarr opened this issue May 10, 2023 · 2 comments
Open

Declaration LoopConstraint #326

AnaisFarr opened this issue May 10, 2023 · 2 comments

Comments

@AnaisFarr
Copy link
Contributor

Good news @Ipuch , LoopConstraint works !

We created an example of a triple bar with the bar2 and 3 are attached with the loopconstraints.
The simulated movement makes the bar2 fall with the gravity (the bar2, attached to the bar1, have an angle of 90°).
The bar3 stay attached by the loopconstraints to the bar2 when the loopconstraints is declared 2 times in the BioMod (one for each axis).

loopconstraint
    predecessor Bar2
    successor Bar3
    RTpredecessor 0 0 0 xyz 0 -1 0
    RTsuccessor 0 0 0 xyz 0 0 0
    axis 0 0 0 0 1 0 // in predecessor frame
    enableStabilization 1
    stabilizationParameter 0
endloopconstraint

loopconstraint
    predecessor Bar2
    successor Bar3
    RTpredecessor 0 0 0 xyz 0 -1 0
    RTsuccessor 0 0 0 xyz 0 0 0
    axis 0 0 0 1 0 0 // in predecessor frame
    enableStabilization 1
    stabilizationParameter 0
endloopconstraint

It doesn't work if the two axis are declared in the same loopconstraints.

We tried to simulate the same thing by calculating the external forces and by introducing these external forces in the calculation of the dynamics. It works when the pendulum doesn't move. We have created an example with three pendulums aligned in y and with gravity in y. The bar3 remains attached to the bar2 in this case. But as soon as there are several loop constraint, we can not make it work, we have the error :

Process finished with exit code 139 (interrupted by signal 11: SIGSEGV)
@Ipuch
Copy link
Collaborator

Ipuch commented May 12, 2023

Nice advancement. I can't wait to see the results and talk about it !

@pariterre
Copy link
Member

This is the expected behavior that it won't work, this is on RBDL side... Maybe we could raise a more descriptive error though...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants