Energy effciency of dense wireless sensor networks: To cooperate or not to cooperate