It really helps a lot. However, what if I want to set the condition that the parameters s(i)>0? Look, t1={384,1186,1471,2236,2772,2967,3812,4880,6104} and y1={13,18,26,34,40,48,61,75,84}, I got that S(i) are a+bi like stuff, what I really want to get is the real number. Again, t2={254,788,1054,1393,2216,2880,3593,4281,5180} and y2={1,3,8,9,11,16,19,25,27}, then S(5)<0 rather than the positive I want to obtain.