This study addresses the problem of optimal resource allocation in nonlinear multi-module dynamic systems arising in complex computational and techno-economic processes, where numerical stability and strict enforcement of structural constraints are critical. The objective is to develop a computationally efficient optimal control algorithm capable of handling bilateral control constraints and external balance conditions without resorting to large-scale nonlinear programming or boundary-value shooting. The proposed method is based on a modified Lagrangian formulation, in which bilateral Karush–Kuhn–Tucker (KKT) conditions are analytically embedded into the optimality system. The resulting computational scheme consists of a coupled system of matrix and vector differential equations solved through a non-iterative backward–forward integration procedure. Numerical experiments conducted on a nonlinear model with Cobb–Douglas-type operators demonstrate the stable convergence of the trajectories toward a stationary regime, strict satisfaction of bilateral constraints, and consistent enforcement of balance relations throughout the planning horizon. Empirical scalability analysis indicates approximately cubic computational complexity with respect to the state dimension, while sensitivity tests confirm the numerical robustness across different integration tolerances and ODE solvers. These results demonstrate that the proposed structure-preserving framework provides a computationally stable and practically implementable approach to constrained optimal control in nonlinear multi-module systems.
Tussupova et al. (Mon,) studied this question.