RHS3DOrbit:

--------------------------------------------------------------------------
   This function is the right-hand-side for the 3D orbit optimization problem.
   This function is specifically for the minimum time problem. It is designed
   to be called by ode113. The terminal condition is the inclination.
   This routine can handle equinoctial or cartesian elements. Partials of the
   state equations with respect to the states are done by a first difference
   approximation.
   See also LocallyOptimalTrajectories.

   Since version 7.
--------------------------------------------------------------------------
   Form:
   varargout = RHS3DOrbit( t, x, flag, d )
--------------------------------------------------------------------------

   ------
   Inputs
   ------
   t          ( 1,1)  TIme
   x          (12,1)  States [elements;lambda]
   flag       ( 1,1)  Flag from ode113
   d          ( 1,1)  Structure to pass to the integration RHS
                      .accel (1,1) The acceleration

   -------
   Outputs
   -------
   xDot       (12,1)  State derivatives d[elements;lambda]/dt

   or

   vnew       ( 1,1)  Value of constraint
   isterminal ( 1,1)  1 if a terminal constraint  
   direction  ( 1,1)  Direction  

--------------------------------------------------------------------------

Children:

Sail: Coordinates/CartToI
Sail: OrbitDynamics/RHSCartesian
Sail: OrbitDynamics/RHSEquinoctial