0% found this document useful (0 votes)
78 views3 pages

EXAMPLE 7 The Following: Manipulate

The document provides examples and explanations of mathematical functions in Mathematica including: 1) Using Manipulate to expand (x + 1)n to powers between 1 and 10 controlled by radio buttons. 2) Explaining options to override Factor's default of only factorizing over integers. 3) Defining and providing examples of using PolynomialGCD to find the greatest common divisor of polynomials and PolynomialLCM to find the least common multiple of polynomials.

Uploaded by

hachan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
78 views3 pages

EXAMPLE 7 The Following: Manipulate

The document provides examples and explanations of mathematical functions in Mathematica including: 1) Using Manipulate to expand (x + 1)n to powers between 1 and 10 controlled by radio buttons. 2) Explaining options to override Factor's default of only factorizing over integers. 3) Defining and providing examples of using PolynomialGCD to find the greatest common divisor of polynomials and PolynomialLCM to find the least common multiple of polynomials.

Uploaded by

hachan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

EXAMPLE 7 The following Manipulate command expands (x + 1)n to any power

between 1 and 10, controlled by radio buttons.

By default, Factor allows factorization only over the integers. There are options
that allow this default to be overridden.

• Extension → {extension1, extension2, . . . } can be used to specify a list of


algebraic numbers that may be included as well. (The brackets, {}, are not
needed if only one extension is used.)
• Extension → Automatic extends the field to include any algebraic numbers that
appear in the polynomial.
• GaussianIntegers → True allows the factorization to take place over the set of

integers with adjoined. Alternatively, or I may be included in the list


of extensions.

EXAMLE 8

The greatest common divisor (GCD) of polynomials, p1, p2 . . . is the polynomial


of largest degree that can be divided evenly (remainder = 0) into p1, p2, . . . . The
least common multiple (LCM) of polynomials p1, p2, . . . is the polynomial of
smallest degree that can be divided evenly by p1, p2, . . . .

PolynomialGCD[p1, p2,...] computes the greatest common divisor of the


polynomialsp1, p2, . . .

PolynomialLCM[p1, p2,...] computes the least common multiple of the


polynomials p1,p2, . . .

EXAMLE 9
p = (x − 1)(x − 2)2 (x − 3)3;

q = (x − 1)2 (x − 2)(x − 3)4;

PolynomialGCD[p, q]

(−3 + x)3(−2 + x)(−1 + x)

PolynomialLCM[p, q]

(−3 + x)4(−2 + x)2(−1 + x)2


By default, both PolynomialGCD and PolynomialLCM assume the coefficients of the
polynomials to be rational numbers. As with Factor, the option Extension can be
used to specify a list of algebraic numbers (and/or I) that may be allowed.

EXAMLE 10

Although Mathematica will automatically expand integer exponents of products


and quotients, if the exponent is non-integer, the expression will be left
unexpanded. To force the “distribution” of the exponent, the
command PowerExpand is available.

PowerExpand [expression] expands nested powers, powers of products and


quotients, roots of products and quotients, and their logarithms.

EXAMPLE 11

One must be very careful with PowerExpand when multi-valued functions


are involved.

EXAMLE 12

Here are a few additional examples illustrating PowerExpand:

EXAMLE 13

(ax)y // PowerExpand

axy

(a/b)x // PowerExpand

ax b−x
Log[x y] // PowerExpand

Log[x] + Log[y]

Log[x/y] // PowerExpand

Log[x] − Log[y]

Log[xy ] // PowerExpand

y Log[x]

SOLVED PROBLEMS

7.1 Test to see if 1 + x sin y + x2 cos y + x5ey is a polynomial in x. Is it a


polynomial in y?

SOLUTION

You might also like