Closed niksknocksu closed 2 years ago
Hmmm... This looks like a problem in the user-supplied dynamics function. Is it properly vectorized? It should return an array with size of '[nState, nTime]' when passed the state and time at every collocation point.
The 'Chebyshev' method is somewhat less rigorously tested than other methods. I suggest avoiding it and using either the trapezoid or Hermite--Simpson methods instead.
That was indeed the problem. I didn't realize that the function had to be vectorized.
Thank you very much!
I get the following error while using trapezoid/rungeKutta methods only. My problem is of a reentry vehicle optimization with 8 states, 2 controls, and an objective to minimize time. I can use the Chebyshev method though it never converges.