taylor INDEX

TAYLOR _ _ _ _ _ _ _ _ _ _ _ _ operator

The taylor operator is used for expanding an expression into a Taylor series.

syntax:

taylor(<expression> ,<var>, <expression>,<number>

{,<var>, <expression>,<number>}*)

<expression> can be any valid REDUCE algebraic expression. <var> must be a kernel, and is the expansion variable. The <expression> following it denotes the point about which the expansion is to take place. <number> must be a non-negative integer and denotes the maximum expansion order. If more than one triple is specified taylor will expand its first argument independently with respect to all the variables. Note that once the expansion has been done it is not possible to calculate higher orders.

Instead of a kernel, <var> may also be a list of kernels. In this case expansion will take place in a way so that the sum/ of the degrees of the kernels does not exceed the maximum expansion order. If the expansion point evaluates to the special identifier infinity, taylor tries to expand in a series in 1/<var>.

The expansion is performed variable per variable, i.e. in the example above by first expanding exp(x^2+y^2) with respect to x and then expanding every coefficient with respect to y.

examples:


    taylor(e^(x^2+y^2),x,0,2,y,0,2); 


       2    2    2  2      2  2
  1 + Y  + X  + Y *X  + O(X ,Y )   


    taylor(e^(x^2+y^2),{x,y},0,2); 


       2    2       2  2
  1 + Y  + X  + O({X ,Y })

The following example shows the case of a non-analytical function.



    taylor(x*y/(x+y),x,0,2,y,0,2); 


  ***** Not a unit in argument to QUOTTAYLOR 

Note that it is not generally possible to apply the standard reduce operators to a Taylor kernel. For example, part, coeff, or coeffn cannot be used. Instead, the expression at hand has to be converted to standard form first using the taylortostandard operator.

Differentiation of a Taylor expression is possible. If you differentiate with respect to one of the Taylor variables the order will decrease by one.

Substitution is a bit restricted: Taylor variables can only be replaced by other kernels. There is one exception to this rule: you can always substitute a Taylor variable by an expression that evaluates to a constant. Note that REDUCE will not always be able to determine that an expression is constant: an example is sin(acos(4)).

Only simple taylor kernels can be integrated. More complicated expressions that contain Taylor kernels as parts of themselves are automatically converted into a standard representation by means of the taylortostandard operator. In this case a suitable warning is printed.