Given:

There are x items for a total of y mass. (x,y)

the first 20% of these x items contain 80% of the y mass. (I will call this (x1,y1))

the last 80% of these x items contain 20% of the y mass. (I will call this (x2,y2))

the first 20% of these x1 items contain 80% of the y1 mass.

the last 80% of these x1 items contain 20% of the y1 mass.

the first 20% of these x2 items contain 80% of the y2 mass.

the last 80% of these x2 items contain 20% of the y2 mass.

and so on until each item has a mass.

I can't seem to wrap my mind around a mathematical equation that would tell you what the mass of the kth item was where 1 <= k <= n.

## Mass of the kth item in a set.

- daniel.is.fischer
**Posts:**2400**Joined:**Sun Sep 02, 2007 11:15 pm**Location:**Bremen, Germany

### Re: Mass of the kth item in a set.

You can't solve that exactly in integers.

Say you have 5 items with total mass 100. Obviously, the first item has mass 80, 4 items remain to be determined. The first 20% = 0.8 items - wait, 0.8 items?

Of course, you can assign masses to fractional items, then the first 0.8 of the second item have mass 16, leaving 3.2 items with total mass 4. The first 20% = 0.64 items of these have a total mass of 3.2. The remaining 2.56 items have a total mass of 0.8.

Of the 0.64 items with mass 3.2, the first 0.2 items are part of the second item, the remainder of the third. The first 20% = 0.128 items have mass 2.56. We now have 0.928 of the second item with mass 18.56 and 0.512 items of which 0.072 are part of item 2, 0.44 part of item 3, with mass 0.64. the first 20% = 0.1024 items of the 0.512 items have mass 0.512, the remaining 0.4096 have mass 0.128 ...

But if you go the fractional route, it's better to do it with calculus. So instead of x items, you have one object of length x. The mass density of the object is such that for every segment of it, the first 20% of the segment have 80% of the total mass of the segment.

Up to constant factors (which are irrelevant), this determines the mass density function to be md(t) = t

The mass of item k is then determined by c∫

Say you have 5 items with total mass 100. Obviously, the first item has mass 80, 4 items remain to be determined. The first 20% = 0.8 items - wait, 0.8 items?

Of course, you can assign masses to fractional items, then the first 0.8 of the second item have mass 16, leaving 3.2 items with total mass 4. The first 20% = 0.64 items of these have a total mass of 3.2. The remaining 2.56 items have a total mass of 0.8.

Of the 0.64 items with mass 3.2, the first 0.2 items are part of the second item, the remainder of the third. The first 20% = 0.128 items have mass 2.56. We now have 0.928 of the second item with mass 18.56 and 0.512 items of which 0.072 are part of item 2, 0.44 part of item 3, with mass 0.64. the first 20% = 0.1024 items of the 0.512 items have mass 0.512, the remaining 0.4096 have mass 0.128 ...

But if you go the fractional route, it's better to do it with calculus. So instead of x items, you have one object of length x. The mass density of the object is such that for every segment of it, the first 20% of the segment have 80% of the total mass of the segment.

Up to constant factors (which are irrelevant), this determines the mass density function to be md(t) = t

^{-[alpha]}, where md(t) is the mass density at distance t from the left end of the object and [alpha] = [frac]log 4,log 5[/frac].The mass of item k is then determined by c∫

_{k-1}^{k}md(t) dt, where c must be chosen so that c∫_{0}^{x}md(t) dt = y.Il faut respecter la montagne -- c'est pourquoi les gypaètes sont là.