Estimation and Control of Nonlinear Hybrid Systems and Nonaffine Control