%% Explicit Function Plot
% Create a 2-D line plot by using fplot. Plot the expression x^3-6x^2+11x-6.

syms x
f = x^3 - 6*x^2 + 11*x - 6;
fplot(f)

%
% Add labels for the x- and y-axes. Generate the title by using texlabel(f). Show the grid by using grid on. For details, see Add Title, Axis Labels, and Legend to Graph.

xlabel('x')
ylabel('y')
title(texlabel(f))
grid on

% Copyright 2012 The MathWorks, Inc.