Stochastic modeling and availability optimization of wireless sensor network through particle swarm optimization