Commit d19a71ea authored by Jesper Andersson's avatar Jesper Andersson
Browse files

Fixed problem with long colormaps on recent Matlab versions

parent 5ad2bc2c
......@@ -26,6 +26,7 @@
[x,y] = ndgrid(-1.5:0.05:2,-1:0.05:3); % Grid on which to calculate function
rosen = (1-x).^2 + 100*(y-x.^2).^2; % Function values on grid
figure('Position',[100 100 800 800]);
colormap(jet(64));
surfc(x,y,rosen,'EdgeColor',[.5 .5 .5]);
xlabel('x');
ylabel('y');
......@@ -190,6 +191,7 @@ refresh_rosenbrock(x,y,lcm,pp);
z = 3 * (1-x).^2 .* exp(-(x.^2) - (y+1).^2) - 10 * (x/5 - x.^3 - y.^5) .* exp(-x.^2 - y.^2) - 1/3 * exp(-(x+1).^2 - y.^2);
figure('Position',[100 100 800 800]);
colormap(jet(64));
surfc(x,y,z,'EdgeColor',[.5 .5 .5]);
xlabel('x');
ylabel('y');
......@@ -422,6 +424,7 @@ for i=1:size(beta1,1)
end
end
figure('Position',[100 100 800 800]);
colormap(jet(64));
surfc(beta1,beta2,sse,'EdgeColor',[.5 .5 .5]);
xlabel('b1');
ylabel('b2');
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment