% We perform ten trajectory optimizations to the same target, and record % the varibility from run-to-run here: task_cost = [0.000471874; 9.93938e-05; 0.00021606; 0.000291473; 0.0021494; 0.000906142; 0.000631215; 0.000437178; 0.000226504; 0.000220305]; act_cost = [0.0182577; 0.0191459; 0.020125; 0.0153004; 0.016475; 0.0191889; 0.0177432; 0.0167409; 0.0198013; 0.0158841]; total_cost = [0.0346219; 0.0353378; 0.0357727; 0.031016; 0.0339422; 0.0347215; 0.0331149; 0.0337079; 0.0379525; 0.0331537]; display(' variability in the total cost percentage relative to the mean'); std(total_cost)/mean(total_cost) * 100 task_weight = 5; display('Variability from run-to-run in the final hand position in cm') std(sqrt(task_cost/task_weight) * 100) display('Variability in the percentage of effort relative to the mean') std(act_cost/(mean(act_cost))) * 100 %{ 1. min result: 0.0346219 actual position: 0.12144 - -0.146672 - 0.343874 rand effect position: 0.117644 - -0.15 - 0.352174 task_term: 0.000471874 activation cost: 0.0182577 joint limits costs: 0.000842249 velocity term: 0.000868267 velocity: ~[-0.000768134,0.000862947,0.00567198] pro sup: 0.0141819 wrist term: 1.23522e-24 hold term: 0 jerk cost: 0 sum pro sup diff: 0 f: 0.0346219 2. actual position: 0.115301 - -0.147631 - 0.355137 rand effect position: 0.117644 - -0.15 - 0.352174 task_term: 9.93938e-05 activation cost: 0.0191459 joint limits costs: 0.000799011 velocity term: 0.00299083 velocity: ~[0.0094547,-0.0050546,0.0168113] pro sup: 0.0123026 wrist term: 7.69669e-25 hold term: 0 jerk cost: 0 sum pro sup diff: 0 f: 0.0353378 by rank 12 3. actual position: 0.11645 - -0.153444 - 0.346704 rand effect position: 0.117644 - -0.15 - 0.352174 task_term: 0.00021606 activation cost: 0.020125 joint limits costs: 0.000542811 velocity term: 0.00103455 velocity: ~[-0.000220499,8.30712e-05,-0.00689294] pro sup: 0.0138543 wrist term: 5.53067e-27 hold term: 0 jerk cost: 0 sum pro sup diff: 0 f: 0.0357727 by rank 0 4. actual position: 0.124858 - -0.149562 - 0.354635 rand effect position: 0.117644 - -0.15 - 0.352174 task_term: 0.000291473 activation cost: 0.0153004 joint limits costs: 0.000476504 velocity term: 0.000833114 velocity: ~[0.00476606,0.000223626,0.002843] pro sup: 0.0141144 wrist term: 2.49783e-25 hold term: 0 jerk cost: 0 sum pro sup diff: 0 f: 0.031016 by rank 0 5. actual position: 0.13652 - -0.147408 - 0.36035 rand effect position: 0.117644 - -0.15 - 0.352174 task_term: 0.0021494 activation cost: 0.016475 joint limits costs: 0.000560444 velocity term: 0.000440801 velocity: ~[-0.00153384,-0.00135333,-0.00210989] pro sup: 0.0143165 wrist term: 8.53138e-27 hold term: 0 jerk cost: 0 sum pro sup diff: 0 f: 0.0339422 by rank 2 6. actual position: 0.124692 - -0.142232 - 0.360612 rand effect position: 0.117644 - -0.15 - 0.352174 task_term: 0.000906142 activation cost: 0.0191889 joint limits costs: 0.000394978 velocity term: 0.0006548 velocity: ~[0.00424671,0.000647898,0.000775801] pro sup: 0.0135766 wrist term: 2.36905e-26 hold term: 0 jerk cost: 0 sum pro sup diff: 0 f: 0.0347215 by rank 4 7. min result: 0.0331149 actual position: 0.120981 - -0.139307 - 0.353045 rand effect position: 0.117644 - -0.15 - 0.352174 task_term: 0.000631215 activation cost: 0.0177432 joint limits costs: 0.000728183 velocity term: 0.00303064 velocity: ~[-0.0201066,-0.00192261,-0.000489273] pro sup: 0.0109817 wrist term: 2.38677e-26 hold term: 0 jerk cost: 0 sum pro sup diff: 0 f: 0.0331149 by rank 0 8. actual position: 0.118321 - -0.152548 - 0.343203 rand effect position: 0.117644 - -0.15 - 0.352174 task_term: 0.000437178 activation cost: 0.0167409 joint limits costs: 0.000723519 velocity term: 0.000245675 velocity: ~[0.00132942,0.00045555,0.000841198] pro sup: 0.0155606 wrist term: 3.39842e-25 hold term: 0 jerk cost: 0 sum pro sup diff: 0 f: 0.0337079 by rank 0 9. actual position: 0.122246 - -0.154577 - 0.353955 rand effect position: 0.117644 - -0.15 - 0.352174 task_term: 0.000226504 activation cost: 0.0198013 joint limits costs: 0.000582413 velocity term: 0.000901806 velocity: ~[-0.00241949,0.0053814,-0.00115378] pro sup: 0.0164405 wrist term: 9.29697e-26 hold term: 0 jerk cost: 0 sum pro sup diff: 0 f: 0.0379525 by rank 6 10. actual position: 0.117776 - -0.151299 - 0.345666 rand effect position: 0.117644 - -0.15 - 0.352174 task_term: 0.000220305 activation cost: 0.0158841 joint limits costs: 0.00069569 velocity term: 0.00149888 velocity: ~[-0.0030961,0.00628761,-0.00712257] pro sup: 0.0148547 wrist term: 2.90771e-25 hold term: 0 jerk cost: 0 sum pro sup diff: 0 f: 0.0331537 by rank 0 %}