How can I terminate FD integration before the final time?

Provide easy-to-use, extensible software for modeling, simulating, controlling, and analyzing the neuromusculoskeletal system.
POST REPLY
User avatar
Sina Porsa
Posts: 99
Joined: Thu Feb 03, 2011 7:21 pm

How can I terminate FD integration before the final time?

Post by Sina Porsa » Thu Apr 11, 2013 5:02 pm

Hi everyone
I am an API user and I was wondering if there is a way to terminate forward dynamic integration before reaching to the preset "Final Time".
For example is there any way to terminate the integration if a parameter (e.g hip angle) reaches to a limit value?
Thanks
Sina

User avatar
Michael Sherman
Posts: 807
Joined: Fri Apr 01, 2005 6:05 pm

Re: How can I terminate FD integration before the final time

Post by Michael Sherman » Thu Apr 11, 2013 5:26 pm

Hi, Sina. The easy way to do that is to run for a series of shorter intervals and check for the termination condition in between. For example, you could stop every 0.5 seconds. It is much trickier if you have to catch the exact moment at which the condition is met (can be done with event handlers), but if having a little slop is acceptable then this is a nice way to do it.

Regards,
Sherm

POST REPLY