Text this: Energy-Efficient Chain Formation Algorithm for Data Gathering in Wireless Sensor Networks