-
Notifications
You must be signed in to change notification settings - Fork 209
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
Bug (?) in OptimTraj wrapper for GPOPS? #19
Comments
If it works natively in GPOPS, but not when called from OptimTraj, then it is probably a bug. One thing to check is that you've properly converted the problem into OptimTraj, since it uses the opposite matrix transpose orientation when compared to GPOPS. Have you checked to make sure that the other methods in OptimTraj are able to solve the problem correctly? |
Yes, all the other OptimTraj methods (trapezoidal, Hermite-Simpose, Runge-Kutta, and Chebyshev) correctly solve the problem. |
Hmm... Sounds like a bug! Unfortunately, I no longer have a license for GPOPS-II, so I can't do the debugging myself. It would be great if you or someone else with a license would be able to play around and see if you can find the bug. I have a few ideas that might be helpful:
|
I faced a similar issue and fixed it by carefully going through matrix transpose orientations. |
@mhuzaif2 - did you find a bug in the OptimTraj implementation while you were investigating this issue, or was it something in your code? If you did find a bug in OptimTraj, it would be great if you could make a pull request that fixed it (or just add enough detail for someone else to implement the fix). Thanks! |
@MatthewPeterKelly - This one was a bug in my code. I just wanted to confirm that the difference of convention might have been overlooked. |
@mhuzaif2 - Thanks for the update! You're responses provide good context here. |
I'm having some trouble getting the OptimTraj gpops method to work on my problem in certain cases. Do you know what might be causing the error below? I think this error may be related to how OptimTraj wraps GPOPS-II, because whenever I use GPOPS-II independently from OptimTraj on my optimal control problem, I never get this error.
| |
| Finding Solution on Mesh 2 |
|___________________________________________________________________|
Computing Radau Points, Integration Weights, and Integration Matrix
Creating Bounds For Nonlinear Program
Creating Guess For Nonlinear Program
Error using griddedInterpolant
Interpolation requires at least two sample points in each dimension.
Error in interp1 (line 161)
F = griddedInterpolant(X,V,method);
Error in gpopsGuessRPMI
Error in gpopsSolveRPMI
Error in gpopsMeshShell
Error in gpops2
Error in gpopsWrapper (line 84)
output = gpops2(setup);
Error in optimTraj (line 190)
soln(iter) = gpopsWrapper(P);
Error in invoke_OptimTraj (line 176)
soln = optimTraj(problem);
The text was updated successfully, but these errors were encountered: