Scientists have created a flexible robot that moves like an earthworm by contracting the segments of its body.

Researchers at the Massachusetts Institute of Technology (MIT), Harvard University and Seoul National University have created a robot named "Meshworm" based on a method known as peristalsis that earthworms use, when they move forward by contracting their body.

Unlike other robots, the "Meshworm" looks more flexible and unbreakable which can be used to explore hard-to-reach spaces.

In order to create the robot, researchers studied the earthworm for their design. They noticed that the earthworm had two muscle groups - longitudinal muscle fibers which run along its length and circular muscle fibers which are wrapped around the worm's body - both of them worked together for their forward movements.

The researchers also followed the same mechanism and created a long tube-like body that is very flexible. Then they created an "artificial muscle" using wires made of nickel and titanium that can stretch and contract when exposed to heat. They wound the wire around the lengthy tube-like body to create artificial circular muscle fibers.

Using a circuit board, the researchers generated current to heat the wire on certain segments of the body. As the temperature reached a level, the wires contracted which in turn caused the tube to squeeze, thus propelling the robots forward movements.

In addition to the two artificial muscles, two more muscle fibers were attached on the sides of the robot's body to move them left and right. The robots were able to move at a speed of 0.2 inches per second.

The soft robot was so flexible that it did not get damaged despite various attempts by the researchers like stepping on to it or hitting it with a hammer. "You can throw it, and it won't collapse," researcher Sangbae Kim from the MIT said in a statement. "Most mechanical parts are rigid and fragile at small scale, but the parts in Meshworms are all fibrous and flexible. The muscles are soft, and the body is soft ... we're starting to show some body-morphing capability."

Researchers hope that such soft and flexible robots can be used on rough terrains in the future.

The details of the design are published in the journal IEEE/ASME Transactions on Mechatronics.