Motor control theory and practical applications