Converting Decimal with 3 decimal places to Octal












0














I know how to convert from $769_{10}$ to base 8 that is $1401_8$ through dividing and remainder method but what is the method for $769.513_{10}$ to convert to octal?I know that it is to separate the integer part and the decimal place part that is $1401_8$ $bullet$ (answer from converting $0.513_{10}$ to octal).I just can't seem to work out the $0.513_{10}$ part to octal.










share|cite|improve this question





























    0














    I know how to convert from $769_{10}$ to base 8 that is $1401_8$ through dividing and remainder method but what is the method for $769.513_{10}$ to convert to octal?I know that it is to separate the integer part and the decimal place part that is $1401_8$ $bullet$ (answer from converting $0.513_{10}$ to octal).I just can't seem to work out the $0.513_{10}$ part to octal.










    share|cite|improve this question



























      0












      0








      0







      I know how to convert from $769_{10}$ to base 8 that is $1401_8$ through dividing and remainder method but what is the method for $769.513_{10}$ to convert to octal?I know that it is to separate the integer part and the decimal place part that is $1401_8$ $bullet$ (answer from converting $0.513_{10}$ to octal).I just can't seem to work out the $0.513_{10}$ part to octal.










      share|cite|improve this question















      I know how to convert from $769_{10}$ to base 8 that is $1401_8$ through dividing and remainder method but what is the method for $769.513_{10}$ to convert to octal?I know that it is to separate the integer part and the decimal place part that is $1401_8$ $bullet$ (answer from converting $0.513_{10}$ to octal).I just can't seem to work out the $0.513_{10}$ part to octal.







      elementary-number-theory decimal-expansion






      share|cite|improve this question















      share|cite|improve this question













      share|cite|improve this question




      share|cite|improve this question








      edited Nov 28 '18 at 11:36









      José Carlos Santos

      152k22123224




      152k22123224










      asked Nov 28 '18 at 11:28









      Jshawn

      11




      11






















          3 Answers
          3






          active

          oldest

          votes


















          0














          First of all, note that $lfloor8times.513rfloor=4$; that will your first digit.



          On the other hand, $.513-4times8^{-1}=.513-.5=.013$. And $lfloor8^2times.013rfloor=0$: that will be your second digit.



          Now, $lfloor8^3times.013rfloor=6$. So, your third digit will be $6$. And so on…



          Actually, this process will never stop, since $.513=dfrac{513}{1,000}$ and this fraction is irreducible. In particular, it is not of the type $dfrac a{8^b}$, with $ainmathbb Z$ and $binmathbb{Z}_+$.






          share|cite|improve this answer





























            0














            Hint:



            $$.513=dfrac{513}{1000}=dfrac{a_1}8+dfrac{a_2}{8^2}+cdots$$ where $0le a_ile7$



            $$implies513=125a_1+cdots$$



            $implies a_1=leftlfloordfrac{513}{125}rightrfloor=?$



            $513-500=dfrac{1000a_2}{8^2}+dfrac{1000a_3}{8^3}+cdots$



            $implies a_1=leftlfloordfrac{(513-500)8^2}{1000}rightrfloor=?$



            Can you take it from here?






            share|cite|improve this answer





























              0














              So the question is to write
              $$
              x=0.513=0.513_{(10)}=frac{513}{1000}
              $$

              to octal. (If no base is written, numbers are considered in the usual decimal system. So $0.513$ is decimal, same for the numerator $513$, and denominator $1000$, decimal numbers.)



              It is known that the result is a periodic number, there may be a part after the comma place which is "atypical", but then we repeat the period. First,
              $$
              frac 1{1000}=frac 18cdotfrac 1{125} .
              $$

              We have $frac {513}{125}=4+frac{13}{125}$. It will be enough to get the octal representation of $13/125$.



              We now search for a number of the shape $8^k-1$ which is divisible by $125$.
              We know (Euler, Euler indicator function) that $k=phi(125)=100$ does it, but it is a good idea to get the minimal $k$. Well, as it happens here, it is $100$. So we expect a period of this length! It is natural that i will use a computer to get it. Now
              $$
              begin{aligned}
              frac 1{125}
              &=
              frac{(8^{100}-1)/125}{8^{100}-1}
              =
              Ncdotfrac{1}{8^{100}-1}text{ with }N=(8^{100}-1)/125inBbb N ,
              \
              &=
              Ncdotfrac{1}{8^{100}}cdotfrac{1}{1-left(frac 18right)^{100}}
              \
              &=
              Ncdot qcdotfrac{1}{1-q}text{ with } q=left(frac 18right)^{100} ,
              \
              &=
              N(q+q^2+q^3+q^4+dots) .
              end{aligned}
              $$

              The last number is simple, as follows: $q$ is the octal number $0,000dots1$, then $q^2$ is $0,000dots0 000dots1 $, and so on, the sum $q+q^2+dots$ is the periodic number
              $0.(000dots1)$, where the parenthesis means "period". An then we multiply by $N$, thus $N$ "becomes the period", well, adjusted to $100$ digits as a "p hone number". In our case, we need instead $13/125$, so we use $13cdot N$. This is using sage



              sage: 13*(8^100-1)/125
              211851741538786552971918351594575328749352712941257370066158606732855655175387017443073327


              in a decimal writing. Octal representation of it, again using sage:



              sage: ''.join( [ str(digit) for digit in ZZ(13*(8^100-1)/125).digits(base=8)[::-1] ] )
              '651767635544264162540203044672274324773716662132071260101422335136152375747331055034530040611156457'


              So the final answer is
              $$
              begin{aligned}
              0.513
              &
              =frac 18cdotfrac {513}{125}
              =frac 18cdotleft(4+frac {13}{125}right)
              \
              &=
              frac 18cdot
              (4_{(8)}+
              0.(065176763554426416254020304467227432
              \&qquadqquad
              477371666213207126010142233513615237574
              \&qquadqquadqquad
              7331055034530040611156457)_{(8)}
              )
              \
              &=
              frac 18cdot
              4.(065176763554426416254020304467227432
              \&qquadqquad
              477371666213207126010142233513615237574
              \&qquadqquadqquad
              7331055034530040611156457)_{(8)}
              \
              &=
              0.4(0651767635544264162540203044672274
              \&qquadqquad
              32477371666213207126010142233513615237
              \&qquadqquadqquad
              5747331055034530040611156457)_{(8)}
              end{aligned}
              $$

              A small check for the first octal places after the comma:



              sage: a - 4/8 - 6/8^3 - 5/8^4 - 1/8^5 - 7/8^6 - 6/8^7
              61/131072000
              sage: _ < 1/8^7
              True





              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',
                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%2f3017038%2fconverting-decimal-with-3-decimal-places-to-octal%23new-answer', 'question_page');
                }
                );

                Post as a guest















                Required, but never shown

























                3 Answers
                3






                active

                oldest

                votes








                3 Answers
                3






                active

                oldest

                votes









                active

                oldest

                votes






                active

                oldest

                votes









                0














                First of all, note that $lfloor8times.513rfloor=4$; that will your first digit.



                On the other hand, $.513-4times8^{-1}=.513-.5=.013$. And $lfloor8^2times.013rfloor=0$: that will be your second digit.



                Now, $lfloor8^3times.013rfloor=6$. So, your third digit will be $6$. And so on…



                Actually, this process will never stop, since $.513=dfrac{513}{1,000}$ and this fraction is irreducible. In particular, it is not of the type $dfrac a{8^b}$, with $ainmathbb Z$ and $binmathbb{Z}_+$.






                share|cite|improve this answer


























                  0














                  First of all, note that $lfloor8times.513rfloor=4$; that will your first digit.



                  On the other hand, $.513-4times8^{-1}=.513-.5=.013$. And $lfloor8^2times.013rfloor=0$: that will be your second digit.



                  Now, $lfloor8^3times.013rfloor=6$. So, your third digit will be $6$. And so on…



                  Actually, this process will never stop, since $.513=dfrac{513}{1,000}$ and this fraction is irreducible. In particular, it is not of the type $dfrac a{8^b}$, with $ainmathbb Z$ and $binmathbb{Z}_+$.






                  share|cite|improve this answer
























                    0












                    0








                    0






                    First of all, note that $lfloor8times.513rfloor=4$; that will your first digit.



                    On the other hand, $.513-4times8^{-1}=.513-.5=.013$. And $lfloor8^2times.013rfloor=0$: that will be your second digit.



                    Now, $lfloor8^3times.013rfloor=6$. So, your third digit will be $6$. And so on…



                    Actually, this process will never stop, since $.513=dfrac{513}{1,000}$ and this fraction is irreducible. In particular, it is not of the type $dfrac a{8^b}$, with $ainmathbb Z$ and $binmathbb{Z}_+$.






                    share|cite|improve this answer












                    First of all, note that $lfloor8times.513rfloor=4$; that will your first digit.



                    On the other hand, $.513-4times8^{-1}=.513-.5=.013$. And $lfloor8^2times.013rfloor=0$: that will be your second digit.



                    Now, $lfloor8^3times.013rfloor=6$. So, your third digit will be $6$. And so on…



                    Actually, this process will never stop, since $.513=dfrac{513}{1,000}$ and this fraction is irreducible. In particular, it is not of the type $dfrac a{8^b}$, with $ainmathbb Z$ and $binmathbb{Z}_+$.







                    share|cite|improve this answer












                    share|cite|improve this answer



                    share|cite|improve this answer










                    answered Nov 28 '18 at 11:35









                    José Carlos Santos

                    152k22123224




                    152k22123224























                        0














                        Hint:



                        $$.513=dfrac{513}{1000}=dfrac{a_1}8+dfrac{a_2}{8^2}+cdots$$ where $0le a_ile7$



                        $$implies513=125a_1+cdots$$



                        $implies a_1=leftlfloordfrac{513}{125}rightrfloor=?$



                        $513-500=dfrac{1000a_2}{8^2}+dfrac{1000a_3}{8^3}+cdots$



                        $implies a_1=leftlfloordfrac{(513-500)8^2}{1000}rightrfloor=?$



                        Can you take it from here?






                        share|cite|improve this answer


























                          0














                          Hint:



                          $$.513=dfrac{513}{1000}=dfrac{a_1}8+dfrac{a_2}{8^2}+cdots$$ where $0le a_ile7$



                          $$implies513=125a_1+cdots$$



                          $implies a_1=leftlfloordfrac{513}{125}rightrfloor=?$



                          $513-500=dfrac{1000a_2}{8^2}+dfrac{1000a_3}{8^3}+cdots$



                          $implies a_1=leftlfloordfrac{(513-500)8^2}{1000}rightrfloor=?$



                          Can you take it from here?






                          share|cite|improve this answer
























                            0












                            0








                            0






                            Hint:



                            $$.513=dfrac{513}{1000}=dfrac{a_1}8+dfrac{a_2}{8^2}+cdots$$ where $0le a_ile7$



                            $$implies513=125a_1+cdots$$



                            $implies a_1=leftlfloordfrac{513}{125}rightrfloor=?$



                            $513-500=dfrac{1000a_2}{8^2}+dfrac{1000a_3}{8^3}+cdots$



                            $implies a_1=leftlfloordfrac{(513-500)8^2}{1000}rightrfloor=?$



                            Can you take it from here?






                            share|cite|improve this answer












                            Hint:



                            $$.513=dfrac{513}{1000}=dfrac{a_1}8+dfrac{a_2}{8^2}+cdots$$ where $0le a_ile7$



                            $$implies513=125a_1+cdots$$



                            $implies a_1=leftlfloordfrac{513}{125}rightrfloor=?$



                            $513-500=dfrac{1000a_2}{8^2}+dfrac{1000a_3}{8^3}+cdots$



                            $implies a_1=leftlfloordfrac{(513-500)8^2}{1000}rightrfloor=?$



                            Can you take it from here?







                            share|cite|improve this answer












                            share|cite|improve this answer



                            share|cite|improve this answer










                            answered Nov 28 '18 at 11:37









                            lab bhattacharjee

                            223k15156274




                            223k15156274























                                0














                                So the question is to write
                                $$
                                x=0.513=0.513_{(10)}=frac{513}{1000}
                                $$

                                to octal. (If no base is written, numbers are considered in the usual decimal system. So $0.513$ is decimal, same for the numerator $513$, and denominator $1000$, decimal numbers.)



                                It is known that the result is a periodic number, there may be a part after the comma place which is "atypical", but then we repeat the period. First,
                                $$
                                frac 1{1000}=frac 18cdotfrac 1{125} .
                                $$

                                We have $frac {513}{125}=4+frac{13}{125}$. It will be enough to get the octal representation of $13/125$.



                                We now search for a number of the shape $8^k-1$ which is divisible by $125$.
                                We know (Euler, Euler indicator function) that $k=phi(125)=100$ does it, but it is a good idea to get the minimal $k$. Well, as it happens here, it is $100$. So we expect a period of this length! It is natural that i will use a computer to get it. Now
                                $$
                                begin{aligned}
                                frac 1{125}
                                &=
                                frac{(8^{100}-1)/125}{8^{100}-1}
                                =
                                Ncdotfrac{1}{8^{100}-1}text{ with }N=(8^{100}-1)/125inBbb N ,
                                \
                                &=
                                Ncdotfrac{1}{8^{100}}cdotfrac{1}{1-left(frac 18right)^{100}}
                                \
                                &=
                                Ncdot qcdotfrac{1}{1-q}text{ with } q=left(frac 18right)^{100} ,
                                \
                                &=
                                N(q+q^2+q^3+q^4+dots) .
                                end{aligned}
                                $$

                                The last number is simple, as follows: $q$ is the octal number $0,000dots1$, then $q^2$ is $0,000dots0 000dots1 $, and so on, the sum $q+q^2+dots$ is the periodic number
                                $0.(000dots1)$, where the parenthesis means "period". An then we multiply by $N$, thus $N$ "becomes the period", well, adjusted to $100$ digits as a "p hone number". In our case, we need instead $13/125$, so we use $13cdot N$. This is using sage



                                sage: 13*(8^100-1)/125
                                211851741538786552971918351594575328749352712941257370066158606732855655175387017443073327


                                in a decimal writing. Octal representation of it, again using sage:



                                sage: ''.join( [ str(digit) for digit in ZZ(13*(8^100-1)/125).digits(base=8)[::-1] ] )
                                '651767635544264162540203044672274324773716662132071260101422335136152375747331055034530040611156457'


                                So the final answer is
                                $$
                                begin{aligned}
                                0.513
                                &
                                =frac 18cdotfrac {513}{125}
                                =frac 18cdotleft(4+frac {13}{125}right)
                                \
                                &=
                                frac 18cdot
                                (4_{(8)}+
                                0.(065176763554426416254020304467227432
                                \&qquadqquad
                                477371666213207126010142233513615237574
                                \&qquadqquadqquad
                                7331055034530040611156457)_{(8)}
                                )
                                \
                                &=
                                frac 18cdot
                                4.(065176763554426416254020304467227432
                                \&qquadqquad
                                477371666213207126010142233513615237574
                                \&qquadqquadqquad
                                7331055034530040611156457)_{(8)}
                                \
                                &=
                                0.4(0651767635544264162540203044672274
                                \&qquadqquad
                                32477371666213207126010142233513615237
                                \&qquadqquadqquad
                                5747331055034530040611156457)_{(8)}
                                end{aligned}
                                $$

                                A small check for the first octal places after the comma:



                                sage: a - 4/8 - 6/8^3 - 5/8^4 - 1/8^5 - 7/8^6 - 6/8^7
                                61/131072000
                                sage: _ < 1/8^7
                                True





                                share|cite|improve this answer


























                                  0














                                  So the question is to write
                                  $$
                                  x=0.513=0.513_{(10)}=frac{513}{1000}
                                  $$

                                  to octal. (If no base is written, numbers are considered in the usual decimal system. So $0.513$ is decimal, same for the numerator $513$, and denominator $1000$, decimal numbers.)



                                  It is known that the result is a periodic number, there may be a part after the comma place which is "atypical", but then we repeat the period. First,
                                  $$
                                  frac 1{1000}=frac 18cdotfrac 1{125} .
                                  $$

                                  We have $frac {513}{125}=4+frac{13}{125}$. It will be enough to get the octal representation of $13/125$.



                                  We now search for a number of the shape $8^k-1$ which is divisible by $125$.
                                  We know (Euler, Euler indicator function) that $k=phi(125)=100$ does it, but it is a good idea to get the minimal $k$. Well, as it happens here, it is $100$. So we expect a period of this length! It is natural that i will use a computer to get it. Now
                                  $$
                                  begin{aligned}
                                  frac 1{125}
                                  &=
                                  frac{(8^{100}-1)/125}{8^{100}-1}
                                  =
                                  Ncdotfrac{1}{8^{100}-1}text{ with }N=(8^{100}-1)/125inBbb N ,
                                  \
                                  &=
                                  Ncdotfrac{1}{8^{100}}cdotfrac{1}{1-left(frac 18right)^{100}}
                                  \
                                  &=
                                  Ncdot qcdotfrac{1}{1-q}text{ with } q=left(frac 18right)^{100} ,
                                  \
                                  &=
                                  N(q+q^2+q^3+q^4+dots) .
                                  end{aligned}
                                  $$

                                  The last number is simple, as follows: $q$ is the octal number $0,000dots1$, then $q^2$ is $0,000dots0 000dots1 $, and so on, the sum $q+q^2+dots$ is the periodic number
                                  $0.(000dots1)$, where the parenthesis means "period". An then we multiply by $N$, thus $N$ "becomes the period", well, adjusted to $100$ digits as a "p hone number". In our case, we need instead $13/125$, so we use $13cdot N$. This is using sage



                                  sage: 13*(8^100-1)/125
                                  211851741538786552971918351594575328749352712941257370066158606732855655175387017443073327


                                  in a decimal writing. Octal representation of it, again using sage:



                                  sage: ''.join( [ str(digit) for digit in ZZ(13*(8^100-1)/125).digits(base=8)[::-1] ] )
                                  '651767635544264162540203044672274324773716662132071260101422335136152375747331055034530040611156457'


                                  So the final answer is
                                  $$
                                  begin{aligned}
                                  0.513
                                  &
                                  =frac 18cdotfrac {513}{125}
                                  =frac 18cdotleft(4+frac {13}{125}right)
                                  \
                                  &=
                                  frac 18cdot
                                  (4_{(8)}+
                                  0.(065176763554426416254020304467227432
                                  \&qquadqquad
                                  477371666213207126010142233513615237574
                                  \&qquadqquadqquad
                                  7331055034530040611156457)_{(8)}
                                  )
                                  \
                                  &=
                                  frac 18cdot
                                  4.(065176763554426416254020304467227432
                                  \&qquadqquad
                                  477371666213207126010142233513615237574
                                  \&qquadqquadqquad
                                  7331055034530040611156457)_{(8)}
                                  \
                                  &=
                                  0.4(0651767635544264162540203044672274
                                  \&qquadqquad
                                  32477371666213207126010142233513615237
                                  \&qquadqquadqquad
                                  5747331055034530040611156457)_{(8)}
                                  end{aligned}
                                  $$

                                  A small check for the first octal places after the comma:



                                  sage: a - 4/8 - 6/8^3 - 5/8^4 - 1/8^5 - 7/8^6 - 6/8^7
                                  61/131072000
                                  sage: _ < 1/8^7
                                  True





                                  share|cite|improve this answer
























                                    0












                                    0








                                    0






                                    So the question is to write
                                    $$
                                    x=0.513=0.513_{(10)}=frac{513}{1000}
                                    $$

                                    to octal. (If no base is written, numbers are considered in the usual decimal system. So $0.513$ is decimal, same for the numerator $513$, and denominator $1000$, decimal numbers.)



                                    It is known that the result is a periodic number, there may be a part after the comma place which is "atypical", but then we repeat the period. First,
                                    $$
                                    frac 1{1000}=frac 18cdotfrac 1{125} .
                                    $$

                                    We have $frac {513}{125}=4+frac{13}{125}$. It will be enough to get the octal representation of $13/125$.



                                    We now search for a number of the shape $8^k-1$ which is divisible by $125$.
                                    We know (Euler, Euler indicator function) that $k=phi(125)=100$ does it, but it is a good idea to get the minimal $k$. Well, as it happens here, it is $100$. So we expect a period of this length! It is natural that i will use a computer to get it. Now
                                    $$
                                    begin{aligned}
                                    frac 1{125}
                                    &=
                                    frac{(8^{100}-1)/125}{8^{100}-1}
                                    =
                                    Ncdotfrac{1}{8^{100}-1}text{ with }N=(8^{100}-1)/125inBbb N ,
                                    \
                                    &=
                                    Ncdotfrac{1}{8^{100}}cdotfrac{1}{1-left(frac 18right)^{100}}
                                    \
                                    &=
                                    Ncdot qcdotfrac{1}{1-q}text{ with } q=left(frac 18right)^{100} ,
                                    \
                                    &=
                                    N(q+q^2+q^3+q^4+dots) .
                                    end{aligned}
                                    $$

                                    The last number is simple, as follows: $q$ is the octal number $0,000dots1$, then $q^2$ is $0,000dots0 000dots1 $, and so on, the sum $q+q^2+dots$ is the periodic number
                                    $0.(000dots1)$, where the parenthesis means "period". An then we multiply by $N$, thus $N$ "becomes the period", well, adjusted to $100$ digits as a "p hone number". In our case, we need instead $13/125$, so we use $13cdot N$. This is using sage



                                    sage: 13*(8^100-1)/125
                                    211851741538786552971918351594575328749352712941257370066158606732855655175387017443073327


                                    in a decimal writing. Octal representation of it, again using sage:



                                    sage: ''.join( [ str(digit) for digit in ZZ(13*(8^100-1)/125).digits(base=8)[::-1] ] )
                                    '651767635544264162540203044672274324773716662132071260101422335136152375747331055034530040611156457'


                                    So the final answer is
                                    $$
                                    begin{aligned}
                                    0.513
                                    &
                                    =frac 18cdotfrac {513}{125}
                                    =frac 18cdotleft(4+frac {13}{125}right)
                                    \
                                    &=
                                    frac 18cdot
                                    (4_{(8)}+
                                    0.(065176763554426416254020304467227432
                                    \&qquadqquad
                                    477371666213207126010142233513615237574
                                    \&qquadqquadqquad
                                    7331055034530040611156457)_{(8)}
                                    )
                                    \
                                    &=
                                    frac 18cdot
                                    4.(065176763554426416254020304467227432
                                    \&qquadqquad
                                    477371666213207126010142233513615237574
                                    \&qquadqquadqquad
                                    7331055034530040611156457)_{(8)}
                                    \
                                    &=
                                    0.4(0651767635544264162540203044672274
                                    \&qquadqquad
                                    32477371666213207126010142233513615237
                                    \&qquadqquadqquad
                                    5747331055034530040611156457)_{(8)}
                                    end{aligned}
                                    $$

                                    A small check for the first octal places after the comma:



                                    sage: a - 4/8 - 6/8^3 - 5/8^4 - 1/8^5 - 7/8^6 - 6/8^7
                                    61/131072000
                                    sage: _ < 1/8^7
                                    True





                                    share|cite|improve this answer












                                    So the question is to write
                                    $$
                                    x=0.513=0.513_{(10)}=frac{513}{1000}
                                    $$

                                    to octal. (If no base is written, numbers are considered in the usual decimal system. So $0.513$ is decimal, same for the numerator $513$, and denominator $1000$, decimal numbers.)



                                    It is known that the result is a periodic number, there may be a part after the comma place which is "atypical", but then we repeat the period. First,
                                    $$
                                    frac 1{1000}=frac 18cdotfrac 1{125} .
                                    $$

                                    We have $frac {513}{125}=4+frac{13}{125}$. It will be enough to get the octal representation of $13/125$.



                                    We now search for a number of the shape $8^k-1$ which is divisible by $125$.
                                    We know (Euler, Euler indicator function) that $k=phi(125)=100$ does it, but it is a good idea to get the minimal $k$. Well, as it happens here, it is $100$. So we expect a period of this length! It is natural that i will use a computer to get it. Now
                                    $$
                                    begin{aligned}
                                    frac 1{125}
                                    &=
                                    frac{(8^{100}-1)/125}{8^{100}-1}
                                    =
                                    Ncdotfrac{1}{8^{100}-1}text{ with }N=(8^{100}-1)/125inBbb N ,
                                    \
                                    &=
                                    Ncdotfrac{1}{8^{100}}cdotfrac{1}{1-left(frac 18right)^{100}}
                                    \
                                    &=
                                    Ncdot qcdotfrac{1}{1-q}text{ with } q=left(frac 18right)^{100} ,
                                    \
                                    &=
                                    N(q+q^2+q^3+q^4+dots) .
                                    end{aligned}
                                    $$

                                    The last number is simple, as follows: $q$ is the octal number $0,000dots1$, then $q^2$ is $0,000dots0 000dots1 $, and so on, the sum $q+q^2+dots$ is the periodic number
                                    $0.(000dots1)$, where the parenthesis means "period". An then we multiply by $N$, thus $N$ "becomes the period", well, adjusted to $100$ digits as a "p hone number". In our case, we need instead $13/125$, so we use $13cdot N$. This is using sage



                                    sage: 13*(8^100-1)/125
                                    211851741538786552971918351594575328749352712941257370066158606732855655175387017443073327


                                    in a decimal writing. Octal representation of it, again using sage:



                                    sage: ''.join( [ str(digit) for digit in ZZ(13*(8^100-1)/125).digits(base=8)[::-1] ] )
                                    '651767635544264162540203044672274324773716662132071260101422335136152375747331055034530040611156457'


                                    So the final answer is
                                    $$
                                    begin{aligned}
                                    0.513
                                    &
                                    =frac 18cdotfrac {513}{125}
                                    =frac 18cdotleft(4+frac {13}{125}right)
                                    \
                                    &=
                                    frac 18cdot
                                    (4_{(8)}+
                                    0.(065176763554426416254020304467227432
                                    \&qquadqquad
                                    477371666213207126010142233513615237574
                                    \&qquadqquadqquad
                                    7331055034530040611156457)_{(8)}
                                    )
                                    \
                                    &=
                                    frac 18cdot
                                    4.(065176763554426416254020304467227432
                                    \&qquadqquad
                                    477371666213207126010142233513615237574
                                    \&qquadqquadqquad
                                    7331055034530040611156457)_{(8)}
                                    \
                                    &=
                                    0.4(0651767635544264162540203044672274
                                    \&qquadqquad
                                    32477371666213207126010142233513615237
                                    \&qquadqquadqquad
                                    5747331055034530040611156457)_{(8)}
                                    end{aligned}
                                    $$

                                    A small check for the first octal places after the comma:



                                    sage: a - 4/8 - 6/8^3 - 5/8^4 - 1/8^5 - 7/8^6 - 6/8^7
                                    61/131072000
                                    sage: _ < 1/8^7
                                    True






                                    share|cite|improve this answer












                                    share|cite|improve this answer



                                    share|cite|improve this answer










                                    answered Nov 28 '18 at 13:15









                                    dan_fulea

                                    6,2151312




                                    6,2151312






























                                        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.





                                        Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


                                        Please pay close attention to the following guidance:


                                        • 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.


                                        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%2f3017038%2fconverting-decimal-with-3-decimal-places-to-octal%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

                                        Ellipse (mathématiques)

                                        Quarter-circle Tiles

                                        Mont Emei