In his write-up of Rule 34, Glowing Fish proposes that it is unlikely for Internet porn to exist for each of the 5400 different possible sexual arrangements of the seven castaways on Gilligan's Island. To be fair, Glowing Fish does not actually claim that there are 5400 combinations, but just points out that "seven factorial is 5400" (which he later corrected to say it actually isn't, it is only 5040) But there's a question to be developed in the mathematical basis of this calculation, and to show why this is, I present to you below a list of the top three level iterations of this formula, that is, all possible sexual groupings of three or fewer residents of Gilligan's Island. Annotated.

For all intentions of this demonstration, we will ignore the null set -- that is, the possibility that someone out there has made Internet porn involving Gilligan's Island, but eschewing inclusion of any characters from the show. Who knows, maybe someone dreams of humping the grass huts or penetrating the moist tropical sand.

Lone rangers

The first set of iterations is necessarily focused on masturbation or comparable solitary activities, for it is the set of each individual character by themselves:

Gilligan (alone)
Mary Ann (alone)
Ginger (alone)
Mrs. Howell (alone)
Skipper (alone)
Professor (alone)
Mr. Howell (alone)

Pairings

The second set, of course, is where the action begins. The second set is also uniquely determined in that every possible sexual encounter is either necessarily gay or straight, which I will explain further when we get to the threesomes. We will begin with the Gilligan sets, because Gilligan is the star. There are seven castaways, or Gilligan-plus-six, three men, and three women. Gilligan plus one woman, in the order that I'd most like to see, includes the following set:

Gilligan with Mary Ann
Gilligan with Ginger
Gilligan with Mrs. Howell

The supremacy of the first two would, naturally, be hotly debated by fans of the show. Observe, also, that Mary Ann is the only character who is not identified in the show's credits by vocation or other tertiary characteristic -- Gilligan and the Skipper are the first mate and captain of a boat; Ginger is a movie star, the professor is a professor, and Mr. and Mrs. Howell are millionaire and wife of millionaire. It is generally put forth throughout the series that Mary Ann is a farm girl, but why not just say "farm girl" in the opening credits? I conclude it is because Mary Ann's real avocation is something else entirely which would conventionally be deemed shameful to include in the opening titles, and therefore that she is a prostitute. (I personally think prostitution is closer to the sacred than the profane, but I don't write for television).

Getting back to the sets, we now come to Gilligan's unequivocally homosexual encounters:

Gilligan with Skipper
Gilligan with Professor
Gilligan with Mr. Howell

Based on the existing relationships between the characters, the first is probably the most likely. On the other hand, I always suspected that the professor was gay. Now, we jump to the lesbian bits -- not that women sexing women are any less homosexual than males, but common societal parlance parses them as such. Having only three women on the island, only three possible pairings present themselves, so we will go just a bit out of order and put them all together:

Mary Ann with Ginger
Mary Ann with Mrs. Howell
Ginger with Mrs. Howell

Again, for most fans, there's only one of them they truly and actually want to see. So then, we've already knocked out all pairings involving Gilligan, which leaves nine possible pairings of castaway gals with castaway guys, and they are as follows:

Mary Ann with Skipper
Mary Ann with Professor
Mary Ann with Mr. Howell
Ginger with Skipper
Ginger with Professor
Ginger with Mr. Howell
Mrs. Howell with Skipper
Mrs. Howell with Professor
Mrs. Howell with Mr. Howell

Notice, of all possible pairings or groupings of larger numbers, only the last one of this series is permissible in the eyes of the bulk of religious doctrines, all others being adultery or fornication of some meter (though there do exist religious beliefs that are positive towards free sexuality). On the other hand, if my Mary Ann = prostitute theory is correct, then given Mrs. Howell's probable post-menopausal state, the most likely pairing may be between Mary Ann and the man with the most cash money.

Now, more man-gayness. Having already knocked out all of the gay Gilligan sets, we are, as we were with the women above, left with three possibilities, presented below in the order I believe to most logically presume to be of precedence of likelihood between the remaining island studmuffins:

Skipper with Professor
Professor with Mr. Howell
Skipper with Mr. Howell

Threesomes

Now we're up to the threesomes. Some of these are unequivocal in their sexual orientation because they involve three people of the same gender, and so can only include homosexual encounters. But all the rest have a mix of one of one kind and two of the other, and so there's no saying what activities are partaken between the two same-sex participants. Popular practice aside, there's no reason that a Ginger-Skipper-Gilligan combo would not involve some action between the latter two.

Again deferring to the starring character, there are fifteen possible iterations involving Gilligan. Based on the island populace, these fall into three groupings -- first, Gilligan with two ladies (incorporating, naturally, the three possible combinations of two ladies set out above:

Gilligan with Mary Ann and Ginger
Gilligan with Mary Ann and Mrs. Howell
Gilligan with Ginger and Mrs. Howell

Then, the nine versions where Gilligan shares a saucy wench with another shipwrecked island man:

Gilligan with Mary Ann and Skipper
Gilligan with Mary Ann and Professor
Gilligan with Mary Ann and Mr. Howell
Gilligan with Ginger and Skipper
Gilligan with Ginger and Professor
Gilligan with Ginger and Mr. Howell
Gilligan with Mrs. Howell and Skipper
Gilligan with Mrs. Howell and Professor
Gilligan with Mrs. Howell and Mr. Howell

And at last, the three possible threesomes where Gilligan goes gay:

Gilligan with Skipper and Professor
Gilligan with Skipper and Mr. Howell
Gilligan with Professor and Mr. Howell

The star being satisfied, there's only one possible combination including all three ladies, which is, naturally:

Mary Ann with Ginger and Mrs. Howell

After that, we can most easily plot out all possible remaining threesomes involving a guy and two girls, those also being higher in the realm of male fantasy:

Mary Ann with Ginger and Skipper
Mary Ann with Ginger and Professor
Mary Ann with Ginger and Mr. Howell
Mary Ann with Mrs. Howell and Skipper
Mary Ann with Mrs. Howell and Professor
Mary Ann with Mrs. Howell and Mr. Howell
Ginger with Mrs. Howell and Skipper
Ginger with Mrs. Howell and Professor
Ginger with Mrs. Howell and Mr. Howell

And then we come to the set of options most likely to be described by the appellation "finger cuffs":

Mary Ann with Skipper and Professor
Mary Ann with Skipper and Mr. Howell
Mary Ann with Professor and Mr. Howell
Ginger with Skipper and Professor
Ginger with Skipper and Mr. Howell
Ginger with Professor and Mr. Howell
Mrs. Howell with Skipper and Professor
Mrs. Howell with Skipper and Mr. Howell
Mrs. Howell with Professor and Mr. Howell

And, having exhausted all the gay Gilligan groupings, only one homosexual man-fest is left to celebrate on this island:

Skipper with Professor and Mr. Howell

Synthesis

For the record, then, there are 63 possible iterations of between one and three Gilligan's Island regulars, including seven solos, 21 pairs, and 35 trysts of three. Among those threesomes, it must also be observed, there are five in which Mr. and Mrs. Howell welcome a third person into their marriage, and two of these are permissible under polygamous doctrines such as those endorsed by the Bible and the Qu'ran (if, that is, Mr. Howell takes either Ginger or Mary Ann as a second wife). As for higher numbers, suffice to say that they increase in complexity as they go. There are, naturally, four possible combinations of one man with the three women, and but one grouping with all four males.

How many groupings of four are there? Well consider, of the 35 possible threesomes, only fifteen include Gilligan, so there are twenty possible groupings made by the addition of Gilligan to one of those threesomes. And so, as Gilligan can not be added to any threesomes of which he is already part, there are twenty possible Gilligan foursomes. That's the largest number there will be, for if we next go to, say, all the Mary Ann foursomes, there will be twenty minus the ten that we have already counted in the Gilligan sets. Jumping to Ginger, she also has twenty possible foursomes, minus the ten already counted involving Gilligan and six already counted involving Mary Ann, leaving but four. By the same formula, there is but one more scenario, having Mrs. Howell with the three men other than Gilligan -- a seemingly meagre total of 35 possible foursomes.

It would seem that the groupings of five and six are harder even to count, but in actuality they are easier, because we need only reverse the question and ask, who is left out? In a group of five, two islanders are excluded; here there are the same number of possibilities as there are pairings -- 21. Just as the 35 groups of four mirrored the 35 groups of three, we go to 21, then to a mere seven groups of six (one excluding each character), and a single group of all seven.

That's a total of 126 sets that actually include people -- so why does Glowing Fish come up with 5040? Because he is looking at the iterations within the iterations -- for example, a grouping of Gilligan, Skipper, Mary Ann, and Ginger, could involve sub-pairings of Gilligan with Mary Ann and Skipper with Ginger, or Gilligan with Ginger and Skipper with poor, used up Mary Ann, or the guys with each other and the girls with each other, or a threesome of Gilligan, Mary Ann, and Skipper, with Ginger watching and taking care of herself. Add in all of these possible iterations for all of these groups and you get to the 5040 proposed by E2's other great Fish.