Optimal Coverage in Wireless Sensor Networks