It's a stupid question but these two line of code do the same thing wthere dt1 is a constant. Is it right?
prova= sum((out1.Y{i}(:,3:end)).^2)*dt1;h=1;for i=3:end;y1=out.Y(:,i); prova(h)=sum(y1.^2)*dt1; h=h+1;end;
difference
prova= sum((out1.Y{i}(:,3:end)).^2)*dt1;h=1;for i=3:end;y1=out.Y(:,i); prova(h)=sum(y1.^2)*dt1; h=h+1;end;
Best Answer