Finding the values of $x$ such that $[x^2]=[x]^2$ ($[cdot]$ denotes the floor function)

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











up vote
6
down vote

favorite
1












I was trying to find the values of $x$ that makes the equation $[x^2]=[x]^2$ true where $[cdot]$ denotes the floor function. I tried doing the following:



Let $x=n+r$ where $n=[x]$ and $0leq r<1$. Then $x^2=n^2+2nr+r^2$ which implies that $[x^2]=[n^2+2nr+r^2]=n^2+[2nr+r^2]=[x]^2=n^2$. Subtracting both sides of the equation by $n^2$ I obtained $[2nr+r^2]=0$ if and only if $0leq 2nr+r^2<1$. I got stucked in here. Any suggestions or hints that can you give me?







share|cite|improve this question

























    up vote
    6
    down vote

    favorite
    1












    I was trying to find the values of $x$ that makes the equation $[x^2]=[x]^2$ true where $[cdot]$ denotes the floor function. I tried doing the following:



    Let $x=n+r$ where $n=[x]$ and $0leq r<1$. Then $x^2=n^2+2nr+r^2$ which implies that $[x^2]=[n^2+2nr+r^2]=n^2+[2nr+r^2]=[x]^2=n^2$. Subtracting both sides of the equation by $n^2$ I obtained $[2nr+r^2]=0$ if and only if $0leq 2nr+r^2<1$. I got stucked in here. Any suggestions or hints that can you give me?







    share|cite|improve this question























      up vote
      6
      down vote

      favorite
      1









      up vote
      6
      down vote

      favorite
      1






      1





      I was trying to find the values of $x$ that makes the equation $[x^2]=[x]^2$ true where $[cdot]$ denotes the floor function. I tried doing the following:



      Let $x=n+r$ where $n=[x]$ and $0leq r<1$. Then $x^2=n^2+2nr+r^2$ which implies that $[x^2]=[n^2+2nr+r^2]=n^2+[2nr+r^2]=[x]^2=n^2$. Subtracting both sides of the equation by $n^2$ I obtained $[2nr+r^2]=0$ if and only if $0leq 2nr+r^2<1$. I got stucked in here. Any suggestions or hints that can you give me?







      share|cite|improve this question













      I was trying to find the values of $x$ that makes the equation $[x^2]=[x]^2$ true where $[cdot]$ denotes the floor function. I tried doing the following:



      Let $x=n+r$ where $n=[x]$ and $0leq r<1$. Then $x^2=n^2+2nr+r^2$ which implies that $[x^2]=[n^2+2nr+r^2]=n^2+[2nr+r^2]=[x]^2=n^2$. Subtracting both sides of the equation by $n^2$ I obtained $[2nr+r^2]=0$ if and only if $0leq 2nr+r^2<1$. I got stucked in here. Any suggestions or hints that can you give me?









      share|cite|improve this question












      share|cite|improve this question




      share|cite|improve this question








      edited Jul 27 at 21:59
























      asked Jul 27 at 4:43









      user573497

      2009




      2009




















          4 Answers
          4






          active

          oldest

          votes

















          up vote
          5
          down vote



          accepted










          $$0leq 2nr+r^2<1$$



          Solve$$ 2nr+r^2-1=0$$ for $r$ in terms of $n$.



          $$ r=-npm sqrt n^2+1 $$



          For $$-n- sqrt n^2+1 <r< -n+sqrt n^2+1$$



          We get $$0leq 2nr+r^2<1$$



          Since $rge 0$, we just need $$ r< -n+sqrt n^2+1$$



          For example if $n=10$, we have to have $r<sqrt 101-10 approx 0.049875$






          share|cite|improve this answer

















          • 1




            The inequality $0 leqslant 2nr + r^2$ is not for free when $n < 0$, which makes the answer incomplete.
            – Adayah
            Jul 27 at 14:32

















          up vote
          8
          down vote













          Write $x=n+r$, where $ninmathbbZ$ and $0le rlt1$. Then we want
          $$
          leftlfloor n^2+2nr+r^2rightrfloor=leftlfloor(n+r)^2rightrfloor=lfloor n+rrfloor^2=n^2tag1
          $$
          If $r=0$, then $(1)$ is true. Thus, we have any $xinmathbbZ$ is a solution.



          Now, assume $0lt rlt1$. $(1)$ requires
          $$
          0le2nr+r^2lt1tag2
          $$
          To satisfy the left-hand inequality of $(2)$, we need
          $$
          2n+rge0tag3
          $$
          So we need $nge0$. To satisfy the right-hand inequality of $(2)$, we need
          $$
          0lt rlt-n+sqrtn^2+1tag4
          $$
          which is equivalent to
          $$
          nlt xltsqrtn^2+1tag5
          $$
          Therefore, we get the complete solution set to be
          $$
          xinmathbbZcupbigcup_n=0^inftyleft(n,sqrtn^2+1right)tag6
          $$






          share|cite|improve this answer





















          • I really liked your solution! Thank you very much!
            – user573497
            Jul 27 at 5:54










          • Can eq.6 be simplified to $$xinbigcup_n=0^inftybigg[n,sqrtn^2+1bigg)tag6$$?
            – AccidentalFourierTransform
            Jul 27 at 17:09











          • @AccidentalFourierTransform: that leaves out all the negative integers.
            – robjohn♦
            Jul 27 at 18:11










          • @robjohn Ah, right. Silly me.
            – AccidentalFourierTransform
            Jul 27 at 18:28

















          up vote
          1
          down vote













          I'm not sure there is going to be a "clean" solution of this, you will have to consider various cases.



          • If $r=0$ the inequalities are clearly true.

          • If $r>0$ and $n<0$ then $2nle-2$ so $2n+r<0$ so $2nr+r^2<0$ and there is no solution.

          • The remaining case is $r>0$ and $nge0$. Then $0le2nr+r^2$ is certainly true, so you have to solve $2nr+r^2<1$ to find $r$ in terms of $n$.

          See if you can finish it from here.






          share|cite|improve this answer




























            up vote
            1
            down vote













            I think that you have done almost everything. In your notation you have the following inequalities: $r>=0$, $r<1$, $r^2+2nr-1<0$. The last one gives $r<sqrtn^2+1-n$. This gives possible values of $r$ for given $n>=0$. For negative $n$ your computation is not correct.






            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%2f2864058%2ffinding-the-values-of-x-such-that-x2-x2-cdot-denotes-the-floor-f%23new-answer', 'question_page');

              );

              Post as a guest






























              4 Answers
              4






              active

              oldest

              votes








              4 Answers
              4






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes








              up vote
              5
              down vote



              accepted










              $$0leq 2nr+r^2<1$$



              Solve$$ 2nr+r^2-1=0$$ for $r$ in terms of $n$.



              $$ r=-npm sqrt n^2+1 $$



              For $$-n- sqrt n^2+1 <r< -n+sqrt n^2+1$$



              We get $$0leq 2nr+r^2<1$$



              Since $rge 0$, we just need $$ r< -n+sqrt n^2+1$$



              For example if $n=10$, we have to have $r<sqrt 101-10 approx 0.049875$






              share|cite|improve this answer

















              • 1




                The inequality $0 leqslant 2nr + r^2$ is not for free when $n < 0$, which makes the answer incomplete.
                – Adayah
                Jul 27 at 14:32














              up vote
              5
              down vote



              accepted










              $$0leq 2nr+r^2<1$$



              Solve$$ 2nr+r^2-1=0$$ for $r$ in terms of $n$.



              $$ r=-npm sqrt n^2+1 $$



              For $$-n- sqrt n^2+1 <r< -n+sqrt n^2+1$$



              We get $$0leq 2nr+r^2<1$$



              Since $rge 0$, we just need $$ r< -n+sqrt n^2+1$$



              For example if $n=10$, we have to have $r<sqrt 101-10 approx 0.049875$






              share|cite|improve this answer

















              • 1




                The inequality $0 leqslant 2nr + r^2$ is not for free when $n < 0$, which makes the answer incomplete.
                – Adayah
                Jul 27 at 14:32












              up vote
              5
              down vote



              accepted







              up vote
              5
              down vote



              accepted






              $$0leq 2nr+r^2<1$$



              Solve$$ 2nr+r^2-1=0$$ for $r$ in terms of $n$.



              $$ r=-npm sqrt n^2+1 $$



              For $$-n- sqrt n^2+1 <r< -n+sqrt n^2+1$$



              We get $$0leq 2nr+r^2<1$$



              Since $rge 0$, we just need $$ r< -n+sqrt n^2+1$$



              For example if $n=10$, we have to have $r<sqrt 101-10 approx 0.049875$






              share|cite|improve this answer













              $$0leq 2nr+r^2<1$$



              Solve$$ 2nr+r^2-1=0$$ for $r$ in terms of $n$.



              $$ r=-npm sqrt n^2+1 $$



              For $$-n- sqrt n^2+1 <r< -n+sqrt n^2+1$$



              We get $$0leq 2nr+r^2<1$$



              Since $rge 0$, we just need $$ r< -n+sqrt n^2+1$$



              For example if $n=10$, we have to have $r<sqrt 101-10 approx 0.049875$







              share|cite|improve this answer













              share|cite|improve this answer



              share|cite|improve this answer











              answered Jul 27 at 5:22









              Mohammad Riazi-Kermani

              27.3k41851




              27.3k41851







              • 1




                The inequality $0 leqslant 2nr + r^2$ is not for free when $n < 0$, which makes the answer incomplete.
                – Adayah
                Jul 27 at 14:32












              • 1




                The inequality $0 leqslant 2nr + r^2$ is not for free when $n < 0$, which makes the answer incomplete.
                – Adayah
                Jul 27 at 14:32







              1




              1




              The inequality $0 leqslant 2nr + r^2$ is not for free when $n < 0$, which makes the answer incomplete.
              – Adayah
              Jul 27 at 14:32




              The inequality $0 leqslant 2nr + r^2$ is not for free when $n < 0$, which makes the answer incomplete.
              – Adayah
              Jul 27 at 14:32










              up vote
              8
              down vote













              Write $x=n+r$, where $ninmathbbZ$ and $0le rlt1$. Then we want
              $$
              leftlfloor n^2+2nr+r^2rightrfloor=leftlfloor(n+r)^2rightrfloor=lfloor n+rrfloor^2=n^2tag1
              $$
              If $r=0$, then $(1)$ is true. Thus, we have any $xinmathbbZ$ is a solution.



              Now, assume $0lt rlt1$. $(1)$ requires
              $$
              0le2nr+r^2lt1tag2
              $$
              To satisfy the left-hand inequality of $(2)$, we need
              $$
              2n+rge0tag3
              $$
              So we need $nge0$. To satisfy the right-hand inequality of $(2)$, we need
              $$
              0lt rlt-n+sqrtn^2+1tag4
              $$
              which is equivalent to
              $$
              nlt xltsqrtn^2+1tag5
              $$
              Therefore, we get the complete solution set to be
              $$
              xinmathbbZcupbigcup_n=0^inftyleft(n,sqrtn^2+1right)tag6
              $$






              share|cite|improve this answer





















              • I really liked your solution! Thank you very much!
                – user573497
                Jul 27 at 5:54










              • Can eq.6 be simplified to $$xinbigcup_n=0^inftybigg[n,sqrtn^2+1bigg)tag6$$?
                – AccidentalFourierTransform
                Jul 27 at 17:09











              • @AccidentalFourierTransform: that leaves out all the negative integers.
                – robjohn♦
                Jul 27 at 18:11










              • @robjohn Ah, right. Silly me.
                – AccidentalFourierTransform
                Jul 27 at 18:28














              up vote
              8
              down vote













              Write $x=n+r$, where $ninmathbbZ$ and $0le rlt1$. Then we want
              $$
              leftlfloor n^2+2nr+r^2rightrfloor=leftlfloor(n+r)^2rightrfloor=lfloor n+rrfloor^2=n^2tag1
              $$
              If $r=0$, then $(1)$ is true. Thus, we have any $xinmathbbZ$ is a solution.



              Now, assume $0lt rlt1$. $(1)$ requires
              $$
              0le2nr+r^2lt1tag2
              $$
              To satisfy the left-hand inequality of $(2)$, we need
              $$
              2n+rge0tag3
              $$
              So we need $nge0$. To satisfy the right-hand inequality of $(2)$, we need
              $$
              0lt rlt-n+sqrtn^2+1tag4
              $$
              which is equivalent to
              $$
              nlt xltsqrtn^2+1tag5
              $$
              Therefore, we get the complete solution set to be
              $$
              xinmathbbZcupbigcup_n=0^inftyleft(n,sqrtn^2+1right)tag6
              $$






              share|cite|improve this answer





















              • I really liked your solution! Thank you very much!
                – user573497
                Jul 27 at 5:54










              • Can eq.6 be simplified to $$xinbigcup_n=0^inftybigg[n,sqrtn^2+1bigg)tag6$$?
                – AccidentalFourierTransform
                Jul 27 at 17:09











              • @AccidentalFourierTransform: that leaves out all the negative integers.
                – robjohn♦
                Jul 27 at 18:11










              • @robjohn Ah, right. Silly me.
                – AccidentalFourierTransform
                Jul 27 at 18:28












              up vote
              8
              down vote










              up vote
              8
              down vote









              Write $x=n+r$, where $ninmathbbZ$ and $0le rlt1$. Then we want
              $$
              leftlfloor n^2+2nr+r^2rightrfloor=leftlfloor(n+r)^2rightrfloor=lfloor n+rrfloor^2=n^2tag1
              $$
              If $r=0$, then $(1)$ is true. Thus, we have any $xinmathbbZ$ is a solution.



              Now, assume $0lt rlt1$. $(1)$ requires
              $$
              0le2nr+r^2lt1tag2
              $$
              To satisfy the left-hand inequality of $(2)$, we need
              $$
              2n+rge0tag3
              $$
              So we need $nge0$. To satisfy the right-hand inequality of $(2)$, we need
              $$
              0lt rlt-n+sqrtn^2+1tag4
              $$
              which is equivalent to
              $$
              nlt xltsqrtn^2+1tag5
              $$
              Therefore, we get the complete solution set to be
              $$
              xinmathbbZcupbigcup_n=0^inftyleft(n,sqrtn^2+1right)tag6
              $$






              share|cite|improve this answer













              Write $x=n+r$, where $ninmathbbZ$ and $0le rlt1$. Then we want
              $$
              leftlfloor n^2+2nr+r^2rightrfloor=leftlfloor(n+r)^2rightrfloor=lfloor n+rrfloor^2=n^2tag1
              $$
              If $r=0$, then $(1)$ is true. Thus, we have any $xinmathbbZ$ is a solution.



              Now, assume $0lt rlt1$. $(1)$ requires
              $$
              0le2nr+r^2lt1tag2
              $$
              To satisfy the left-hand inequality of $(2)$, we need
              $$
              2n+rge0tag3
              $$
              So we need $nge0$. To satisfy the right-hand inequality of $(2)$, we need
              $$
              0lt rlt-n+sqrtn^2+1tag4
              $$
              which is equivalent to
              $$
              nlt xltsqrtn^2+1tag5
              $$
              Therefore, we get the complete solution set to be
              $$
              xinmathbbZcupbigcup_n=0^inftyleft(n,sqrtn^2+1right)tag6
              $$







              share|cite|improve this answer













              share|cite|improve this answer



              share|cite|improve this answer











              answered Jul 27 at 5:53









              robjohn♦

              258k25297612




              258k25297612











              • I really liked your solution! Thank you very much!
                – user573497
                Jul 27 at 5:54










              • Can eq.6 be simplified to $$xinbigcup_n=0^inftybigg[n,sqrtn^2+1bigg)tag6$$?
                – AccidentalFourierTransform
                Jul 27 at 17:09











              • @AccidentalFourierTransform: that leaves out all the negative integers.
                – robjohn♦
                Jul 27 at 18:11










              • @robjohn Ah, right. Silly me.
                – AccidentalFourierTransform
                Jul 27 at 18:28
















              • I really liked your solution! Thank you very much!
                – user573497
                Jul 27 at 5:54










              • Can eq.6 be simplified to $$xinbigcup_n=0^inftybigg[n,sqrtn^2+1bigg)tag6$$?
                – AccidentalFourierTransform
                Jul 27 at 17:09











              • @AccidentalFourierTransform: that leaves out all the negative integers.
                – robjohn♦
                Jul 27 at 18:11










              • @robjohn Ah, right. Silly me.
                – AccidentalFourierTransform
                Jul 27 at 18:28















              I really liked your solution! Thank you very much!
              – user573497
              Jul 27 at 5:54




              I really liked your solution! Thank you very much!
              – user573497
              Jul 27 at 5:54












              Can eq.6 be simplified to $$xinbigcup_n=0^inftybigg[n,sqrtn^2+1bigg)tag6$$?
              – AccidentalFourierTransform
              Jul 27 at 17:09





              Can eq.6 be simplified to $$xinbigcup_n=0^inftybigg[n,sqrtn^2+1bigg)tag6$$?
              – AccidentalFourierTransform
              Jul 27 at 17:09













              @AccidentalFourierTransform: that leaves out all the negative integers.
              – robjohn♦
              Jul 27 at 18:11




              @AccidentalFourierTransform: that leaves out all the negative integers.
              – robjohn♦
              Jul 27 at 18:11












              @robjohn Ah, right. Silly me.
              – AccidentalFourierTransform
              Jul 27 at 18:28




              @robjohn Ah, right. Silly me.
              – AccidentalFourierTransform
              Jul 27 at 18:28










              up vote
              1
              down vote













              I'm not sure there is going to be a "clean" solution of this, you will have to consider various cases.



              • If $r=0$ the inequalities are clearly true.

              • If $r>0$ and $n<0$ then $2nle-2$ so $2n+r<0$ so $2nr+r^2<0$ and there is no solution.

              • The remaining case is $r>0$ and $nge0$. Then $0le2nr+r^2$ is certainly true, so you have to solve $2nr+r^2<1$ to find $r$ in terms of $n$.

              See if you can finish it from here.






              share|cite|improve this answer

























                up vote
                1
                down vote













                I'm not sure there is going to be a "clean" solution of this, you will have to consider various cases.



                • If $r=0$ the inequalities are clearly true.

                • If $r>0$ and $n<0$ then $2nle-2$ so $2n+r<0$ so $2nr+r^2<0$ and there is no solution.

                • The remaining case is $r>0$ and $nge0$. Then $0le2nr+r^2$ is certainly true, so you have to solve $2nr+r^2<1$ to find $r$ in terms of $n$.

                See if you can finish it from here.






                share|cite|improve this answer























                  up vote
                  1
                  down vote










                  up vote
                  1
                  down vote









                  I'm not sure there is going to be a "clean" solution of this, you will have to consider various cases.



                  • If $r=0$ the inequalities are clearly true.

                  • If $r>0$ and $n<0$ then $2nle-2$ so $2n+r<0$ so $2nr+r^2<0$ and there is no solution.

                  • The remaining case is $r>0$ and $nge0$. Then $0le2nr+r^2$ is certainly true, so you have to solve $2nr+r^2<1$ to find $r$ in terms of $n$.

                  See if you can finish it from here.






                  share|cite|improve this answer













                  I'm not sure there is going to be a "clean" solution of this, you will have to consider various cases.



                  • If $r=0$ the inequalities are clearly true.

                  • If $r>0$ and $n<0$ then $2nle-2$ so $2n+r<0$ so $2nr+r^2<0$ and there is no solution.

                  • The remaining case is $r>0$ and $nge0$. Then $0le2nr+r^2$ is certainly true, so you have to solve $2nr+r^2<1$ to find $r$ in terms of $n$.

                  See if you can finish it from here.







                  share|cite|improve this answer













                  share|cite|improve this answer



                  share|cite|improve this answer











                  answered Jul 27 at 5:03









                  David

                  65.8k662124




                  65.8k662124




















                      up vote
                      1
                      down vote













                      I think that you have done almost everything. In your notation you have the following inequalities: $r>=0$, $r<1$, $r^2+2nr-1<0$. The last one gives $r<sqrtn^2+1-n$. This gives possible values of $r$ for given $n>=0$. For negative $n$ your computation is not correct.






                      share|cite|improve this answer

























                        up vote
                        1
                        down vote













                        I think that you have done almost everything. In your notation you have the following inequalities: $r>=0$, $r<1$, $r^2+2nr-1<0$. The last one gives $r<sqrtn^2+1-n$. This gives possible values of $r$ for given $n>=0$. For negative $n$ your computation is not correct.






                        share|cite|improve this answer























                          up vote
                          1
                          down vote










                          up vote
                          1
                          down vote









                          I think that you have done almost everything. In your notation you have the following inequalities: $r>=0$, $r<1$, $r^2+2nr-1<0$. The last one gives $r<sqrtn^2+1-n$. This gives possible values of $r$ for given $n>=0$. For negative $n$ your computation is not correct.






                          share|cite|improve this answer













                          I think that you have done almost everything. In your notation you have the following inequalities: $r>=0$, $r<1$, $r^2+2nr-1<0$. The last one gives $r<sqrtn^2+1-n$. This gives possible values of $r$ for given $n>=0$. For negative $n$ your computation is not correct.







                          share|cite|improve this answer













                          share|cite|improve this answer



                          share|cite|improve this answer











                          answered Jul 27 at 5:08









                          V. Asnin

                          711




                          711






















                               

                              draft saved


                              draft discarded


























                               


                              draft saved


                              draft discarded














                              StackExchange.ready(
                              function ()
                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f2864058%2ffinding-the-values-of-x-such-that-x2-x2-cdot-denotes-the-floor-f%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?