17
$\begingroup$

Consider the following sequence - $$ 1,2,2,4,4,4,4,8,8,8,8,8,8,8,8, ... $$

In this sequence, what will be the $ 1025^{th}\, term $

So, when we write down the sequence and then write the value of $ n $ (Here, $n$ stands for the number of the below term) above it We can observe the following -


$1 - 1$

$2 - 2 $

$3 - 2$

$4 - 4$

$5 - 4$

. . .

$8 - 8$

$9 - 8$

. . .


We can notice that $ 4^{th}$ term is 4 and similarly, the $ 8^{th}$ term is 8. So the $ 1025^{th}$ term must be 1024 as $ 1024^{th} $ term starts with 1024.

So the value of $ 1025^{th}$ term is $ 2^{10} $ .

Is there any other method to solve this question?

$\endgroup$
1
  • 21
    $\begingroup$ This method is very efficient. Why would you want another ? $\endgroup$
    – user65203
    Commented Jul 21, 2019 at 21:08

7 Answers 7

53
$\begingroup$

In binary, the term indexes

$$1,10,11,100,101,110,111,1000,1001,1010,1011,1100,1101,1110,1111,\cdots$$

become

$$1,10,10,100,100,100,100,1000,1000,1000,1000,1000,1000,1000,1000,\cdots$$

So for any index, clear all bits but the most significant.

$$1025_{10}=‭10000000001_b\to‭10000000000_b=1024_{10}.$$

$\endgroup$
36
$\begingroup$

A higher brow way of writing the same thing is to say the $n^{th}$ term is $2^{\lfloor \log_2 n\rfloor}$, then to evaluate that at $n=1025$. The base $2$ log of $1025$ is slightly greater than $10$, so the term is $2^{10}=1024$.

$\endgroup$
7
$\begingroup$

The number $n$ first appears in the sequence at position $n$ until position $2n-1$. So, the number $1024$ appears in the sequence at position $1024$ until $2047$. Therefore the number will be $1024$.

$\endgroup$
1
  • 2
    $\begingroup$ You missed an ^ in your $2n-1$. It should be $2^n-1$ $\endgroup$ Commented Aug 15, 2019 at 17:54
3
$\begingroup$

The first term is $2^0=1$; the next $2^1=2$ terms are equal to $2^1=2$; the next $2^2=4$ terms are equal to $4$ and so on. Since $$ 2^0+2^1+2^2+\dots+2^n=2^{n+1}-1 $$ the term at place $1023$ is $512$. The next $2^{10}$ terms are equal to $1024$.

$\endgroup$
6
  • 1
    $\begingroup$ How did you get this $ 2^0+2^1+2^2+\dots+2^n=2^{n+1}-1 $ ? $\endgroup$
    – Kaushik
    Commented Jul 22, 2019 at 19:05
  • 1
    $\begingroup$ @Kaushik In binary $\underbrace{11\dots1}_{n\text{ times}}+1=1{\underbrace{00\dots0}_{n\text{ times}}}$. Or use the standard formula $1+x+x^2+\dots+x^n=\frac{x^{n+1}-1}{x-1}$ (valid for $x\ne1$). $\endgroup$
    – egreg
    Commented Jul 22, 2019 at 20:49
  • $\begingroup$ But why is this true ?->[$ 2^0+2^1+2^2+\dots+2^n=2^{n+1}-1 $] $\endgroup$
    – Kaushik
    Commented Jul 22, 2019 at 21:22
  • $\begingroup$ @Kaushik Doesn't the previous comment answer your question? $\endgroup$
    – egreg
    Commented Jul 22, 2019 at 21:27
  • 1
    $\begingroup$ @Kaushik The lhs is a number in binary representation $\endgroup$
    – egreg
    Commented Jul 23, 2019 at 7:03
2
$\begingroup$

The given sequence is equivalent to

$$ 1 + 2(2) + 4(2^{2}) + 8(2^{3}) + 16(2^{4}) + \ldots $$

$$ = 1 + (2^{2})^{1} + (2^{2})^{2} + (2^{3})^{3} + \ldots + (2^{2})^{k-1} + \ldots $$

Now, since this is a geometric series, we may solve

$$ s_{k} = \frac{a(1 - r^{k})}{1-r} = \frac{1(1-4^{k})}{1-4} = 1025 $$

which easily can be shown to give $ 5 < k < 6$.

Hence, the integer $k$ we seek is $5$; and so, the $1025th$ term of the sequence is $4^{k} = 4^{5} = 1024.$

$\endgroup$
0
1
$\begingroup$

$$ 2^0 + 2^1 + 2^2 + 2^3 + ... + 2^n < 1025 = 2^{10}+ 2^0 $$ $$ 2^1 + 2^2 + 2^3 + ... + 2^n < 2^{10} $$ $$ \frac{1}{2^9} + \frac{1}{2^8} + ... + \frac{1}{2^{10-n}} < 1 $$

In the left-hand side of the above inequality, we've acquired a geometrical sequence. The summation formula for geometrical series is;

$$ S = \frac{a(1-r^n)}{1-r} $$

So this summation must be smaller than 1, with this condition stated we can set n = 9.

$$ 2^0 + 2^1 + 2^2 + ... + 2^9 = 1023 $$

We are now able to conclude that the term at place 1024 and 1025 (at the same time) is 1024.

$\endgroup$
0
$\begingroup$

Make up the frequency and cumulative frequency table: $$\begin{array}{c|c|c} x&f&F\\ \hline 1&1&1=2^1-1\\ 2&2&3=2^2-1\\ 4&4&7=2^3-1\\ 8&8&15=2^4-1\\ \vdots&\vdots&\vdots\\ 256&256&511=2^{9}-1\\ 512&512&1023=2^{10}-1\\ 1024&1024&2047=2^{11}-1\\ \vdots&\vdots&\vdots\\ 2^n&2^n&2^{n+1}-1 \end{array}$$ So, your approach was efficient to notice that $a_{2^n}=2^n$. Hence, $a_{1024}=\color{red}{a_{1025}}=\cdots =a_{2047}=\color{red}{1024}$.

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .