% This script generates a loglog plot of y = x^2 for 1 < x < 100 % % Use the logspace command to generate x values rather than the linspace % command. 1 = 10^0 and 100 = 10^2, so the input to logspace is the pair % 0, 2 % x = logspace (0,2); % % Calculate y as usual % y = x.^2; % % Use the command loglog instead of plot % loglog(x,y) xlabel('x') ylabel('y') title('loglog plot of y = x^2')