I don't know if someone can help me with this but I'm calculating the dynamics of a 6DOF robot using the Newton-Euler iterative dynamics algorithm. I'm following the recursive method (inwards and outwards) explained in the book Introduction to Robotics Mechanics and Control (Pages 175-176). After putting down on MATLAB the calculations, I started to check if the gravity compensation, g term, made sense. I had calculated the gravity term from the Lagrange approach before so I knew the set of torques had to be the same for a specific pose. Although the values are almost similar (one actuator has some considerable deviation, still unknown to me as to why). Now, here's the thing: the robot is the Kinova JACO v2 arm, and if one assumes that only the gravity effect is taking place, no torque is assumed for the first actuator (its associated link is at the base). Indeed this is visually clear, and the Lagrangian approach based on the potential energy corroborates that, giving me a torque vector with no torque being sent to the first actuator.
My problem is just that... The Newton-Euler iterative algorithm is based on the balance of the forces between the links. And since the contributions of the forces are summed up (when performing the outwards calculations) the torque sent for the actuator 1 is not zero and has actually the value that would be sent to the actuator 2. Basically a "shift" was made, and the torque for actuator 1 should've been for actuator 2, and so on.
I don't know if you can get any insight from this... But I've tried to recheck my calculations and I can't seem to find any problem with them... Please if you have any suggestions I'll be grateful.