Application of singular perturbation theory to onboard aircraft trajectory optimization