Tracking and modifying human motion with dynamic simulation