Gait model using motor torques