TAOCP Vol 2: Seminumerical Algorithms · Week 85

TAOCP 4.6.1 Division of Polynomials

Updated

About 7 hours31 exercises, rated 10 to M40

Summary

TAOCP 4.6.1 Division of Polynomials: Polynomial arithmetic, especially division with remainder, and computing greatest common divisors of polynomials, including variants that avoid fractions when coefficients are integers. Budget about 7 hours; do exercises 4.6-1, 4.6-4 and 4.6-5.

Flashcards 14 cards for Anki and AnkiMobile · all decks

Anki deck.tsv

This week's steps

3 steps
  1. Read §4.6.1 Division of Polynomials

    Implement polynomial division over integers mod a prime.

  2. Work the exercises (8 picked)

    Start with Ex 4.6-1, Ex 4.6-4, Ex 4.6-5; log what you solve below.

  3. Write down one thing you'd explain to someone

    A few sentences in your own words in Your notes: the idea, why it works, an example. 30 words ticks this.

Sign in to track this: tick each step off and it counts toward your week.

Exercises

This section has 31 exercises, rated 10 to M40, and Knuth marks 5 of them with the triangle for recommended. Counts include the 5 exercises at the end of the 4.6 introduction (numbered 4.6-1 to 4.6-5) plus the 26 of 4.6.1. Implement polynomials over the integers mod p and over the integers, with division and gcd, and use these to test it.

Worth your time

  • Exercise 4.6-110

    Polynomial arithmetic modulo 10. Shows where non-prime moduli cause trouble.

    Discuss

  • Exercise 4.6-421▶ Recommended

    Multiply polynomials mod 2 with bitwise word operations.

    Discuss

  • Exercise 4.6-5M21▶ Recommended

    Karatsuba for polynomials mod 2.

    Discuss

  • Exercise 4.6.1-110

    Pseudo-division by hand on integer polynomials.

    Discuss

  • Exercise 4.6.1-215

    A polynomial gcd modulo 7.

    Discuss

  • Exercise 4.6.1-3M25

    Extended Euclid for polynomials and the degrees of the coefficients.

    Discuss

  • Exercise 4.6.1-16M22▶ Recommended

    A nonzero polynomial cannot vanish on too many grid points. The basis of randomized identity testing.

    Discuss

  • Exercise 4.6.1-26M26▶ Recommended

    Best rational-function approximations from the polynomial Euclid algorithm. The stretch.

    Discuss

Your log

Sign in to log the exercises you work: number, rating, how far you got.

Your notes

Only you

Sign in to keep private notes on this guide, in Markdown. They stay yours: never on your profile, and you can export them all.

Discussion

0 posts

Questions about the reading go here; each exercise has its own thread below. Hints over answers.

No posts yet. Ask a question or share a tip.

Sign in to postAnyone can read. Posting needs an account with a confirmed email.

Exercise threads

One thread per exercise. Open one to ask for a nudge or check your thinking.

  • Exercise 4.6-110No posts yet

    Hints over answers. Say what you tried; put an answer or a full solution inside a spoiler: ||like this|| or a ```spoiler block.

    Sign in to postAnyone can read. Posting needs an account with a confirmed email.

  • Exercise 4.6-421No posts yet

    Hints over answers. Say what you tried; put an answer or a full solution inside a spoiler: ||like this|| or a ```spoiler block.

    Sign in to postAnyone can read. Posting needs an account with a confirmed email.

  • Exercise 4.6-5M21No posts yet

    Hints over answers. Say what you tried; put an answer or a full solution inside a spoiler: ||like this|| or a ```spoiler block.

    Sign in to postAnyone can read. Posting needs an account with a confirmed email.

  • Exercise 4.6.1-110No posts yet

    Hints over answers. Say what you tried; put an answer or a full solution inside a spoiler: ||like this|| or a ```spoiler block.

    Sign in to postAnyone can read. Posting needs an account with a confirmed email.

  • Exercise 4.6.1-215No posts yet

    Hints over answers. Say what you tried; put an answer or a full solution inside a spoiler: ||like this|| or a ```spoiler block.

    Sign in to postAnyone can read. Posting needs an account with a confirmed email.

  • Exercise 4.6.1-3M25No posts yet

    Hints over answers. Say what you tried; put an answer or a full solution inside a spoiler: ||like this|| or a ```spoiler block.

    Sign in to postAnyone can read. Posting needs an account with a confirmed email.

  • Exercise 4.6.1-16M22No posts yet

    Hints over answers. Say what you tried; put an answer or a full solution inside a spoiler: ||like this|| or a ```spoiler block.

    Sign in to postAnyone can read. Posting needs an account with a confirmed email.

  • Exercise 4.6.1-26M26No posts yet

    Hints over answers. Say what you tried; put an answer or a full solution inside a spoiler: ||like this|| or a ```spoiler block.

    Sign in to postAnyone can read. Posting needs an account with a confirmed email.

Reference

Why it matters

Polynomials over finite fields power error-correcting codes, CRCs and cryptography. Polynomial gcd is a building block in computer algebra.

Before you start
  • 4.5.2 The Greatest Common Divisor
  • 4.3.1 Classical Algorithms
How to approach it

Implement polynomial division over integers mod a prime. Then compute a CRC by hand as polynomial division over GF(2) to see a real use.

Common traps
  • Coefficient blow-up when working over the integers. That is exactly what the fraction-free methods address.

Spot a mistake? Report it

Back to week 85