19.07.2014 Views

Contents - Student subdomain for University of Bath

Contents - Student subdomain for University of Bath

Contents - Student subdomain for University of Bath

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

C.5. REDUCE 239<br />

1: (x^2-1)^10/(x+1)^10;<br />

Figure C.8: Reduce output<br />

x 10 − 10x 9 + 45x 8 − 120x 7 + 210x 6 − 252x 5 + 210x 4 − 120x 3 + 45x 2 − 10x + 1<br />

2: <strong>of</strong>f exp;<br />

3: (x^2-1)^10/(x+1)^10;<br />

4: <strong>of</strong>f gcd;<br />

5: (x^2-1)^10/(x+1)^10;<br />

(x − 1) 10<br />

(x − 1) 10<br />

6: (x^2-1)^10/(x^2+2*x+1)^10;<br />

(<br />

x 2 − 1 ) 10<br />

7: on gcd;<br />

8: ws;<br />

(x 2 + 2x + 1) 10<br />

(x − 1) 10<br />

(x + 1) 10<br />

above is taken from MatLab.<br />

C.5 Reduce<br />

C.5.1<br />

Overview<br />

Note that Reduce produces output that cuts/pastes as TEX, as in Figure C.8.<br />

By default, the output is canonical (Definition 4), but this can be changed<br />

via the exp (short <strong>for</strong> expand) and gcd (compute them) switches. Note that<br />

exact division tests are done even when gcd is <strong>of</strong>f, as in line 5, and we need a<br />

more challenging example, as in line 6.<br />

C.5.2<br />

History

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!