Generally speaking, in order for a person to rid himself of his ritually impure status, he must immerse in a mikveh, a natural body of water that contains a quantity of at least 40 se’a. The Gemara on our daf concerns itself with situations where it is not clear whether the required 40 se’a are in one place. For example, if a wave containing 40 se’a comes crashing down on someone, that person would become tahor. In the water, however, only the parts of that same wave that are connected to the ocean – called rashin – can be used as a mikveh; the kippin, or top of the wave (or arc), is considered to be air and is thus not a kosher mikveh.
Another case discussed by the Gemara is that of shalosh gemamiyot ba-nahal. In this case, three pools of water are connected to one another by a small trickle of rainwater. If the top pool and the bottom pool have less than the required 40 se’a, but the middle one does have the required amount, we find a disagreement between Rabbi Meir, who permits immersion in any of the pools since the water between them connects them to one another, and Rabbi Yehuda, who insists that only the middle pool containing the full amount can be used as a mikveh.
The description of shalosh gemamiyot ba-nahal matches typical wadis (dry river beds) that are commonly found in the deserts of the Land of Israel and in the surrounding areas. While they are totally dry during the summer, during the rainy winter season floods of water race through these valleys, leaving behind ponds of water that are created naturally. We also find that cisterns are dug out specifically to access these rainwaters that collect underground (see, for example, Bereishit 26:19 where we find the servants of Yitzhak digging in the valley and finding water).