The aim of this article is to present algorithms to compute the first
conjugate time along a smooth extremal curve, where the trajectory
ceases to be optimal. It is based on recent theoretical developments
of geometric optimal control, and the article contains a review
of second order optimality conditions.
The computations are related to a test
of positivity of the intrinsic second order derivative or a test of
singularity of the extremal flow. We derive an algorithm called COTCOT
(Conditions of Order Two and COnjugate Times), available on the web,
and apply it to the minimal time problem of orbit transfer, and to the
attitude control problem of a rigid spacecraft.
This algorithm involves both normal and abnormal cases.