Robot Effort
Description
Added robot effort to Movement Analysis, which can be used with user effort to calculate the percentage of user effort in a movement. I also made a change to how we calculate tool (endpoint) work in the movement analysis code.
Tool work was being calculated as the dot product of the user estimated force (output of dist obsv) and what is essentially the tool velocity (_deltaPos is the differential position over one time step). I added a time delay to the _deltaPos
signal (change in position) before taking its dot product with the dist obsv force to get work. That's because there is already a time delay in the disturbance observer due to its use of filters and integrals. By adding the time delay to the deltaPos signal, they line up better in time.
The _deltaWork
signal is the result of this dot product, and it is the tiny amount of work done over a single time step. It can be positive or negative. Because of the way we defined the user force to be force applied by the user on the robot, positive deltaWork is work done by the user and negative deltaWork is work done by the robot. So I just use the "strictly positive" summation objects called _userEffort
and _robotEffort
to accumulate positive deltaWork for the user and negative deltaWork for the robot.
The formula we will then use in a Burt activity to report the percentage of user contribution to a movement will be userEffort / (userEffort + robotEffort).
What to focus on
- Use MovementAnalysisTest program in Sandbox to see robot effort vs user effort (make use of robot generated forces).