A One Smoot brain teaser

The toomanycats are particularly cuddly this evening. Since they've finally gotten the point that I've had enough kitty cuddling, they're now mostly sticking to intraspecies cuddling. Which brings us to this One Smoot Brain Teaser™.

Assuming Dexter and Mirmir hate each other and won't go near each other (which I assume based on how there's a big fit of claws and hissing and running away any time they see each other), how many possible piles of at least two cats could occur chez eeka?

In case you need a visual aid:

Dexter                  Loki
Dexter icon Loki
Izzy being a dumbass 1
Izzy                  Mirmir

Bonus points if you can come up with the equation for solving this. (Yes, this problem is easy enough to do mentally, but equations are useful so you could also do the problem just as fast with 4000 cats *shudder*.)


2 comments:

Anonymous said...

Ooh, combinatorics! It's been a while.

The answer is seven.

Equations:

Let n be the total number of cats; each cat is unique.

Let r be the number of cats in a pile; r goes from 2 to n.

Let x be the number of enemy cats; these cats will never be in a pile together.

For this specific problem, let n=4 (Dexter, Izzy, Loki, and Mirmir) and x=2 (Dexter and Mirmir).

We can either count the total number of possible piles, and then exclude the ones containing more than one enemy cat:

[n!/2!(n-2)! + n!/3!(n-3)! + . . .
+ n!/n!(n-n)!] -
[x!/2!(x-2)! + x!/3!(x-3)! + . . .
+ x!/x!(x-x)!] *
[(1) +
[(n-x)!/1!((n-x)-1)! + (n-x)!/2!((n-x)-2)! . . .
(n-x)!/(n-x)!((n-x)-(n-x))!]]

or we can count only the number of piles that do not contain more than one enemy cat:

[(x)(n-x)] +
[(h-x)/2!((n-x)-2)! + (n-x)/3!((n-x)-3)! . . .
(n-x)/(n-x)((n-x)-(n-x))!] *
[(1+x)]

eeka said...

WINNAR! Beautifully done.

(OK, spill it. Who are you?)