>> w = arrayfun(@(x) sum(arrayfun(@(m) quad(@(u) sin(m*pi/2).*cos(u*x).*sin(m*pi/2+u.^2),0,50),1:100)),-2*pi:0.1*pi:2*pi,'UniformOutput',false);>> plot(-2*pi:0.1*pi:2*pi,cell2mat(w))