When solving an optimal control problem with both direct and indirect approaches, the main technique is to transfer the optimal control problem from the class of infinite-dimensional optimization to a finite-dimensional one. However, with all these approaches, the result is an open-loop program control that is sensitive to uncertainties, and for the implementation of which in a real object it is ... [Show full abstract] necessary to build a stabilization system. The introduction of the stabilization system changes the dynamics of the object, which means that the optimal control and the optimal trajectory should be calculated for the object already taking into account the stabilization system. As a result, it turns out that the initial optimal control problem is complex, and often the possibility of solving it is extremely dependent on the type of object and functionality, and if the object becomes more complex due to the introduction of a stabilization system, the complexity of the problem increases significantly and the application of classical approaches to solving the optimal control problem turns out to be time-consuming or impossible. In this paper, a synthesized optimal control method is proposed that implements the designated logic for developing optimal control systems, overcoming the computational complexity of the problem posed through the use of modern machine learning methods based on symbolic regression and evolutionary optimization algorithms. According to the approach, the object stabilization system is first built relative to some point, and then the position of this equilibrium point becomes a control parameter. Thus, it is possible to translate the infinite-dimensional optimization problem into a finite-dimensional optimization problem, namely, the optimal location of equilibrium points. The effectiveness of the approach is demonstrated by solving the problem of optimal control of a mobile robot.