A Hybrid Optimal Control Approach To Multi-Aircraft Formation Flying