kill(all)$

van=facebook.com/LearningCalculus$

f(x,n):=sum(sum(sin(i*x)*sin(j*x),j,i+1,n), i, 1,n-1);

f(x,n);

f(x,4);

f(%pi/4,2019);