All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad is His slave and Messenger. We ask Allaah to exalt his mention as well as that of his family and all his companions.
If a man committed fornication or adultery and then fathered a child/children then these children do not take his name according to the majority of the scholars and they do not inherit the man or vice-versa. But they can be named after their mother and they can inherit her and vice-versa as long as they are of the same religion. If she was a non-Muslim and later embraced Islam then they do not inherit each other. However, if the children are young then the ruling is that they are Muslims as their mother and so they can inherit her and she can inherit them.
Allaah knows best.