Update ik.c

bugfix - q_min1 is a negative number, q_max1 a positiove... same for q_min2...