Stochastic Approximation and Optimization of Random Systems