OrthogonalSeries
Evaluate
evaluate a finite series
Calling Sequence
Parameters
Description
Examples
Evaluate(S, trunc_option)
Evaluate(S, x=v, trunc_option)
Evaluate(S, [x1=v1,..., xk=vk], trunc_option)
Evaluate(S, v, trunc_option)
Evaluate(S, [v1,..., vn], trunc_option)
S
-
orthogonal series
x, x1, .., xk
name
v, v1, .., vk
values (symbolic or numeric)
trunc_option
(optional) equation of the form trunc=[t1,..., tn] or trunc=t1
The Evaluate routine evaluates finite orthogonal series of one or more variables using a generalization of the Horner scheme.
The generalized Horner scheme accepts only finite series, that is, polynomials, but S can be a infinite series if the truncation option is used. This option has the form trunc=[t1,...,tn], where n is the dimension of the series S and t1,...,tn are non-negative integers. The Evaluate(S, arguments, trunc=[t1,..., tn]) calling sequence is equivalent to Evaluate(Truncate(S, [t1,..., tn]), arguments). For n equal to 1 the list format is not required. You can replace trunc=[t1] with trunc=t1.
The Evaluate(S) calling sequence returns the series S in the canonical basis.
The Evaluate(S, x=v) calling sequence evaluates the series S after substituting the value v for the variable x. More generally, the Evaluate(S, [x1=v1,..., xk=vk]) calling sequence evaluates the series S after substituting each value vi for the corresponding variable xi. If x or xi is not a variable of S, the substitution is ignored. If there exists i and j such that xi=xj in the substitution list, only the first substitution is performed. If the number of substitutions is less than the dimension of S, the result of the Evaluate function is a new orthogonal series with (n−k) variables. Otherwise, the result is an algebraic expression.
The Evaluate(S, v) calling sequence evaluates the univariate series S after substituting the value v for the variable. The Evaluate(S, [v1,..., vn]) calling sequence evaluates the series of dimension n S after substituting each vi for the corresponding ith variable. If n is not the dimension of S, an error is returned.
with⁡OrthogonalSeries:
S≔Create⁡4,−2,13,ChebyshevT⁡n,x
S≔4⁢ChebyshevT⁡0,x−2⁢ChebyshevT⁡1,x+ChebyshevT⁡2,x3
Evaluate⁡S;Evaluate⁡S,1;Evaluate⁡S,x=1
23⁢x2−2⁢x+113
73
If y is not a variable of S, the substitution is ignored.
Evaluate⁡S,y=1
4⁢ChebyshevT⁡0,x−2⁢ChebyshevT⁡1,x+ChebyshevT⁡2,x3
The following examples use the multivariate case.
S1≔Create⁡1,2=1,4,3=3,HermiteH⁡n,x,HermiteH⁡m,y
S1≔HermiteH⁡1,x⁢HermiteH⁡2,y+3⁢HermiteH⁡4,x⁢HermiteH⁡3,y
Evaluate⁡S1
384⁢x4⁢y3−576⁢x4⁢y−1152⁢x2⁢y3+1728⁢x2⁢y+8⁢x⁢y2+288⁢y3−4⁢x−432⁢y
Evaluate⁡S1,3,4
1219764
Evaluate⁡S1,x=3,y=4
Evaluate⁡S1,x=3,y=4,trunc=2,2
372
If a variable is given multiple substitution values, the first is used.
Evaluate⁡S1,y=3,y=4
34⁢HermiteH⁡1,x+540⁢HermiteH⁡4,x
Evaluate⁡S1,y=3
Evaluate⁡S1,y=3,trunc=2
34⁢HermiteH⁡1,x
An infinite series can be partially evaluated if truncated.
S2≔Create⁡1n,n=3..∞,4,−2,13,ChebyshevT⁡n,x
S2≔4⁢ChebyshevT⁡0,x−2⁢ChebyshevT⁡1,x+ChebyshevT⁡2,x3+∑n=3∞⁡ChebyshevT⁡n,xn
Evaluate⁡S2
Error, (in OrthogonalSeries:-Evaluate) infinite number of terms
Evaluate⁡S2,trunc=5
165⁢x5+2⁢x4−83⁢x3−43⁢x2−2⁢x+4712
See Also
ChebyshevT
HermiteH
OrthogonalSeries[Create]
Download Help Document