Subtract - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


MultivariatePowerSeries

  

Subtract

  

subtract two power series or two Puiseux series or two univariate polynomial over power series

 

Calling Sequence

Parameters

Description

Examples

Compatibility

Calling Sequence

p - q

Subtract(p, q)

r - s

Subtract(r, s)

u - v

Subtract(u, v)

Parameters

p, q

-

power series generated by this package, polynomials, or complex constants

r, s

-

Puiseux series generated by this package

u, v

-

univariate polynomials over power series generated by this package with the same main variable

Description

• 

The commands p - q and Subtract(p, q) return the difference of p and q.

• 

The commands r - s and Subtract(r, s) return the difference of r and s. This can only be computed if the orders of r and s are compatible. See the Add help page for an explanation.

• 

The commands u - v and Subtract(u, v) return the difference of u and v.

• 

When using the MultivariatePowerSeries package, do not assign anything to the variables occurring in the power series, Puiseux series, and univariate polynomials over these series. If you do, you may see invalid results.

Examples

withMultivariatePowerSeries:

We define two power series.

aGeometricSeriesx,y:

bPowerSeries1+x+y+z:

We compute their difference in two equivalent ways.

cab

cPowⅇrSⅇrⅈⅇs of 11xy1xyz : 0+

(1)

dSubtracta,b

dPowⅇrSⅇrⅈⅇs of 11xy1xyz : z+

(2)

We verify that the two results are equal up to homogeneous degree 10.

ApproximatelyEqualc,d,10

true

(3)

We define two univariate polynomials over power series and compute their difference.

fUnivariatePolynomialOverPowerSeriesxz+yz2+xyz3,z:

gUnivariatePolynomialOverPowerSeriesGeometricSeriesx,y,z:

hSubtractf,g

hUnⅈvarⅈatⅇPolynomⅈalOvⅇrPowⅇrSⅇrⅈⅇs: −1++xz+yz2+xyz3

(4)

Create three Puiseux series.

s1PuiseuxSeriesPowerSeries11+u,u=x13y2,x=3,y=4

s1PuⅈsⅇuxSⅇrⅈⅇs of x31+y2x13y4 : x3y4+

(5)

s2PuiseuxSeries2+2u+v,u=x12y,v=y,x=3,y=2

s2PuⅈsⅇuxSⅇrⅈⅇs of 2+2yx+2yx3y2 : 2x3y2+2x52y3+2y3x3

(6)

s3PuiseuxSeriesPowerSeries11+uv,y,x,u,v,1,0,1,12

s3PuⅈsⅇuxSⅇrⅈⅇs of 1y2x+1 : 1+

(7)

We subtract s1 and s2.

Subtracts1,s2

PuⅈsⅇuxSⅇrⅈⅇs of 11+y2x13+22y6x3y4 : x3y4+

(8)

We get an error if we try to subtract s1 and s3, since the orders [x,y] and [y,x] are not compatible.

Subtracts1,s3

Error, (in MultivariatePowerSeries:-Subtract) the order of Puiseux series [x, y] and [y, x] are not compatible

We can use the command GetPuiseuxSeriesOrder to obtain the Puiseux series order of s1 and s3.

GetPuiseuxSeriesOrders1

x,y

(9)

GetPuiseuxSeriesOrders3

y,x

(10)

Compatibility

• 

The MultivariatePowerSeries[Subtract] command was introduced in Maple 2021.

• 

For more information on Maple 2021 changes, see Updates in Maple 2021.

• 

The MultivariatePowerSeries[Subtract] command was updated in Maple 2023.

See Also

Add

GeometricSeries

MainVariable

Negate

PowerSeries

Truncate

UnivariatePolynomialOverPowerSeries