Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re^2: Can It Be Written In Base X With Only 1s And 0s

by Laurent_R (Canon)
on Jun 16, 2015 at 06:36 UTC ( [id://1130558]=note: print w/replies, xml ) Need Help??


in reply to Re: Can It Be Written In Base X With Only 1s And 0s
in thread Can It Be Written In Base X With Only 1s And 0s

82000 is a sum of powers of all the inputs
That's sort of by definition: if the number is expressed with only 1 and 0 in a given base, then it will be sum of simple powers of that base.
  • Comment on Re^2: Can It Be Written In Base X With Only 1s And 0s

Replies are listed 'Best First'.
Re^3: Can It Be Written In Base X With Only 1s And 0s
by BrowserUk (Patriarch) on Jun 16, 2015 at 07:14 UTC

    Hm. A phraseology problem I think.

    Below are all the numbers less than 3^11, that when encoded base-3 use only 0 1:

    All of them can be defined as the sums of multiples of powers of 3. But only the first number in each block is a power of 3.

    And 82000 is a sum of a selection of those first numbers in each block. And that is so for 4 & 5 also.

    And, if it holds true for the higher numbers in the sequence (and they are going to be very large) then not having to consider all the other numbers in each of those blocks is a significant saving.

    So worth pointing out don't you think? Even if I need to clarify the meaning or use better phraseology.

    How about a sum of single powers? Or discrete powers?


    With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority". I'm with torvalds on this
    In the absence of evidence, opinion is indistinguishable from prejudice. Agile (and TDD) debunked
      Yes, it is probably a phraseology problem or a misunderstanding, but I still don't agree with this sentence:
      All of them can be defined as the sums of multiples of powers of 3. But only the first number in each block is a power of 3.
      To me, these numbers are all sums of single powers of 3. For example, taking the beginning of your list:
      1 -- 3**0 3 4 -- 3**1, 3**0 + 3**1 9 10 12 13 -- 3**2, 3**0 + 3**2, 3**1 + 3**2, 3**0 + 3**1 + 3**2 etc.
      So they are all sums of pure (or single) powers of 3, not sums of multiples of powers of 3 (which would imply numbers expressed with other digits than 0 and 1 in base 3). And so is 82000.

      And I agree with you that you don't have to consider these other numbers, only those that are pure powers of 3 are of interest for the search; so, as you said, only the first one of each block if you want to figure out whether 82000 or any other number qualifies the test.

        82000 can be broken down to 3^0 + 3^3 + 3^4 + 3^5 + 3^6 + 3^7 + 3^9 + 3^10. Ie. The sum of 8 discrete or single powers of 3.

        82001 would require 2*3^0, thus a multiple of one of the powers of 3.

        I don't much care how it is worded; so long as you understand my meaning; which you evidently do.


        With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
        Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
        "Science is about questioning the status quo. Questioning authority". I'm with torvalds on this
        In the absence of evidence, opinion is indistinguishable from prejudice. Agile (and TDD) debunked

      All of them can be defined as the sums of multiples of powers of 3.

      All integers are sums of multiples of powers of 3. The ones of interest are sums of powers of 3. You had it right the first time

        Jeez!

        These are all powers of 3 less than 3^11:

        1 3 9 27 81 243 729 2187 6561 19683 59049

        These are all sums of multiple powers of three less than 3^11 that also consist of 0s & 1s when encoded in base-3:

        It is a quicker to permute the combinations of the 11 powers of the to look for solutions that are sum of distinct powers of 3,

        than it is to permute the combinations 1847 compliant numbers that are (a subset of the) sums of multiple powers of 3.

        And the numbers & differences get much larger for 4, 5, 6 ...

        So, please refrain from telling me what I got right and wrong, when you appear to not understand the subject.


        With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
        Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
        "Science is about questioning the status quo. Questioning authority". I'm with torvalds on this
        In the absence of evidence, opinion is indistinguishable from prejudice. Agile (and TDD) debunked

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1130558]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (4)
As of 2024-04-24 06:43 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found