Removed bug in calculation of Gaits and Steps