0

I‘m currently preparing for an algebra exam and I just cannot understand what is goin on in this task.

$$\frac{2X^2}{2X^2+2}\in F_7[X]/(X^3+X^2+1)$$

I know how polynomial division works and thats how I normally go about these kinds of problems, but unfortunately I have no clue what to do if it is in rational form.

The proposed solution is the following:

$$ \frac{2 X^2}{2 X^2+2}=1-\frac{1}{X^2+1} $$

$a, b, c \in \mathbb{F}_7$: $$ \begin{aligned} \left(X^2+1\right)\left(a X^2+b X+c\right) & =a X^4+b X^3+(a+c) X^2+b X+c \\ & =a\left(-X^2-X\right)+b(-X-1)+(a+c) X^2+b X+c \\ & =c X^2-a X+(c-b) \end{aligned} $$

We want $c X^2-a X+(c-b)=1$, therefore $c=0, a=0$ und $b=-1$ in $\mathbb{F}_7[X] /\left(X^3+X^2+1\right)$. Then $$ \frac{2 X^2}{2 X^2+2}=1+X $$

If one could share a link to a resource on this topic or explain it to me, it would help me massively. Thank you

EDIT: I dont how I could miss that I‘m just looking for the inverse of x^2+1 …

Should I delete the question as it seems pretty trivial now?

  • You need to find the inverse of $X^2+1$ in your field. See for example here or here about the technique. Many other examples worked out, I think. – Jyrki Lahtonen Jan 26 '25 at 21:03
  • Instead of running Extended Euclid, you can observe that $x^2+1=-x^3$, so $$\frac{x^2}{x^2+1}=-\frac{x^2}{x^3}=-\frac1x.$$ Surely that is simpler. – Jyrki Lahtonen Jan 26 '25 at 21:44
  • I am sure any good textbook on the subject is an appropriate resource. There appears to be nothing fancy in finding $(x^2+1)^{-1}$, it looks like simple algebra solving for the coefficients $a,b,c$ We're a question-answer site in the meanwhile however, we are not an open-ended tutoring site. – Mike Jan 26 '25 at 22:01
  • Please check the defining polynomial. The title says $X^3+X^2+1$, but your question body uses $X^3+X+1$. Which is it? – Jyrki Lahtonen Jan 26 '25 at 22:14
  • This is a simple purely mechanical calculation using the Extended Euclidean algorithm e.g. as here in the 2nd dupe. As usual, for small elements there are various minor simplifications one can apply, e.g. using inverse reciprocity simplifies the inversion modulus from your cubic to the quadratic $,x^2+1.,$ i.e. to the trivial problems of inverting a complex number, as here in the first dupe. Chasing links from the dupes will reveal hundreds of worked examples. $\ \ $ – Bill Dubuque Jan 26 '25 at 22:47
  • Comparing rational numbers is also a mechanical calculation. Yet we find tricks like this delightful. Same here, @BillDubuque. Sometimes the terms of the minimal polynomial suggest a particular trick to be applied instead of the mechanical approach. – Jyrki Lahtonen Jan 27 '25 at 18:13
  • @JyrkiLahtonen What you call "tricks" are merely special case optimizations of the (extended) Euclidean algorithm (or closely related methods). Most all known such methods have already been mentioned here many times in prior posts. As an experienced user in these tags you should know that well. In fact you have made arguments against rampant duplication of such "tricks" when it comes to methods for computing large modular powers, so it is a bit contradictory to argue the contrary here (assuming you are serious). There is nothing novel in either answer. – Bill Dubuque Jan 27 '25 at 19:53
  • May be we can, finally, also close every mechanical calculation of modular powers as a duplicate of this canonical question? – Jyrki Lahtonen Jan 28 '25 at 04:38
  • @Jyrki Since someone has apparently reacted by going on a downvoting spree on some of my answers, there will be no further replies from me. It is sad that users cannot behave more maturely when discussing such matters. – Bill Dubuque Jan 30 '25 at 17:43
  • @BillDubuque Fine. The discussion wasn't going anywhere. Surprised to hear that someone who allegedly pays no attention to reputation would worry about a few downvotes. We both get our share of political downvotes anyhow. – Jyrki Lahtonen Jan 30 '25 at 20:19
  • @Jryki I remind you for the umpteenth time: not everyone shares your extreme concerns about gamification matters. I could not care less about the puerile SE rep game. I am here to disseminate mathematical knowledge (same as in the non-gamified sci.math). Said concern about such (political) downvotes is that they may mislead readers about aspects of the attacked answers (correctness, value, etc). – Bill Dubuque Jan 31 '25 at 17:32

1 Answers1

3

I think the question is rather about what is going on, than about "solving" the problem. So let us compare the given problem with the following one, invented for the reason of being similar with a simpler arithmetic situation:

Compute $2/4\in\Bbb Z/(7)$.

There is no profit in knowing here the answer for the stated question, but the structure is similar. So i will explain this structure first. On the R.H.S. we have a ring modulo an ideal, the ring is the ring of integers, and the ideal is the ideal generated by $7$, so we consider to be zero (in the quotient ring) elements that are multiples of $7$, we simply write $0=\pm7=\pm 14=\pm21=\dots$ in the ring $R=\Bbb Z/(7)$. (Which is by chance a field.) Now we have to make a computation in this ring, what is $2/4$ in $R$? Well, we can claim it is simply $2/4$, which is an element in $R$, or simplify and claim it is $1/2$. Both answers are valid. But implicitly, tacitly the question wants from us to have an answer using the "standard representatives" from $R=\Bbb Z/(7)$, which are (depending on taste) either the seven (classes of the) elements $0,1,2,3,4,5,6$, or the other used set $0,\pm1,\pm2,\pm3$. Well, we have a finite set of candidates, and the answer is quickly find by trial and error, it is $4$, why? - well we check that $2/4=4$ in $\Bbb R$, equivalently $2=4\cdot 4$ in $R$, equivalently $2=16$ in R$, equivalently $2-16$ is a multiple of seven, and this is indeed the case.


We translate in the given situation. The ring is (no longer $\Bbb Z$), but the ring $\Bbb F_7[X]$ of polynomials in the indeterminate $X$ with coefficients in the field with seven elements $\Bbb F_7$. The ideal we consider in this ring is the ideal generated by the one polynomial $X^3+X^2+1$. We are searching for a better representative for $2X^2/(2X^2+2)$ in the quotient ring. Again, the problem wants (tacitly) us to find a "good representative". (Modulo seven, the possible rests when dividing with rest by seven are $0,1,2,3,4,5,6$. Which are the possible rests when dividing with rest by a polynomial of third degree?) We search thus the answer in the form $aX^2+bX+c$ with coefficients $a,b,c\in\Bbb F_7$. The check is this time: $$ \frac {2X^2}{2X^2+2}=aX^2+bX+c\in\Bbb F_7[X] \text{ modulo }(X^3+X^2+1) \\ \text{ iff } \\ 2X^2-(2X^2+2)(aX^2+bX+c)\text{ is a multiple of }(X^3+X^2+1) \\ \text{ iff } \\ (X^2+1)(aX^2+bX+c)\text{ is equal to $X^2$ modulo }(X^3+X^2+1) \ . $$ We compute thus $(X^2+1)(aX^2+bX+c)$ modulo $(X^3+X^2+1)$ as a polynomial of degree $\le 2$ in $X$, and finally insist this polynomial is $X^2$. $$ \begin{aligned} (X^2+1)(aX^2+bX+c) &= aX^4+bX^3+(c+a)X^2+bX+c\\ &\equiv (aX^4+bX^3+(c+a)X^2+bX+c)-aX(X^3+X^2+1)\\ &= (b-a)X^3+(c+a)X^2+(b-a)X+c\\ &\equiv (b-a)X^3+(c+a)X^2+(b-a)X+c-(b-a)(X^3+X^2+1)\\ &=(c-b+2a)X^2+(b-a)X+(c-b+a)\ . \end{aligned} $$ The last expression is set to be equal to $X^2$, so we solve the system with three equations $c-b+2a=1$, and $b-a=0$, and $c-b+a=0$, to obtain $a=b$, then $c=0$, then $a=1$, so the answer is $X^2+X$.


Note: If we know this answer, then the whole story reduces to the check: $2X^2/(2X^2+2)$ is $X^2+X$ because $(2X^2+2)(X^2+X)=2X^4+2X^3+2X^2+2X=2X\color{blue}{(X^3+X^2+1)}+2X^2\equiv 2X^2$ modulo $\color{blue}{(X^3+X^2+1)}$.


Note: Computers may be useful to understand similar computations and check results. For instance, the result is obtained as follows in sage:

sage: R.<X> = PolynomialRing(GF(7))
sage: R
Univariate Polynomial Ring in X over Finite Field of size 7
sage: Q.<x> = R.quotient(X^3 + X^2 + 1)
sage: 2*x^2/(2*x^2 + 2)
x^2 + x

The computation in the other quotient ring:

sage: R.<X> = PolynomialRing(GF(7))
sage: R
Univariate Polynomial Ring in X over Finite Field of size 7
sage: Q.<x> = R.quotient(X^3 + X + 1)    # the other quotient ring
sage: Q.is_field()
True
sage: 2*x^2/(2*x^2 + 2)
x + 1

Again: Knowing the answer makes the solution a simple check: $$(2X^2+2)(X+1)=2X^3+2X^2+2X+2=2\color{blue}{(X^3+X+1)}+2X^2\equiv 2X^2$$ modulo $\color{blue}{(X^3+X+1)}$.

dan_fulea
  • 37,952
  • Please strive not to post more (dupe) answers to dupes of FAQs. This is enforced site policy, see here. – Bill Dubuque Jan 26 '25 at 22:34
  • @BillDubuque The question did not made the impression of a low-quality question. OP mentions some details and types a solution more or less asking for the structural explanation. It is a simple question, yes, but it is placed in a ring theoretic framework that often turns out to be problematic in exams. If it is a duplicate question the i usually see the former question in the Linked or Related part. The answer in https://math.stackexchange.com/questions/124300/finding-inverse-of-polynomial-in-a-field is not exactly useful here. Usually i am answering rather "hard" or didactic questions. – dan_fulea Jan 26 '25 at 23:02
  • Please read the prior linked post on site policy. For posts that are likely dupes (e.g. common exercises like this) users are expected to either search for dupe targets, or refrain from answering while others do so. – Bill Dubuque Jan 26 '25 at 23:07
  • @Bill I was against "rampant duplication" already at the time when you were happily self-duplicating answers. It is exactly self-duplicating posts that I find distasteful. That is hardly ever the case with new users. Also using the dupehammer privilege to draw attention to posts the hammerer has answered themself is somewhere between unappetizing and obnoxious. – Jyrki Lahtonen Jan 29 '25 at 20:40
  • 1
    @BillDubuque After taking a closer look at the mentioned "dupe" (since duplicate seems to take longer to type - not the first time, so at some point i realized what it means), https://math.stackexchange.com/questions/3140242/how-does-the-extended-euclidean-algorithm-generalize-to-polynomials there are some reasons to not see this question in the same frame. We have here polynomials over a finite field, so there are a few answers that may be possible. OP writes (the idea of) a solution that searches for some coefficients and reduces the problem to solving a system. Computing $1/(2X^2+2)$... – dan_fulea Jan 30 '25 at 13:15
  • 1
    ... does not fit in an optimal solution. Neither respects this the OP needs, it is just an other way to solve the same problem, by reducing it to understand the Euclidean algorithm - off topic, not the asked question. But when it comes to give other solutions, then let us take a look at the quick, pointed, straightforward hint in the comments, then in an answer of @JyrkiLahtonen . It is a "trick solution", but the one i would give in an exam after having the solution. This is also an important point, when you have a solution - write a better one! So OP wins more from this trick answer! – dan_fulea Jan 30 '25 at 13:19
  • @dan_fulea See my final comment on the question. – Bill Dubuque Jan 30 '25 at 17:44
  • @BillDubuque Not my downvotes, from my point of view each answer is valuable for the community. Also there if for me no reason to adjust a good, deserved reputation by some minus epsilon. I understand the inflation produced in time by answer of the same (easy) nature, at some point the growth comes from quality and connectivity of themes. – dan_fulea Jan 30 '25 at 19:34