In biomechanics, animal locomotion is the study of how animals move. Not all animals move, but locomotive ability is widespread throughout the animal kingdom. As all animals are heterotrophs, they must obtain food from their environment. Some animals such as sponges are sessile, and move the fluid in which they live through their body (this is known as filter feeding). However, most animals must move around to find food, a mate, and so forth. Ability to do so efficiently is therefore essential to their survival.
Locomotion requires energy to overcome friction and often gravity as well. In terrestrial environments gravity must be overcome, though the friction of air is much less of an issue (except for crawling animals like worms, for which friction is much higher). In aqueous environments however, friction (or drag) becomes the major challenge, with gravity being less of a concern. Although animals with natural buoyancy need not expend much energy maintaining vertical position, though some will naturally sink and must expend energy to remain afloat. Friction may also present a problem in flight, and the aerodynamically efficient body shapes of birds highlight this point. Flight presents a different problem from movement in water however, as there is no way for a living organism to have lower density than air.
Much of the study is an application of Newton's third law of motion: if at rest, to move forwards an animal must push something backwards. Terrestrial animals must push the solid ground, swimming and flying animals must push against a fluid or gas (either water or air).
Classification
Animals move through a variety of fluids, such as water, air and mud. Some may move through more than one, such seals and otters. In some cases locomotion is facilitated by the substrate on which they move. Forms of locomotion include:
Through a fluid medium
Swimming

In the water staying afloat is possible through buoyancy. Provided an aquatic animal's body is no denser than its aqueous environment, it should be able to stay afloat well enough. Though this means little energy need be expended maintaining vertical position, it makes movement in the horizontal plane much more difficult. The drag encountered in water is much higher than that of air, which is almost negligible at low speeds. Body shape is therefore important is efficient movement, which is essential for basic functions like catching prey. A fusiform, torpedo-like body form is seen in many marine animals, though the mechanisms they employ for movement are diverse. Movement of the body may be from side to side, as in sharks and many fishes, or up and down, as in marine mammals. Other animals, such as those from the class Cephalopoda, use jet-propulsion, taking in water then squirting it back out in an explosive burst. Others may rely predominantly on their limbs, much as humans do when swimming. Though life on land originated from the seas, terrestrial animals have returned to an aquatic lifestyle on several occasions, such as the fully aquatic cetaceans, now far removed from their terrestrial ancestors.
Flight

Gravity is a major problem for flight through the air. Because it is impossibly for any organism to approach the density of air, flying animals must generate enough lift to ascend and remain airborne. Wing shape is crucial in achieving this, generating a pressure gradient that results in an upward force on the animal' body. The same principle applies to airplanes, the wings of which are also airfoils. Unlike aircraft however, flying animals must be very light to achieve flight, the largest birds being around 20 kilograms.[2] Other structural modifications of flying animals include reduced and redistributed body weight, fusiform shape and powerful flight muscles.
Rather than fly, some animals simply reduce their rate of falling by gliding. Flight has independently evolved at least four times, in the insects, pterosaurs, birds, and bats. Gliding has evolved on many more occasions. The advantage gliding provides to arboreal animals provides a bridge for the evolution of flight.