Real-time algorithm for self-reflective model predictive control. (May 2018)