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

Restricting quaternion sign interferes with odeint #4

Open
translunar opened this issue Jan 24, 2020 · 0 comments
Open

Restricting quaternion sign interferes with odeint #4

translunar opened this issue Jan 24, 2020 · 0 comments
Labels
bug Something isn't working

Comments

@translunar
Copy link
Collaborator

I narrowed down the problem to translunar@a2da759.

When using odeint with qdot for quaternion propagation, sometimes odeint gives errors that look like this:

Solving ODE
 lsoda--  warning..internal t (=r1) and h (=r2) are
       such that in the machine, t + h = t on the next step  
       (h = step size). solver will continue anyway
      in above,  r1 =  0.1198705359199D+02   r2 =  0.8575714648946D-15
 lsoda--  warning..internal t (=r1) and h (=r2) are
       such that in the machine, t + h = t on the next step  
       (h = step size). solver will continue anyway
      in above,  r1 =  0.1198705359199D+02   r2 =  0.5846098197682D-15
 lsoda--  warning..internal t (=r1) and h (=r2) are
       such that in the machine, t + h = t on the next step  
       (h = step size). solver will continue anyway
      in above,  r1 =  0.1198705359199D+02   r2 =  0.8353495261073D-15
 lsoda--  at current t (=r1), mxstep (=i1) steps   
       taken on this call before reaching tout     
      in above message,  i1 =       500
      in above message,  r1 =  0.1198705359199D+02
/home/mohawkjohn/.local/lib/python2.7/site-packages/scipy/integrate/odepack.py:218: ODEintWarning: Excess work done on this call (perhaps wrong Dfun type). Run with full_output = 1 to get quantitative information.
  warnings.warn(warning_msg, ODEintWarning)

I suspect that one of the propagated quaternions is developing a negative scalar component, pyquat is detecting that and negating the entire quaternion, and that creates a discontinuity that odeint observes.

I'm not sure how to fix the problem at the moment (or if it should be fixed, since it isn't technically a pyquat bug), but I'm listing it here so other people don't get caught by the same problem.

Copied over from https://github.com/autumnsault/pyquat/issues/8

@translunar translunar added the bug Something isn't working label Jan 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant