Function Reference
— Function File: fplot (fn, limits)
— Function File: fplot (fn, limits, tol)
— Function File: fplot (fn, limits, n)
— Function File: fplot (..., fmt)

Plot a function fn, within the defined limits. fn an be either a string, a function handle or an inline function. The limits of the plot are given by limits of the form [xlo, xhi] or [xlo, xhi, ylo, yhi]. tol is the default tolerance to use for the plot, and if tol is an integer it is assumed that it defines the number points to use in the plot. The fmt argument is passed to the plot command.

             fplot ("cos", [0, 2*pi])
             fplot ("[cos(x), sin(x)]", [0, 2*pi])

See also: plot

Demonstration 1

The following code

 fplot ("cos", [0, 2*pi])

Produces the following figure

Demonstration 2

The following code

 fplot ("[cos(x), sin(x)]", [0, 2*pi])

Produces the following figure