Prove that $a^(p-1)/2 equiv 1$ (mod p) and $a^(p-1)/2 equiv -1 pmod p$Show that if $p$ is prime and $p equiv 3 pmod 4$, then $fracp-12 notequiv pm1 pmod p$Primitive Roots mod a prime numberDetermine if a number is a primitive rootProve that $x^3 equiv a pmodp$ has a solution where $p equiv 2 pmod3$?Prove that $x^2 equiv -1 pmod p$ has no solutions if prime $p equiv 3 pmod 4$.There is solution for $x^16 equiv 256 pmod p$ for all prime $p$. Prove or disprove it.$2^4n+1 equiv 1 pmod8n+7$, this has been bugging meWilson's theorem and congruenceWhat are all possible values of $ x equiv a^fracp-12 pmod p$?How to solve $n$ in $5^n-1equiv 1 pmodn$Given $xequiv b^(2p-1)/3 pmodp$, show that $x^3 equiv b pmodp$.Show the congruence $x^p-1equiv 1pmodp$ has $p-1$ solutionsNumber Theory: Prove $x^kequiv apmodp$ is solvable for $r^d,r^2d,dots,r^[(p-1)/d]d$.

What is the reasoning behind standardization (dividing by standard deviation)?

What is 管理しきれず?

Emojional cryptic crossword

If I cast the Enlarge/Reduce spell on an arrow, what weapon could it count as?

How to balance a monster modification (zombie)?

Can a university suspend a student even when he has left university?

How to test the sharpness of a knife?

Asserting that Atheism and Theism are both faith based positions

Was World War I a war of liberals against authoritarians?

Is xar preinstalled on macOS?

Does the Shadow Magic sorcerer's Eyes of the Dark feature work on all Darkness spells or just his/her own?

Could any one tell what PN is this Chip? Thanks~

UK Tourist Visa- Enquiry

Does convergence of polynomials imply that of its coefficients?

Recursively updating the MLE as new observations stream in

Symbolism of 18 Journeyers

Why is "la Gestapo" feminine?

Why is participating in the European Parliamentary elections used as a threat?

Animating wave motion in water

What is the difference between something being completely legal and being completely decriminalized?

Norwegian Refugee travel document

Why didn’t Eve recognize the little cockroach as a living organism?

Isn't the word "experience" wrongly used in this context?

Exit shell with shortcut (not typing exit) that closes session properly



Prove that $a^(p-1)/2 equiv 1$ (mod p) and $a^(p-1)/2 equiv -1 pmod p$


Show that if $p$ is prime and $p equiv 3 pmod 4$, then $fracp-12 notequiv pm1 pmod p$Primitive Roots mod a prime numberDetermine if a number is a primitive rootProve that $x^3 equiv a pmodp$ has a solution where $p equiv 2 pmod3$?Prove that $x^2 equiv -1 pmod p$ has no solutions if prime $p equiv 3 pmod 4$.There is solution for $x^16 equiv 256 pmod p$ for all prime $p$. Prove or disprove it.$2^4n+1 equiv 1 pmod8n+7$, this has been bugging meWilson's theorem and congruenceWhat are all possible values of $ x equiv a^fracp-12 pmod p$?How to solve $n$ in $5^n-1equiv 1 pmodn$Given $xequiv b^(2p-1)/3 pmodp$, show that $x^3 equiv b pmodp$.Show the congruence $x^p-1equiv 1pmodp$ has $p-1$ solutionsNumber Theory: Prove $x^kequiv apmodp$ is solvable for $r^d,r^2d,dots,r^[(p-1)/d]d$.













6












$begingroup$


I've stumbled upon this congruence very similar to Fermat's Little Theorem, but I can't seem to wrap my head around how to solve it. It goes like this:




i) Suppose $p$ is prime, $(a,p)=1$ and the congruence $x^2 equiv a pmod p$ has a solution $x$. Prove that $a^(p-1)/2equiv 1 pmod p$.




And the same question but with an additional condition:




ii) Suppose $p$ is prime, $p equiv 3 pmod 4$, $(a,p) = 1$ and the congruence $x^2 equiv a pmod p$ does not have a solution $x$. Prove that $a^(p-1)/2equiv -1 pmod p$.




For i: Since $x^2 equiv a pmod p$ has a solution, we know that $p mid x^2 - a$, hence $kp=x^2-a$ for some integer $k$, or $a = x^2-kp$. Now this doesn't really help me much!



For ii: Similarly stumped.










share|cite|improve this question











$endgroup$







  • 1




    $begingroup$
    As noted in one of the answers, the condition $p equiv 3 pmod4$ in (ii) is superfluous.
    $endgroup$
    – Andreas Caranti
    Sep 23 '13 at 7:53















6












$begingroup$


I've stumbled upon this congruence very similar to Fermat's Little Theorem, but I can't seem to wrap my head around how to solve it. It goes like this:




i) Suppose $p$ is prime, $(a,p)=1$ and the congruence $x^2 equiv a pmod p$ has a solution $x$. Prove that $a^(p-1)/2equiv 1 pmod p$.




And the same question but with an additional condition:




ii) Suppose $p$ is prime, $p equiv 3 pmod 4$, $(a,p) = 1$ and the congruence $x^2 equiv a pmod p$ does not have a solution $x$. Prove that $a^(p-1)/2equiv -1 pmod p$.




For i: Since $x^2 equiv a pmod p$ has a solution, we know that $p mid x^2 - a$, hence $kp=x^2-a$ for some integer $k$, or $a = x^2-kp$. Now this doesn't really help me much!



For ii: Similarly stumped.










share|cite|improve this question











$endgroup$







  • 1




    $begingroup$
    As noted in one of the answers, the condition $p equiv 3 pmod4$ in (ii) is superfluous.
    $endgroup$
    – Andreas Caranti
    Sep 23 '13 at 7:53













6












6








6


2



$begingroup$


I've stumbled upon this congruence very similar to Fermat's Little Theorem, but I can't seem to wrap my head around how to solve it. It goes like this:




i) Suppose $p$ is prime, $(a,p)=1$ and the congruence $x^2 equiv a pmod p$ has a solution $x$. Prove that $a^(p-1)/2equiv 1 pmod p$.




And the same question but with an additional condition:




ii) Suppose $p$ is prime, $p equiv 3 pmod 4$, $(a,p) = 1$ and the congruence $x^2 equiv a pmod p$ does not have a solution $x$. Prove that $a^(p-1)/2equiv -1 pmod p$.




For i: Since $x^2 equiv a pmod p$ has a solution, we know that $p mid x^2 - a$, hence $kp=x^2-a$ for some integer $k$, or $a = x^2-kp$. Now this doesn't really help me much!



For ii: Similarly stumped.










share|cite|improve this question











$endgroup$




I've stumbled upon this congruence very similar to Fermat's Little Theorem, but I can't seem to wrap my head around how to solve it. It goes like this:




i) Suppose $p$ is prime, $(a,p)=1$ and the congruence $x^2 equiv a pmod p$ has a solution $x$. Prove that $a^(p-1)/2equiv 1 pmod p$.




And the same question but with an additional condition:




ii) Suppose $p$ is prime, $p equiv 3 pmod 4$, $(a,p) = 1$ and the congruence $x^2 equiv a pmod p$ does not have a solution $x$. Prove that $a^(p-1)/2equiv -1 pmod p$.




For i: Since $x^2 equiv a pmod p$ has a solution, we know that $p mid x^2 - a$, hence $kp=x^2-a$ for some integer $k$, or $a = x^2-kp$. Now this doesn't really help me much!



For ii: Similarly stumped.







elementary-number-theory






share|cite|improve this question















share|cite|improve this question













share|cite|improve this question




share|cite|improve this question








edited Mar 13 at 4:20









Rócherz

2,9863821




2,9863821










asked Sep 23 '13 at 5:08









NumbersandsoonNumbersandsoon

1,4521636




1,4521636







  • 1




    $begingroup$
    As noted in one of the answers, the condition $p equiv 3 pmod4$ in (ii) is superfluous.
    $endgroup$
    – Andreas Caranti
    Sep 23 '13 at 7:53












  • 1




    $begingroup$
    As noted in one of the answers, the condition $p equiv 3 pmod4$ in (ii) is superfluous.
    $endgroup$
    – Andreas Caranti
    Sep 23 '13 at 7:53







1




1




$begingroup$
As noted in one of the answers, the condition $p equiv 3 pmod4$ in (ii) is superfluous.
$endgroup$
– Andreas Caranti
Sep 23 '13 at 7:53




$begingroup$
As noted in one of the answers, the condition $p equiv 3 pmod4$ in (ii) is superfluous.
$endgroup$
– Andreas Caranti
Sep 23 '13 at 7:53










5 Answers
5






active

oldest

votes


















7












$begingroup$

Hints:



(i) If $x^2 equiv a pmod p$ then what is $a^fracp-12$ as a power of $x$? Do this and apply Fermat's little theorem.



(ii) Write $x=a^fracp-12$. Fermat's little theorem gives you $x^2 equiv 1 pmod p$. Now use the rest of the information you've been given.






share|cite|improve this answer









$endgroup$




















    2












    $begingroup$

    For the first part, note that $x^p-1equiv 1$ by Fermat's little theorem. Then assuming that $p$ is not $2$ (deal with that case separetly), we have $1equiv (x^2)^(p-1)/2equiv a^(p-1)/2$.



    For the second part, let $alpha$ be a primitive element (this means that there is an element $alpha$ in $1,...,p-1$ such that $alpha$ has order exactly $p-1$ (this means that $alpha^i$ will range through $mathbbZ_p^times$ as we let $i=1,2,..,p-1$).



    Then, since $a$ is not a square, we have that $a=alpha^2c+1$, so $$a^(p-1)/2equiv (alpha^2c+1)^(p-1)/2equiv alpha^c(p-1)alpha^(p-1)/2equiv alpha^(p-1)/2$$Now note that $alpha^(p-1)/2$ is a root of $x^2-1$. Also note that $1$ and $-1$ are also roots. Note that we cannot have three roots (the degree of $x^2-1$ is $2$ and over a field, the degree bounds the number of roots), so we have that $alpha^(p-1)/2$ is either $1$ or $-1$, but it cannot be $1$ since the order of $alpha$ is $p-1$, hence it is $-1$, and we are done. I just realized that I did not use the fact that $pequiv 3pmod4$ (all i used was $pneq 2$), so I guess the conditions can be weakened.






    share|cite|improve this answer











    $endgroup$




















      2












      $begingroup$

      For the first one, one just has to compute: $a^(p-1)/2 = x^2(p-1)/2 = x^p-1 = 1 mod p$.



      For the second one, let $p = 4k + 3$. $a^(p-1)/2$ is a root of $X^2 - 1$ (as above) which has only two solutions: $1$ and $-1$. If $a^(p-1)/2 = 1mod p$, $a^(p-1)/2a = a mod p$, and $a^(p-1)/2a = a^(p+1)/2 = a^2(k+1) = (a^k+1)^2$, hence $x^2 = a$ has a solution, which is a contradiction. Hence $a^(p-1)/2 = -1mod p$.






      share|cite|improve this answer











      $endgroup$




















        1












        $begingroup$

        This is an important theorem due to Leonhard Euler reworded in a different essence I think and it is usually proved at the beginning of an introduction to quadratic residues.



        First you need to know that in a complete residue system modulo $p$, there are exactly $fracp-12$ quadratic residues and $fracp-12$ non-residues and the quadratic residues are $1^2,2^2, cdots, (fracp-12)^2$. This could be checked as an easy exercise. If you needed further help with this let me know.



        By using Fermat's little theorem we know that $a^p-1 equiv 1 pmodp$.



        Now I'll give you a sketch of proof for Euler's criterion, you can work out the details on your own. You can factor $a^p-1 -1$ as $$a^p-1-1=(a^(p-1)/2-1)(a^(p-1)/2+1)$$



        $$implies 0 equiv a^p-1-1equiv (a^(p-1)/2-1)(a^(p-1)/2+1) pmodp$$



        But since $p$ is a prime number, then $a^(p-1)/2-1 equiv 0 pmodp$ or $a^(p-1)/2+1 equiv 0 pmodp$



        You can check that $1^2, 2^2, cdots, (fracp-12)^2$ satisfy $x^(p-1)/2 equiv 1 pmodp$. Now if you work out the details now which is easy I think it's obvious that $a$ is a non-residue if and only if $a^(p-1)/2 equiv -1 pmodp$.



        If you're familiar with Legendre's symbol you can state this theorem this way as well:



        $$left(fracapright) equiv a^(p-1)/2 pmod p;;text and left(fracapright) in -1,0,1$$.



        where Legendre's symbol is defined as:



        $$left(fracapright) = begincases;;,1 text if a text is a quadratic residue modulo ptext and a notequiv 0pmodp \-1 text if a text is a quadratic non-residue modulo p\;;,0 text if a equiv 0 pmodp. endcases$$






        share|cite|improve this answer









        $endgroup$




















          1












          $begingroup$

          $newcommandZpmathbbZ/pmathbbZ$Among the many proofs of these facts, let me mention one that uses basically only Fermat's little theorem, and then the fact that a polynomial of degree $n$ over a field has at most $n$ roots. And then of course you need to know that $Zp$ is a field, for $p$ prime.



          I take $p$ to be an odd prime.



          If $0 ne b in Zp$, then the equation
          $$
          x^2 = b^2
          $$
          has the two solutions $x = b, -b$, and no more, because $x^2 - b^2$ is a polynomial of degree $2$ over the field $Zp$.



          It follows that there are
          $$
          fracp-12
          $$
          non-zero squares in $Zp$.



          If $0 ne b in Zp$, we have
          $$
          (b^2)^(p-1)/2 = 1,
          $$
          so if $a = b^2$ is a non-zero square, then
          $$
          a^(p-1)/2 = 1.
          $$



          In other words, the non-zero squares in $Zp$ are roots of the polynomial
          $$
          f = x^(p-1)/2 - 1.
          $$
          Since there are $(p-1)/2$ squares, and $f$ has degree $(p-1)/2$, the non-zero squares are exactly the roots of the $f$.



          So if $a$ is a non-square, we have $a^(p-1)/2 ne 1$. Since
          $$
          (a^(p-1)/2)^2 = 1,
          $$
          we have that $a^(p-1)/2$ is a root of $x^2 - 1$, and it is different from $1$, so $a^(p-1)/2 = -1$.






          share|cite|improve this answer









          $endgroup$












            Your Answer





            StackExchange.ifUsing("editor", function ()
            return StackExchange.using("mathjaxEditing", function ()
            StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix)
            StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
            );
            );
            , "mathjax-editing");

            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "69"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader:
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            ,
            noCode: true, onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );













            draft saved

            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f502089%2fprove-that-ap-1-2-equiv-1-mod-p-and-ap-1-2-equiv-1-pmod-p%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown

























            5 Answers
            5






            active

            oldest

            votes








            5 Answers
            5






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            7












            $begingroup$

            Hints:



            (i) If $x^2 equiv a pmod p$ then what is $a^fracp-12$ as a power of $x$? Do this and apply Fermat's little theorem.



            (ii) Write $x=a^fracp-12$. Fermat's little theorem gives you $x^2 equiv 1 pmod p$. Now use the rest of the information you've been given.






            share|cite|improve this answer









            $endgroup$

















              7












              $begingroup$

              Hints:



              (i) If $x^2 equiv a pmod p$ then what is $a^fracp-12$ as a power of $x$? Do this and apply Fermat's little theorem.



              (ii) Write $x=a^fracp-12$. Fermat's little theorem gives you $x^2 equiv 1 pmod p$. Now use the rest of the information you've been given.






              share|cite|improve this answer









              $endgroup$















                7












                7








                7





                $begingroup$

                Hints:



                (i) If $x^2 equiv a pmod p$ then what is $a^fracp-12$ as a power of $x$? Do this and apply Fermat's little theorem.



                (ii) Write $x=a^fracp-12$. Fermat's little theorem gives you $x^2 equiv 1 pmod p$. Now use the rest of the information you've been given.






                share|cite|improve this answer









                $endgroup$



                Hints:



                (i) If $x^2 equiv a pmod p$ then what is $a^fracp-12$ as a power of $x$? Do this and apply Fermat's little theorem.



                (ii) Write $x=a^fracp-12$. Fermat's little theorem gives you $x^2 equiv 1 pmod p$. Now use the rest of the information you've been given.







                share|cite|improve this answer












                share|cite|improve this answer



                share|cite|improve this answer










                answered Sep 23 '13 at 5:45









                Clive NewsteadClive Newstead

                51.9k474136




                51.9k474136





















                    2












                    $begingroup$

                    For the first part, note that $x^p-1equiv 1$ by Fermat's little theorem. Then assuming that $p$ is not $2$ (deal with that case separetly), we have $1equiv (x^2)^(p-1)/2equiv a^(p-1)/2$.



                    For the second part, let $alpha$ be a primitive element (this means that there is an element $alpha$ in $1,...,p-1$ such that $alpha$ has order exactly $p-1$ (this means that $alpha^i$ will range through $mathbbZ_p^times$ as we let $i=1,2,..,p-1$).



                    Then, since $a$ is not a square, we have that $a=alpha^2c+1$, so $$a^(p-1)/2equiv (alpha^2c+1)^(p-1)/2equiv alpha^c(p-1)alpha^(p-1)/2equiv alpha^(p-1)/2$$Now note that $alpha^(p-1)/2$ is a root of $x^2-1$. Also note that $1$ and $-1$ are also roots. Note that we cannot have three roots (the degree of $x^2-1$ is $2$ and over a field, the degree bounds the number of roots), so we have that $alpha^(p-1)/2$ is either $1$ or $-1$, but it cannot be $1$ since the order of $alpha$ is $p-1$, hence it is $-1$, and we are done. I just realized that I did not use the fact that $pequiv 3pmod4$ (all i used was $pneq 2$), so I guess the conditions can be weakened.






                    share|cite|improve this answer











                    $endgroup$

















                      2












                      $begingroup$

                      For the first part, note that $x^p-1equiv 1$ by Fermat's little theorem. Then assuming that $p$ is not $2$ (deal with that case separetly), we have $1equiv (x^2)^(p-1)/2equiv a^(p-1)/2$.



                      For the second part, let $alpha$ be a primitive element (this means that there is an element $alpha$ in $1,...,p-1$ such that $alpha$ has order exactly $p-1$ (this means that $alpha^i$ will range through $mathbbZ_p^times$ as we let $i=1,2,..,p-1$).



                      Then, since $a$ is not a square, we have that $a=alpha^2c+1$, so $$a^(p-1)/2equiv (alpha^2c+1)^(p-1)/2equiv alpha^c(p-1)alpha^(p-1)/2equiv alpha^(p-1)/2$$Now note that $alpha^(p-1)/2$ is a root of $x^2-1$. Also note that $1$ and $-1$ are also roots. Note that we cannot have three roots (the degree of $x^2-1$ is $2$ and over a field, the degree bounds the number of roots), so we have that $alpha^(p-1)/2$ is either $1$ or $-1$, but it cannot be $1$ since the order of $alpha$ is $p-1$, hence it is $-1$, and we are done. I just realized that I did not use the fact that $pequiv 3pmod4$ (all i used was $pneq 2$), so I guess the conditions can be weakened.






                      share|cite|improve this answer











                      $endgroup$















                        2












                        2








                        2





                        $begingroup$

                        For the first part, note that $x^p-1equiv 1$ by Fermat's little theorem. Then assuming that $p$ is not $2$ (deal with that case separetly), we have $1equiv (x^2)^(p-1)/2equiv a^(p-1)/2$.



                        For the second part, let $alpha$ be a primitive element (this means that there is an element $alpha$ in $1,...,p-1$ such that $alpha$ has order exactly $p-1$ (this means that $alpha^i$ will range through $mathbbZ_p^times$ as we let $i=1,2,..,p-1$).



                        Then, since $a$ is not a square, we have that $a=alpha^2c+1$, so $$a^(p-1)/2equiv (alpha^2c+1)^(p-1)/2equiv alpha^c(p-1)alpha^(p-1)/2equiv alpha^(p-1)/2$$Now note that $alpha^(p-1)/2$ is a root of $x^2-1$. Also note that $1$ and $-1$ are also roots. Note that we cannot have three roots (the degree of $x^2-1$ is $2$ and over a field, the degree bounds the number of roots), so we have that $alpha^(p-1)/2$ is either $1$ or $-1$, but it cannot be $1$ since the order of $alpha$ is $p-1$, hence it is $-1$, and we are done. I just realized that I did not use the fact that $pequiv 3pmod4$ (all i used was $pneq 2$), so I guess the conditions can be weakened.






                        share|cite|improve this answer











                        $endgroup$



                        For the first part, note that $x^p-1equiv 1$ by Fermat's little theorem. Then assuming that $p$ is not $2$ (deal with that case separetly), we have $1equiv (x^2)^(p-1)/2equiv a^(p-1)/2$.



                        For the second part, let $alpha$ be a primitive element (this means that there is an element $alpha$ in $1,...,p-1$ such that $alpha$ has order exactly $p-1$ (this means that $alpha^i$ will range through $mathbbZ_p^times$ as we let $i=1,2,..,p-1$).



                        Then, since $a$ is not a square, we have that $a=alpha^2c+1$, so $$a^(p-1)/2equiv (alpha^2c+1)^(p-1)/2equiv alpha^c(p-1)alpha^(p-1)/2equiv alpha^(p-1)/2$$Now note that $alpha^(p-1)/2$ is a root of $x^2-1$. Also note that $1$ and $-1$ are also roots. Note that we cannot have three roots (the degree of $x^2-1$ is $2$ and over a field, the degree bounds the number of roots), so we have that $alpha^(p-1)/2$ is either $1$ or $-1$, but it cannot be $1$ since the order of $alpha$ is $p-1$, hence it is $-1$, and we are done. I just realized that I did not use the fact that $pequiv 3pmod4$ (all i used was $pneq 2$), so I guess the conditions can be weakened.







                        share|cite|improve this answer














                        share|cite|improve this answer



                        share|cite|improve this answer








                        edited Sep 23 '13 at 5:56

























                        answered Sep 23 '13 at 5:48









                        Daniel MontealegreDaniel Montealegre

                        4,8081644




                        4,8081644





















                            2












                            $begingroup$

                            For the first one, one just has to compute: $a^(p-1)/2 = x^2(p-1)/2 = x^p-1 = 1 mod p$.



                            For the second one, let $p = 4k + 3$. $a^(p-1)/2$ is a root of $X^2 - 1$ (as above) which has only two solutions: $1$ and $-1$. If $a^(p-1)/2 = 1mod p$, $a^(p-1)/2a = a mod p$, and $a^(p-1)/2a = a^(p+1)/2 = a^2(k+1) = (a^k+1)^2$, hence $x^2 = a$ has a solution, which is a contradiction. Hence $a^(p-1)/2 = -1mod p$.






                            share|cite|improve this answer











                            $endgroup$

















                              2












                              $begingroup$

                              For the first one, one just has to compute: $a^(p-1)/2 = x^2(p-1)/2 = x^p-1 = 1 mod p$.



                              For the second one, let $p = 4k + 3$. $a^(p-1)/2$ is a root of $X^2 - 1$ (as above) which has only two solutions: $1$ and $-1$. If $a^(p-1)/2 = 1mod p$, $a^(p-1)/2a = a mod p$, and $a^(p-1)/2a = a^(p+1)/2 = a^2(k+1) = (a^k+1)^2$, hence $x^2 = a$ has a solution, which is a contradiction. Hence $a^(p-1)/2 = -1mod p$.






                              share|cite|improve this answer











                              $endgroup$















                                2












                                2








                                2





                                $begingroup$

                                For the first one, one just has to compute: $a^(p-1)/2 = x^2(p-1)/2 = x^p-1 = 1 mod p$.



                                For the second one, let $p = 4k + 3$. $a^(p-1)/2$ is a root of $X^2 - 1$ (as above) which has only two solutions: $1$ and $-1$. If $a^(p-1)/2 = 1mod p$, $a^(p-1)/2a = a mod p$, and $a^(p-1)/2a = a^(p+1)/2 = a^2(k+1) = (a^k+1)^2$, hence $x^2 = a$ has a solution, which is a contradiction. Hence $a^(p-1)/2 = -1mod p$.






                                share|cite|improve this answer











                                $endgroup$



                                For the first one, one just has to compute: $a^(p-1)/2 = x^2(p-1)/2 = x^p-1 = 1 mod p$.



                                For the second one, let $p = 4k + 3$. $a^(p-1)/2$ is a root of $X^2 - 1$ (as above) which has only two solutions: $1$ and $-1$. If $a^(p-1)/2 = 1mod p$, $a^(p-1)/2a = a mod p$, and $a^(p-1)/2a = a^(p+1)/2 = a^2(k+1) = (a^k+1)^2$, hence $x^2 = a$ has a solution, which is a contradiction. Hence $a^(p-1)/2 = -1mod p$.







                                share|cite|improve this answer














                                share|cite|improve this answer



                                share|cite|improve this answer








                                edited Sep 24 '13 at 5:03

























                                answered Sep 23 '13 at 5:45









                                zarathustrazarathustra

                                4,14011029




                                4,14011029





















                                    1












                                    $begingroup$

                                    This is an important theorem due to Leonhard Euler reworded in a different essence I think and it is usually proved at the beginning of an introduction to quadratic residues.



                                    First you need to know that in a complete residue system modulo $p$, there are exactly $fracp-12$ quadratic residues and $fracp-12$ non-residues and the quadratic residues are $1^2,2^2, cdots, (fracp-12)^2$. This could be checked as an easy exercise. If you needed further help with this let me know.



                                    By using Fermat's little theorem we know that $a^p-1 equiv 1 pmodp$.



                                    Now I'll give you a sketch of proof for Euler's criterion, you can work out the details on your own. You can factor $a^p-1 -1$ as $$a^p-1-1=(a^(p-1)/2-1)(a^(p-1)/2+1)$$



                                    $$implies 0 equiv a^p-1-1equiv (a^(p-1)/2-1)(a^(p-1)/2+1) pmodp$$



                                    But since $p$ is a prime number, then $a^(p-1)/2-1 equiv 0 pmodp$ or $a^(p-1)/2+1 equiv 0 pmodp$



                                    You can check that $1^2, 2^2, cdots, (fracp-12)^2$ satisfy $x^(p-1)/2 equiv 1 pmodp$. Now if you work out the details now which is easy I think it's obvious that $a$ is a non-residue if and only if $a^(p-1)/2 equiv -1 pmodp$.



                                    If you're familiar with Legendre's symbol you can state this theorem this way as well:



                                    $$left(fracapright) equiv a^(p-1)/2 pmod p;;text and left(fracapright) in -1,0,1$$.



                                    where Legendre's symbol is defined as:



                                    $$left(fracapright) = begincases;;,1 text if a text is a quadratic residue modulo ptext and a notequiv 0pmodp \-1 text if a text is a quadratic non-residue modulo p\;;,0 text if a equiv 0 pmodp. endcases$$






                                    share|cite|improve this answer









                                    $endgroup$

















                                      1












                                      $begingroup$

                                      This is an important theorem due to Leonhard Euler reworded in a different essence I think and it is usually proved at the beginning of an introduction to quadratic residues.



                                      First you need to know that in a complete residue system modulo $p$, there are exactly $fracp-12$ quadratic residues and $fracp-12$ non-residues and the quadratic residues are $1^2,2^2, cdots, (fracp-12)^2$. This could be checked as an easy exercise. If you needed further help with this let me know.



                                      By using Fermat's little theorem we know that $a^p-1 equiv 1 pmodp$.



                                      Now I'll give you a sketch of proof for Euler's criterion, you can work out the details on your own. You can factor $a^p-1 -1$ as $$a^p-1-1=(a^(p-1)/2-1)(a^(p-1)/2+1)$$



                                      $$implies 0 equiv a^p-1-1equiv (a^(p-1)/2-1)(a^(p-1)/2+1) pmodp$$



                                      But since $p$ is a prime number, then $a^(p-1)/2-1 equiv 0 pmodp$ or $a^(p-1)/2+1 equiv 0 pmodp$



                                      You can check that $1^2, 2^2, cdots, (fracp-12)^2$ satisfy $x^(p-1)/2 equiv 1 pmodp$. Now if you work out the details now which is easy I think it's obvious that $a$ is a non-residue if and only if $a^(p-1)/2 equiv -1 pmodp$.



                                      If you're familiar with Legendre's symbol you can state this theorem this way as well:



                                      $$left(fracapright) equiv a^(p-1)/2 pmod p;;text and left(fracapright) in -1,0,1$$.



                                      where Legendre's symbol is defined as:



                                      $$left(fracapright) = begincases;;,1 text if a text is a quadratic residue modulo ptext and a notequiv 0pmodp \-1 text if a text is a quadratic non-residue modulo p\;;,0 text if a equiv 0 pmodp. endcases$$






                                      share|cite|improve this answer









                                      $endgroup$















                                        1












                                        1








                                        1





                                        $begingroup$

                                        This is an important theorem due to Leonhard Euler reworded in a different essence I think and it is usually proved at the beginning of an introduction to quadratic residues.



                                        First you need to know that in a complete residue system modulo $p$, there are exactly $fracp-12$ quadratic residues and $fracp-12$ non-residues and the quadratic residues are $1^2,2^2, cdots, (fracp-12)^2$. This could be checked as an easy exercise. If you needed further help with this let me know.



                                        By using Fermat's little theorem we know that $a^p-1 equiv 1 pmodp$.



                                        Now I'll give you a sketch of proof for Euler's criterion, you can work out the details on your own. You can factor $a^p-1 -1$ as $$a^p-1-1=(a^(p-1)/2-1)(a^(p-1)/2+1)$$



                                        $$implies 0 equiv a^p-1-1equiv (a^(p-1)/2-1)(a^(p-1)/2+1) pmodp$$



                                        But since $p$ is a prime number, then $a^(p-1)/2-1 equiv 0 pmodp$ or $a^(p-1)/2+1 equiv 0 pmodp$



                                        You can check that $1^2, 2^2, cdots, (fracp-12)^2$ satisfy $x^(p-1)/2 equiv 1 pmodp$. Now if you work out the details now which is easy I think it's obvious that $a$ is a non-residue if and only if $a^(p-1)/2 equiv -1 pmodp$.



                                        If you're familiar with Legendre's symbol you can state this theorem this way as well:



                                        $$left(fracapright) equiv a^(p-1)/2 pmod p;;text and left(fracapright) in -1,0,1$$.



                                        where Legendre's symbol is defined as:



                                        $$left(fracapright) = begincases;;,1 text if a text is a quadratic residue modulo ptext and a notequiv 0pmodp \-1 text if a text is a quadratic non-residue modulo p\;;,0 text if a equiv 0 pmodp. endcases$$






                                        share|cite|improve this answer









                                        $endgroup$



                                        This is an important theorem due to Leonhard Euler reworded in a different essence I think and it is usually proved at the beginning of an introduction to quadratic residues.



                                        First you need to know that in a complete residue system modulo $p$, there are exactly $fracp-12$ quadratic residues and $fracp-12$ non-residues and the quadratic residues are $1^2,2^2, cdots, (fracp-12)^2$. This could be checked as an easy exercise. If you needed further help with this let me know.



                                        By using Fermat's little theorem we know that $a^p-1 equiv 1 pmodp$.



                                        Now I'll give you a sketch of proof for Euler's criterion, you can work out the details on your own. You can factor $a^p-1 -1$ as $$a^p-1-1=(a^(p-1)/2-1)(a^(p-1)/2+1)$$



                                        $$implies 0 equiv a^p-1-1equiv (a^(p-1)/2-1)(a^(p-1)/2+1) pmodp$$



                                        But since $p$ is a prime number, then $a^(p-1)/2-1 equiv 0 pmodp$ or $a^(p-1)/2+1 equiv 0 pmodp$



                                        You can check that $1^2, 2^2, cdots, (fracp-12)^2$ satisfy $x^(p-1)/2 equiv 1 pmodp$. Now if you work out the details now which is easy I think it's obvious that $a$ is a non-residue if and only if $a^(p-1)/2 equiv -1 pmodp$.



                                        If you're familiar with Legendre's symbol you can state this theorem this way as well:



                                        $$left(fracapright) equiv a^(p-1)/2 pmod p;;text and left(fracapright) in -1,0,1$$.



                                        where Legendre's symbol is defined as:



                                        $$left(fracapright) = begincases;;,1 text if a text is a quadratic residue modulo ptext and a notequiv 0pmodp \-1 text if a text is a quadratic non-residue modulo p\;;,0 text if a equiv 0 pmodp. endcases$$







                                        share|cite|improve this answer












                                        share|cite|improve this answer



                                        share|cite|improve this answer










                                        answered Sep 23 '13 at 7:41









                                        user66733user66733

                                        4,82821450




                                        4,82821450





















                                            1












                                            $begingroup$

                                            $newcommandZpmathbbZ/pmathbbZ$Among the many proofs of these facts, let me mention one that uses basically only Fermat's little theorem, and then the fact that a polynomial of degree $n$ over a field has at most $n$ roots. And then of course you need to know that $Zp$ is a field, for $p$ prime.



                                            I take $p$ to be an odd prime.



                                            If $0 ne b in Zp$, then the equation
                                            $$
                                            x^2 = b^2
                                            $$
                                            has the two solutions $x = b, -b$, and no more, because $x^2 - b^2$ is a polynomial of degree $2$ over the field $Zp$.



                                            It follows that there are
                                            $$
                                            fracp-12
                                            $$
                                            non-zero squares in $Zp$.



                                            If $0 ne b in Zp$, we have
                                            $$
                                            (b^2)^(p-1)/2 = 1,
                                            $$
                                            so if $a = b^2$ is a non-zero square, then
                                            $$
                                            a^(p-1)/2 = 1.
                                            $$



                                            In other words, the non-zero squares in $Zp$ are roots of the polynomial
                                            $$
                                            f = x^(p-1)/2 - 1.
                                            $$
                                            Since there are $(p-1)/2$ squares, and $f$ has degree $(p-1)/2$, the non-zero squares are exactly the roots of the $f$.



                                            So if $a$ is a non-square, we have $a^(p-1)/2 ne 1$. Since
                                            $$
                                            (a^(p-1)/2)^2 = 1,
                                            $$
                                            we have that $a^(p-1)/2$ is a root of $x^2 - 1$, and it is different from $1$, so $a^(p-1)/2 = -1$.






                                            share|cite|improve this answer









                                            $endgroup$

















                                              1












                                              $begingroup$

                                              $newcommandZpmathbbZ/pmathbbZ$Among the many proofs of these facts, let me mention one that uses basically only Fermat's little theorem, and then the fact that a polynomial of degree $n$ over a field has at most $n$ roots. And then of course you need to know that $Zp$ is a field, for $p$ prime.



                                              I take $p$ to be an odd prime.



                                              If $0 ne b in Zp$, then the equation
                                              $$
                                              x^2 = b^2
                                              $$
                                              has the two solutions $x = b, -b$, and no more, because $x^2 - b^2$ is a polynomial of degree $2$ over the field $Zp$.



                                              It follows that there are
                                              $$
                                              fracp-12
                                              $$
                                              non-zero squares in $Zp$.



                                              If $0 ne b in Zp$, we have
                                              $$
                                              (b^2)^(p-1)/2 = 1,
                                              $$
                                              so if $a = b^2$ is a non-zero square, then
                                              $$
                                              a^(p-1)/2 = 1.
                                              $$



                                              In other words, the non-zero squares in $Zp$ are roots of the polynomial
                                              $$
                                              f = x^(p-1)/2 - 1.
                                              $$
                                              Since there are $(p-1)/2$ squares, and $f$ has degree $(p-1)/2$, the non-zero squares are exactly the roots of the $f$.



                                              So if $a$ is a non-square, we have $a^(p-1)/2 ne 1$. Since
                                              $$
                                              (a^(p-1)/2)^2 = 1,
                                              $$
                                              we have that $a^(p-1)/2$ is a root of $x^2 - 1$, and it is different from $1$, so $a^(p-1)/2 = -1$.






                                              share|cite|improve this answer









                                              $endgroup$















                                                1












                                                1








                                                1





                                                $begingroup$

                                                $newcommandZpmathbbZ/pmathbbZ$Among the many proofs of these facts, let me mention one that uses basically only Fermat's little theorem, and then the fact that a polynomial of degree $n$ over a field has at most $n$ roots. And then of course you need to know that $Zp$ is a field, for $p$ prime.



                                                I take $p$ to be an odd prime.



                                                If $0 ne b in Zp$, then the equation
                                                $$
                                                x^2 = b^2
                                                $$
                                                has the two solutions $x = b, -b$, and no more, because $x^2 - b^2$ is a polynomial of degree $2$ over the field $Zp$.



                                                It follows that there are
                                                $$
                                                fracp-12
                                                $$
                                                non-zero squares in $Zp$.



                                                If $0 ne b in Zp$, we have
                                                $$
                                                (b^2)^(p-1)/2 = 1,
                                                $$
                                                so if $a = b^2$ is a non-zero square, then
                                                $$
                                                a^(p-1)/2 = 1.
                                                $$



                                                In other words, the non-zero squares in $Zp$ are roots of the polynomial
                                                $$
                                                f = x^(p-1)/2 - 1.
                                                $$
                                                Since there are $(p-1)/2$ squares, and $f$ has degree $(p-1)/2$, the non-zero squares are exactly the roots of the $f$.



                                                So if $a$ is a non-square, we have $a^(p-1)/2 ne 1$. Since
                                                $$
                                                (a^(p-1)/2)^2 = 1,
                                                $$
                                                we have that $a^(p-1)/2$ is a root of $x^2 - 1$, and it is different from $1$, so $a^(p-1)/2 = -1$.






                                                share|cite|improve this answer









                                                $endgroup$



                                                $newcommandZpmathbbZ/pmathbbZ$Among the many proofs of these facts, let me mention one that uses basically only Fermat's little theorem, and then the fact that a polynomial of degree $n$ over a field has at most $n$ roots. And then of course you need to know that $Zp$ is a field, for $p$ prime.



                                                I take $p$ to be an odd prime.



                                                If $0 ne b in Zp$, then the equation
                                                $$
                                                x^2 = b^2
                                                $$
                                                has the two solutions $x = b, -b$, and no more, because $x^2 - b^2$ is a polynomial of degree $2$ over the field $Zp$.



                                                It follows that there are
                                                $$
                                                fracp-12
                                                $$
                                                non-zero squares in $Zp$.



                                                If $0 ne b in Zp$, we have
                                                $$
                                                (b^2)^(p-1)/2 = 1,
                                                $$
                                                so if $a = b^2$ is a non-zero square, then
                                                $$
                                                a^(p-1)/2 = 1.
                                                $$



                                                In other words, the non-zero squares in $Zp$ are roots of the polynomial
                                                $$
                                                f = x^(p-1)/2 - 1.
                                                $$
                                                Since there are $(p-1)/2$ squares, and $f$ has degree $(p-1)/2$, the non-zero squares are exactly the roots of the $f$.



                                                So if $a$ is a non-square, we have $a^(p-1)/2 ne 1$. Since
                                                $$
                                                (a^(p-1)/2)^2 = 1,
                                                $$
                                                we have that $a^(p-1)/2$ is a root of $x^2 - 1$, and it is different from $1$, so $a^(p-1)/2 = -1$.







                                                share|cite|improve this answer












                                                share|cite|improve this answer



                                                share|cite|improve this answer










                                                answered Sep 23 '13 at 8:45









                                                Andreas CarantiAndreas Caranti

                                                56.8k34397




                                                56.8k34397



























                                                    draft saved

                                                    draft discarded
















































                                                    Thanks for contributing an answer to Mathematics Stack Exchange!


                                                    • Please be sure to answer the question. Provide details and share your research!

                                                    But avoid


                                                    • Asking for help, clarification, or responding to other answers.

                                                    • Making statements based on opinion; back them up with references or personal experience.

                                                    Use MathJax to format equations. MathJax reference.


                                                    To learn more, see our tips on writing great answers.




                                                    draft saved


                                                    draft discarded














                                                    StackExchange.ready(
                                                    function ()
                                                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f502089%2fprove-that-ap-1-2-equiv-1-mod-p-and-ap-1-2-equiv-1-pmod-p%23new-answer', 'question_page');

                                                    );

                                                    Post as a guest















                                                    Required, but never shown





















































                                                    Required, but never shown














                                                    Required, but never shown












                                                    Required, but never shown







                                                    Required, but never shown

































                                                    Required, but never shown














                                                    Required, but never shown












                                                    Required, but never shown







                                                    Required, but never shown







                                                    Popular posts from this blog

                                                    Solar Wings Breeze Design and development Specifications (Breeze) References Navigation menu1368-485X"Hang glider: Breeze (Solar Wings)"e

                                                    Kathakali Contents Etymology and nomenclature History Repertoire Songs and musical instruments Traditional plays Styles: Sampradayam Training centers and awards Relationship to other dance forms See also Notes References External links Navigation menueThe Illustrated Encyclopedia of Hinduism: A-MSouth Asian Folklore: An EncyclopediaRoutledge International Encyclopedia of Women: Global Women's Issues and KnowledgeKathakali Dance-drama: Where Gods and Demons Come to PlayKathakali Dance-drama: Where Gods and Demons Come to PlayKathakali Dance-drama: Where Gods and Demons Come to Play10.1353/atj.2005.0004The Illustrated Encyclopedia of Hinduism: A-MEncyclopedia of HinduismKathakali Dance-drama: Where Gods and Demons Come to PlaySonic Liturgy: Ritual and Music in Hindu Tradition"The Mirror of Gesture"Kathakali Dance-drama: Where Gods and Demons Come to Play"Kathakali"Indian Theatre: Traditions of PerformanceIndian Theatre: Traditions of PerformanceIndian Theatre: Traditions of PerformanceIndian Theatre: Traditions of PerformanceMedieval Indian Literature: An AnthologyThe Oxford Companion to Indian TheatreSouth Asian Folklore: An Encyclopedia : Afghanistan, Bangladesh, India, Nepal, Pakistan, Sri LankaThe Rise of Performance Studies: Rethinking Richard Schechner's Broad SpectrumIndian Theatre: Traditions of PerformanceModern Asian Theatre and Performance 1900-2000Critical Theory and PerformanceBetween Theater and AnthropologyKathakali603847011Indian Theatre: Traditions of PerformanceIndian Theatre: Traditions of PerformanceIndian Theatre: Traditions of PerformanceBetween Theater and AnthropologyBetween Theater and AnthropologyNambeesan Smaraka AwardsArchivedThe Cambridge Guide to TheatreRoutledge International Encyclopedia of Women: Global Women's Issues and KnowledgeThe Garland Encyclopedia of World Music: South Asia : the Indian subcontinentThe Ethos of Noh: Actors and Their Art10.2307/1145740By Means of Performance: Intercultural Studies of Theatre and Ritual10.1017/s204912550000100xReconceiving the Renaissance: A Critical ReaderPerformance TheoryListening to Theatre: The Aural Dimension of Beijing Opera10.2307/1146013Kathakali: The Art of the Non-WorldlyOn KathakaliKathakali, the dance theatreThe Kathakali Complex: Performance & StructureKathakali Dance-Drama: Where Gods and Demons Come to Play10.1093/obo/9780195399318-0071Drama and Ritual of Early Hinduism"In the Shadow of Hollywood Orientalism: Authentic East Indian Dancing"10.1080/08949460490274013Sanskrit Play Production in Ancient IndiaIndian Music: History and StructureBharata, the Nāṭyaśāstra233639306Table of Contents2238067286469807Dance In Indian Painting10.2307/32047833204783Kathakali Dance-Theatre: A Visual Narrative of Sacred Indian MimeIndian Classical Dance: The Renaissance and BeyondKathakali: an indigenous art-form of Keralaeee

                                                    Method to test if a number is a perfect power? Announcing the arrival of Valued Associate #679: Cesar Manara Planned maintenance scheduled April 23, 2019 at 00:00UTC (8:00pm US/Eastern)Detecting perfect squares faster than by extracting square rooteffective way to get the integer sequence A181392 from oeisA rarely mentioned fact about perfect powersHow many numbers such $n$ are there that $n<100,lfloorsqrtn rfloor mid n$Check perfect squareness by modulo division against multiple basesFor what pair of integers $(a,b)$ is $3^a + 7^b$ a perfect square.Do there exist any positive integers $n$ such that $lfloore^nrfloor$ is a perfect power? What is the probability that one exists?finding perfect power factors of an integerProve that the sequence contains a perfect square for any natural number $m $ in the domain of $f$ .Counting Perfect Powers