removed dup variable from sine func