Processing math: 100%

Friday, January 17, 2025

A cloning problem from a reddit math contest

 A cute problem from reddit.


You have 2n people standing in an infinite row at spots say 1,2,3,..,2n (one person at each spot). A scientist performs the following steps repeatedly.

Clone every person on the row, and move the clones one position the right i.e. if there were x people at position k, you create x clones and place them at position k+1. Note that this is done for every position in parallel (so no moving clones twice etc). Previously empty positions could see folks being moved there.


After 2n1 repeats of the above steps, how many people will be there at position n?

Scroll down for a solution.

.

.

.



Suppose there are pj people at position j (j>=1).

Then the steps is basically replacing pk+1 with pk+1+pk

This looks ripe for matrices, the steps are basically a linear transformation, but the matrix is large, of size 4n1 or so.


There is another way to look at this: polynomials!


Let f(z)=n=1pnzn

(Even though there is infinity, it is still a finite polynomial as all pi=0 after a certain point)


Then the steps are basically replacing f(z) by f(z)(z+1)

Initially f(z)=z+z2++z2n

After 2n1 steps we get

(z+z2++z2n)(1+z)2n1=

(z+z2++z2n)(2n1r=0(2n1r)zr)

(using binomial theorem on (1+z)2n1)

The number of people in row n is coefficient of zn and that comes out to be

nr=0(2n1r)=22n12=22n2

(using (2n1r)=(2n12n1r) and adding them up to get 22n1)


No comments:

Post a Comment