13 January 2022 at 5 h 46 min #21382
As discussed, I was hoping to create some respiratory motion for my simulation and I was wondering how I could achieve this? Thanks13 January 2022 at 9 h 53 min #21393
Thanks for posting it on the forum.
The way I would recreate a desired motion of an object would be to implement this change of position (dofs) as a controller, whether a python or a C++ one, which would overwrite the new positions of your object at each time step.
For oscillatory motion, we also have a projective constraint (similar to what I wrote just previously, projecting at the end of the time step the new positions) named: OscillatorConstraint.
Would this suit you?
Is a whole object moving or would you like just to impose an oscillatory motion of a part of an object?
Hugo14 January 2022 at 6 h 20 min #21401
@Hugo Thank you! The OscillatorConstraint does the job, I think I would like to later implement this as a controller. In my case, the whole object is moving, is there a way I can achieve this too? Thanks 🙂14 January 2022 at 11 h 56 min #21402
Great that OscillatorConstraint does the job!
Regarding a later implementation as a controller, all you would need in your controller is a link to the MechanicalObject of your object so that you can write in it the new position at each time step.
The MechanicalStateController (C++ class in SOFA) could be worth looking at.
—14 January 2022 at 21 h 33 min #21403
Regarding the forum migration, interesting move. Does this mean that in the future, users will be unable to ask questions on the SOFA Forum?17 January 2022 at 8 h 46 min #21404
Correct. Starting from this week:
– new registration on the Forum will be prevented and redirected towards GitHub Discussions
– Users will not be able to create new topics
– All admin replies will include the footer your noticed
The issue #2591 has been opened for you to follow the migration process.
Any feedback is most welcome.
—17 January 2022 at 12 h 27 min #21407
I see. For what it’s worth, I think it’s a good move
- You must be logged in to reply to this topic.