Why when performing numerical integration in Matlab with integral does this case need 'ArrayValued' to be set to true:
f = @(x) 5;
integral(f,0,2,'ArrayValued',true)
... while in this case the option isn't needed?:
f = @(x) x;
integral(f,0,2)