Stochastic Modeling and Analysis with Energy Optimization for Wireless Sensor Networks. (12th May 2014)