Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Solving equation in finite field

  1. Nov 8, 2006 #1
    Hi all,

    I encountered a problem I don't know how to solve: In [itex]\mathbb{Z}_{21}[/itex], I want to find numbers x such that [itex]x^2 = x[/itex].

    I don't know what to do with that, I just wrote that (since 21 divides [itex]x^2 - x[/itex])

    21y = x^2 - x

    for some integer y, but it didn't seem to help me much.

    Could you give me please some advice?

    And I have one more (probably trivial, but I can't find it nowhere) question regarding [itex]Z_{n}[/itex]: These fields consist of elements [itex]\{0, 1, ... , n - 1\}[/itex]. But what if I am given something like -7 or [itex]\frac{2}{5}[/itex], how should I represent it in this field?

    Thank you.
  2. jcsd
  3. Nov 8, 2006 #2


    User Avatar
    Staff Emeritus
    Science Advisor
    Gold Member

    Z_21 isn't a finite field. If it was, solving this problem would be trivial. (You'd do exactly the same thing you did in your precalculus classes)

    But you can factor Z_21 into the product of two finite fields...

    -7 should be easy. (Remember that Z_n is just working modulo n)

    As for 2/5, that would simply require solving the equation 5x = 2. The extended Euclidean algorithm will be useful here. (run it on (5, n))
    Last edited: Nov 8, 2006
  4. Nov 8, 2006 #3


    User Avatar
    Science Advisor
    Homework Helper

    solve it as usual, i.e. x(x-1) = 0, so either x = 0, or x-1 = 0, or x(x-1) is a multiple of 3(7). e.g. x=7 works.

    but as i noticed on my midterm in college when i had not studied this topic, it aint too hard to find all solutions of a problem when there are only 21 possible solutions. i.e. try them all.
  5. Nov 8, 2006 #4


    User Avatar
    Staff Emeritus
    Science Advisor
    Gold Member

    Hey, wait a minute! I thought x² - x = (x - 15)(x - 7)!

    (Yes, I know both are true. I just thought it would be fun to say it that way. :wink:)
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook