Niddah 9:4-5
Niddah 9:4
If three women slept in the same bed and blood was found under one of them, all three are ritually unclean. If one of them checked herself and was found to be unclean, she is unclean and the others are clean. The women may also attribute the stain to one another. If they were unlikely to see blood (e.g., pregnant or nursing), we consider them as if they were likely to do so.
Niddah 9:5
If three women slept in one bed and blood was found under the one in the middle, all three are unclean. If it was found under the innermost woman, the two women on the inside are unclean but the one on the outside is clean; if under the outermost woman, the two outer women are unclean but the one on the inside is clean. This is the case when they got into the bed by climbing over the foot; if they got in by passing over then all of them are unclean. If one of them examined herself and was found to be clean, then she is clean and the other two are unclean. If two of them examined themselves and found themselves clean, then they’re clean and the third woman is unclean. If all three of them examined themselves and found themselves clean, then all of them are unclean (because it had to come from someone). This is comparable to a ritually unclean mound that was mixed up with two ritually clean mounds. If they examine one and find it clean, that mound is clean and the other two are unclean. If they examined two and found them to be clean, they’re clean and third mound is unclean. If they examined all three and found them to be clean, all of them are unclean; this is the opinion of Rabbi Meir, who used to say that anything presumed to be unclean remains perpetually unclean until the source of the impurity can be located. The Sages say that one searches for the impurity until he reaches bedrock or virgin soil.