do we really need to make a separate variable for joint name? why not just continue to use joint_names_[j] everywhere?