Can you substitute congruences into an expression if the conditions are right?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
1
down vote

favorite












When using a congruences can we substitute them into an expression. For example, when we look at Fermat's little theorem we notice that $a^p$ is congruent to $a (textmod p)$ when $a$ is an integer and $p$ is prime, so where ever we see $a^p$ where $a$ is an integer and $p$ is prime, can we simply substitute $a (textmod p)$ for $a^p$?







share|cite|improve this question

























    up vote
    1
    down vote

    favorite












    When using a congruences can we substitute them into an expression. For example, when we look at Fermat's little theorem we notice that $a^p$ is congruent to $a (textmod p)$ when $a$ is an integer and $p$ is prime, so where ever we see $a^p$ where $a$ is an integer and $p$ is prime, can we simply substitute $a (textmod p)$ for $a^p$?







    share|cite|improve this question























      up vote
      1
      down vote

      favorite









      up vote
      1
      down vote

      favorite











      When using a congruences can we substitute them into an expression. For example, when we look at Fermat's little theorem we notice that $a^p$ is congruent to $a (textmod p)$ when $a$ is an integer and $p$ is prime, so where ever we see $a^p$ where $a$ is an integer and $p$ is prime, can we simply substitute $a (textmod p)$ for $a^p$?







      share|cite|improve this question













      When using a congruences can we substitute them into an expression. For example, when we look at Fermat's little theorem we notice that $a^p$ is congruent to $a (textmod p)$ when $a$ is an integer and $p$ is prime, so where ever we see $a^p$ where $a$ is an integer and $p$ is prime, can we simply substitute $a (textmod p)$ for $a^p$?









      share|cite|improve this question












      share|cite|improve this question




      share|cite|improve this question








      edited Jul 25 at 18:43
























      asked Jul 24 at 6:29









      Charles Quinn

      533




      533




















          3 Answers
          3






          active

          oldest

          votes

















          up vote
          0
          down vote



          accepted










          Yes in general using congruences all algebraic rules hold for for the sum and product and we can substitute them into an expression, notably for



          • $Aequiv a mod p$

          • $Bequiv b mod p$

          we have that



          • $A+Bequiv a+b mod p$

          • $Acdot Bequiv acdot b mod p$





          share|cite|improve this answer





















          • Thank you. I do remember in foundations that you can manipulate congruences like that. I wasn't sure. Thanks again.
            – Charles Quinn
            Jul 25 at 4:25


















          up vote
          0
          down vote













          No. It would be very bad notation in some cases.



          For example, if you replace $a^p$ by $apmod p$ in the equation $$a^ptimes5=5a^p$$ then you get $$apmod ptimes5=5apmod p$$ so the RHS would be very ambiguous. Do you mean $5apmod p$ or $5times[apmod p]$?






          share|cite|improve this answer





















          • If I do, then I must be careful.
            – Charles Quinn
            Jul 24 at 22:32


















          up vote
          0
          down vote













          So, what about taking the Pythagorean triples as an example. We know for Pythagorean triples $x,y,$ and $z$ are integers in $x^2+y^2=z^2$. By Fermats little theorem, we know



          • $a^2equiva (textmod 2)$ where $ainmathbbz$

          So, $x^2+y^2=z^2$ yields,



          • $x+yequivz (textmod 2)$





          share|cite|improve this answer





















            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',
            convertImagesToLinks: true,
            noModals: false,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            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%2f2861066%2fcan-you-substitute-congruences-into-an-expression-if-the-conditions-are-right%23new-answer', 'question_page');

            );

            Post as a guest






























            3 Answers
            3






            active

            oldest

            votes








            3 Answers
            3






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes








            up vote
            0
            down vote



            accepted










            Yes in general using congruences all algebraic rules hold for for the sum and product and we can substitute them into an expression, notably for



            • $Aequiv a mod p$

            • $Bequiv b mod p$

            we have that



            • $A+Bequiv a+b mod p$

            • $Acdot Bequiv acdot b mod p$





            share|cite|improve this answer





















            • Thank you. I do remember in foundations that you can manipulate congruences like that. I wasn't sure. Thanks again.
              – Charles Quinn
              Jul 25 at 4:25















            up vote
            0
            down vote



            accepted










            Yes in general using congruences all algebraic rules hold for for the sum and product and we can substitute them into an expression, notably for



            • $Aequiv a mod p$

            • $Bequiv b mod p$

            we have that



            • $A+Bequiv a+b mod p$

            • $Acdot Bequiv acdot b mod p$





            share|cite|improve this answer





















            • Thank you. I do remember in foundations that you can manipulate congruences like that. I wasn't sure. Thanks again.
              – Charles Quinn
              Jul 25 at 4:25













            up vote
            0
            down vote



            accepted







            up vote
            0
            down vote



            accepted






            Yes in general using congruences all algebraic rules hold for for the sum and product and we can substitute them into an expression, notably for



            • $Aequiv a mod p$

            • $Bequiv b mod p$

            we have that



            • $A+Bequiv a+b mod p$

            • $Acdot Bequiv acdot b mod p$





            share|cite|improve this answer













            Yes in general using congruences all algebraic rules hold for for the sum and product and we can substitute them into an expression, notably for



            • $Aequiv a mod p$

            • $Bequiv b mod p$

            we have that



            • $A+Bequiv a+b mod p$

            • $Acdot Bequiv acdot b mod p$






            share|cite|improve this answer













            share|cite|improve this answer



            share|cite|improve this answer











            answered Jul 24 at 6:36









            gimusi

            65.2k73583




            65.2k73583











            • Thank you. I do remember in foundations that you can manipulate congruences like that. I wasn't sure. Thanks again.
              – Charles Quinn
              Jul 25 at 4:25

















            • Thank you. I do remember in foundations that you can manipulate congruences like that. I wasn't sure. Thanks again.
              – Charles Quinn
              Jul 25 at 4:25
















            Thank you. I do remember in foundations that you can manipulate congruences like that. I wasn't sure. Thanks again.
            – Charles Quinn
            Jul 25 at 4:25





            Thank you. I do remember in foundations that you can manipulate congruences like that. I wasn't sure. Thanks again.
            – Charles Quinn
            Jul 25 at 4:25











            up vote
            0
            down vote













            No. It would be very bad notation in some cases.



            For example, if you replace $a^p$ by $apmod p$ in the equation $$a^ptimes5=5a^p$$ then you get $$apmod ptimes5=5apmod p$$ so the RHS would be very ambiguous. Do you mean $5apmod p$ or $5times[apmod p]$?






            share|cite|improve this answer





















            • If I do, then I must be careful.
              – Charles Quinn
              Jul 24 at 22:32















            up vote
            0
            down vote













            No. It would be very bad notation in some cases.



            For example, if you replace $a^p$ by $apmod p$ in the equation $$a^ptimes5=5a^p$$ then you get $$apmod ptimes5=5apmod p$$ so the RHS would be very ambiguous. Do you mean $5apmod p$ or $5times[apmod p]$?






            share|cite|improve this answer





















            • If I do, then I must be careful.
              – Charles Quinn
              Jul 24 at 22:32













            up vote
            0
            down vote










            up vote
            0
            down vote









            No. It would be very bad notation in some cases.



            For example, if you replace $a^p$ by $apmod p$ in the equation $$a^ptimes5=5a^p$$ then you get $$apmod ptimes5=5apmod p$$ so the RHS would be very ambiguous. Do you mean $5apmod p$ or $5times[apmod p]$?






            share|cite|improve this answer













            No. It would be very bad notation in some cases.



            For example, if you replace $a^p$ by $apmod p$ in the equation $$a^ptimes5=5a^p$$ then you get $$apmod ptimes5=5apmod p$$ so the RHS would be very ambiguous. Do you mean $5apmod p$ or $5times[apmod p]$?







            share|cite|improve this answer













            share|cite|improve this answer



            share|cite|improve this answer











            answered Jul 24 at 6:39









            TheSimpliFire

            9,61461851




            9,61461851











            • If I do, then I must be careful.
              – Charles Quinn
              Jul 24 at 22:32

















            • If I do, then I must be careful.
              – Charles Quinn
              Jul 24 at 22:32
















            If I do, then I must be careful.
            – Charles Quinn
            Jul 24 at 22:32





            If I do, then I must be careful.
            – Charles Quinn
            Jul 24 at 22:32











            up vote
            0
            down vote













            So, what about taking the Pythagorean triples as an example. We know for Pythagorean triples $x,y,$ and $z$ are integers in $x^2+y^2=z^2$. By Fermats little theorem, we know



            • $a^2equiva (textmod 2)$ where $ainmathbbz$

            So, $x^2+y^2=z^2$ yields,



            • $x+yequivz (textmod 2)$





            share|cite|improve this answer

























              up vote
              0
              down vote













              So, what about taking the Pythagorean triples as an example. We know for Pythagorean triples $x,y,$ and $z$ are integers in $x^2+y^2=z^2$. By Fermats little theorem, we know



              • $a^2equiva (textmod 2)$ where $ainmathbbz$

              So, $x^2+y^2=z^2$ yields,



              • $x+yequivz (textmod 2)$





              share|cite|improve this answer























                up vote
                0
                down vote










                up vote
                0
                down vote









                So, what about taking the Pythagorean triples as an example. We know for Pythagorean triples $x,y,$ and $z$ are integers in $x^2+y^2=z^2$. By Fermats little theorem, we know



                • $a^2equiva (textmod 2)$ where $ainmathbbz$

                So, $x^2+y^2=z^2$ yields,



                • $x+yequivz (textmod 2)$





                share|cite|improve this answer













                So, what about taking the Pythagorean triples as an example. We know for Pythagorean triples $x,y,$ and $z$ are integers in $x^2+y^2=z^2$. By Fermats little theorem, we know



                • $a^2equiva (textmod 2)$ where $ainmathbbz$

                So, $x^2+y^2=z^2$ yields,



                • $x+yequivz (textmod 2)$






                share|cite|improve this answer













                share|cite|improve this answer



                share|cite|improve this answer











                answered Jul 24 at 23:08









                Charles Quinn

                533




                533






















                     

                    draft saved


                    draft discarded


























                     


                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f2861066%2fcan-you-substitute-congruences-into-an-expression-if-the-conditions-are-right%23new-answer', 'question_page');

                    );

                    Post as a guest













































































                    Comments

                    Popular posts from this blog

                    What is the equation of a 3D cone with generalised tilt?

                    Color the edges and diagonals of a regular polygon

                    Relationship between determinant of matrix and determinant of adjoint?