It is narrated from Sayyiduna A'idh bin Amr (may Allah be pleased with him), who was among those who pledged allegiance to the Messenger of Allah (peace and blessings be upon him) beneath the tree, that he related: His wife was in postnatal bleeding (nifas); after twenty days she saw that she was pure, so she performed the ritual bath (ghusl). Then she began to come under the quilt with him, and he felt her touch. He asked: Who is this? She said: So-and-so (it is I). He asked: What is the matter with you? She said: I saw that I was pure, so I performed ghusl. So he struck her with his foot and made her get up from his bed, and said: Do not try to lead me astray from my religion until forty days have passed.
Hadith Referenceالمعجم الكبير للطبراني / باب العين / 15115