Analytic solution to indefinite linear quadratic regulator for stochastic systems