Function plotting

You will recall that we have discussed both expressions and functions, so we can have polynomials that are functions, or polynomials that are polynomials of a specific variable:

[> Id := x -> x:

To plot a function, it is not necessary to specify a variable, but instead, you just provide a range:

[> # 0.5x^2 - 2.3*x - 7.5
[> plot( 0.5*Id^2 - 2.3*Id - 7.5, -4..4, color = "RosyBrown" );

[> # x^2*sin(x)/7
[> plot( Id^2/7*sin, -10..10, scaling = 'constrained', color = "Crimson" );

All the options are the same as that for plotting an expression.