A simple calculator

A simple calculator only has 2 functions.

It always starts at 0 and then does one of the following

  • add a N a \in \mathbb{N} to the number
  • multiply the number by b N b \in \mathbb{N}

It can do multiple operations in a row, the result of the last operation is always the input for the next one.

This calculator is then named ( a , b ) (a,b) .


Consider the calculator ( 20 , 19 ) (20,19) .

What portion of positive integers can be calculated using this calculator?


More formally:

Let S n ( a , b ) |S_n(a,b)| count the number of positive integers less than or equal to n n that can be calculated using this calculator. Then, find

lim n S n ( a , b ) n \displaystyle \lim_{n \to \infty} \frac {|S_n(a,b)|}{n}


The answer is 0.05.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

Henry U
Dec 26, 2018

Since the calculator starts with 0, the only thing to do is to add 20. This can be done as often as necessary to generate every number of the form 20 k , k N 20k, k \in \mathbb{N} .

If some step was to multiply by 19, this wouldn't give any new numbers since the resulting number could also have been reached by adding 20 a few times.

No matter which steps are performed, the number will always be divisible by 20, and every multiple of 20 can be reached (by just adding 20 as often as necessary). So, 1 20 = 0.05 \frac 1{20} = \boxed{0.05} of all positive integers can be reached.

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...