TaylorApproximation - Maple Help

Student[MultivariateCalculus]

 TaylorApproximation
 return the Taylor series for a multivariate function

 Calling Sequence TaylorApproximation(f(x,y,...), [x,y,...]=[a,b,...], degree, x=xmin..xmax, y=ymin..ymax, ..., opts)

Parameters

 f(x, y, ...) - algebraic expression x, y, ... - name; specify the independent variables a, b, ... - name or real constants; point around which the function is expanded degree - (optional) positive integer; degree of Taylor polynomial xmin, xmax, ymin, ymax, ... - (optional) real constants specifying range over which to plot function opts - (optional) equation(s) of the form option=value where option is one of centeroptions, functionoptions, output, showcenter, showfunction, tayloroptions; specify output options

Description

 • The TaylorApproximation command returns the Taylor approximation of f of a specified degree around a specified point. By using options, you can specify that the command returns a plot or animation.  This feature is only available if one or two variables are specified.
 • The opts argument can contain any of the following equations that set output options.  Plotting is only available for univariate or bivariate functions.
 • The TaylorApproximationTutor routine offers equivalent capabilities to TaylorApproximation in a tutor interface.  See Student[MultivariateCalculus][TaylorApproximationTutor] help page.
 centeroptions = list
 Specifies the plot options for plotting the point $x,f\left(x\right)$ or $x,y,f\left(x,y\right)$.  For more information on plotting options, see plot3d/options.
 functionoptions = list
 Specifies the plot options for plotting the function $f$. For more information on plotting options, see plot3d/options.
 output = value, plot, or animation
 This option controls the return value of the function.
 * output = value specifies that the value of the approximation is returned. Plot options are ignored if output = value.  The default is output = value.
 * output = plot specifies that a plot displays, which shows the expression and the Taylor approximation to the function.
 * output = animation specifies that an animation displays, which shows the Taylor approximation approaching the function as the degree of the Taylor series increases with each frame.
 showcenter = true or false
 Determines whether the point around which the series is expanded is plotted. The default is true.
 showfunction = true or false
 Determines whether the function f is plotted. The default is true.
 tayloroptions = list
 Specifies the plot options for plotting the Taylor approximation to f. The default is $\left['\mathrm{color}'='\mathrm{red}','\mathrm{transparency}'=0.5\right]$. For more information on plotting options, see plot3d/options.
 caption = anything
 A caption for the plot.
 The default caption is constructed from the parameters and the command options. caption = "" disables the default caption. For more information about specifying a caption, see plot/typesetting.
 title = anything
 A title for the plot.
 The default title is constructed from the parameters and the command options. title = "" disables the default title. For more information about specifying a title, see plot/typesetting.
 • For information on how to change the default colors, see the Student[SetColors] help page.

Examples

 > $\mathrm{with}\left(\mathrm{Student}\left[\mathrm{MultivariateCalculus}\right]\right):$
 > $\mathrm{TaylorApproximation}\left(\mathrm{sin}\left(x+y\right),\left[x,y\right]=\left[1,0\right],5\right)$
 $\frac{{\mathrm{cos}}{}\left({1}\right){}{{y}}^{{5}}}{{120}}{+}\frac{{\mathrm{sin}}{}\left({1}\right){}{{y}}^{{4}}}{{24}}{+}\frac{{\mathrm{cos}}{}\left({1}\right){}\left({x}{-}{1}\right){}{{y}}^{{4}}}{{24}}{-}\frac{{\mathrm{cos}}{}\left({1}\right){}{{y}}^{{3}}}{{6}}{+}\frac{{\mathrm{sin}}{}\left({1}\right){}\left({x}{-}{1}\right){}{{y}}^{{3}}}{{6}}{+}\frac{{\mathrm{cos}}{}\left({1}\right){}{\left({x}{-}{1}\right)}^{{2}}{}{{y}}^{{3}}}{{12}}{-}\frac{{\mathrm{sin}}{}\left({1}\right){}{{y}}^{{2}}}{{2}}{-}\frac{{\mathrm{cos}}{}\left({1}\right){}\left({x}{-}{1}\right){}{{y}}^{{2}}}{{2}}{+}\frac{{\mathrm{sin}}{}\left({1}\right){}{\left({x}{-}{1}\right)}^{{2}}{}{{y}}^{{2}}}{{4}}{+}\frac{{\mathrm{cos}}{}\left({1}\right){}{\left({x}{-}{1}\right)}^{{3}}{}{{y}}^{{2}}}{{12}}{+}{\mathrm{cos}}{}\left({1}\right){}{y}{-}{\mathrm{sin}}{}\left({1}\right){}\left({x}{-}{1}\right){}{y}{-}\frac{{\mathrm{cos}}{}\left({1}\right){}{\left({x}{-}{1}\right)}^{{2}}{}{y}}{{2}}{+}\frac{{\mathrm{sin}}{}\left({1}\right){}{\left({x}{-}{1}\right)}^{{3}}{}{y}}{{6}}{+}\frac{{\mathrm{cos}}{}\left({1}\right){}{\left({x}{-}{1}\right)}^{{4}}{}{y}}{{24}}{+}{\mathrm{sin}}{}\left({1}\right){+}{\mathrm{cos}}{}\left({1}\right){}\left({x}{-}{1}\right){-}\frac{{\mathrm{sin}}{}\left({1}\right){}{\left({x}{-}{1}\right)}^{{2}}}{{2}}{-}\frac{{\mathrm{cos}}{}\left({1}\right){}{\left({x}{-}{1}\right)}^{{3}}}{{6}}{+}\frac{{\mathrm{sin}}{}\left({1}\right){}{\left({x}{-}{1}\right)}^{{4}}}{{24}}{+}\frac{{\mathrm{cos}}{}\left({1}\right){}{\left({x}{-}{1}\right)}^{{5}}}{{120}}$ (1)

To play the following animation in this help page, right-click (Control-click, on Macintosh) the plot to display the context menu.  Select Animation > Play.

 > $\mathrm{TaylorApproximation}\left(\mathrm{sin}\left(x+y\right),\left[x,y\right]=\left[1,0\right],5,\mathrm{output}=\mathrm{animation}\right)$

The command to create the plot in the Plotting Guide is

 > $\mathrm{TaylorApproximation}\left(\mathrm{sin}\left(x\right),\left[x,y\right]=\left[0,0\right],5,x=-3..3,y=-3..3,\mathrm{output}=\mathrm{plot}\right)$