This is going to be a long time, because I have to make a deduction and so I can only pass on the logic. Each case has to be calculated individually
Let's start with the fact that in the pre-Islamic era (Jahiliya), inheritance may have taken place in three circles. On the basis of descent, adoption and alliance. Women and minors were excluded from the procedure, only the offspring and the ascending branch were involved into the heritage. There was also the case of adopted sons who were considered as members of blood lineage so they could inherit and the honored friend or fellow warrior, who could inherit the wealth based on a covenant when the person died.
In the early stages of Islam, these conditions were maintained, and even expanded by two more.
These two cases are of those who flee from Mecca to Medina and those who established brotherhood in Medina. People who fled from Mecca to Medina are called Muhajirs, and those in Medina who received and supported them are called Ansar. As the refugees left without property and in Medina the community had to be forged together, a regulation of inheritance between refugees and hosts was introduced, which strengthened internal cohesion. Muslims who did not flee from Mecca and did not join the Muhajirs, lost their right to the inheritance.
Those who believed, and adopted exile, and fought for the Faith, with their property and their persons, in the cause of Allah, as well as those who gave (them) asylum and aid,- these are (all) friends and protectors, one of another. As to those who believed but came not into exile, ye owe no duty of protection to them until they come into exile; but if they seek your aid in religion, it is your duty to help them, except against a people with whom ye have a treaty of mutual alliance. And (remember) Allah seeth all that ye do. (Quran 8:72)
The reference is to the Muhajirin and the Ansar, the Emigrants and the Helpers, the people who forsook their homes and adopted voluntary exile from Makkah in company with their beloved Leader, and their good friends in Madinah, who gave them asylum and every kind of assistance, moral and material. Under the magnetic personality of the Holy Prophet these two groups became like blood-brothers, and they were so treated in matters of inheritance during the period when they were cut off from their kith and kin.
The Believers (Muslims) were entitled to all assistance in matters of religion. But if they were not strong enough to suffer voluntary exile on behalf of the Cause and make the personal sacrifices which their more ardent brethren in faith made, they could not reasonably ask for political or military assistance or protection. Religious protection and support they could get even if they were not exiling.
Establishing brotherhood served also the same purpose. The defense struggles of the new state, Medina, brought together the citizens of the city-state into a common alliance. The Prophet (peace be upon him) affirmed this with an oath of brotherhood. This meant that non-blood related persons who jointly defend Medina for the cause of Islam, are also considered brothers, and they are also linked by the law of inheritance.
To (benefit) every one, We have appointed shares and heirs to property left by parents and relatives. To those, also, to whom your right hand was pledged, give their due portion. For truly Allah is witness to all things. (Quran 4:33)
However, consolidating the situation, the role of family was in focus, and this is the guiding principle even today. Parallelly, all other inheritance circles were closed by Islamic law and only the family remained open. Thus, there is no inheritance for an adopted son, an ally, and the established brotherhood or refugee-host status have been ceased. Several quotes narrow the circle, here I mention only the case of adopted sons:
… nor has He made your adopted sons your sons. Such is (only) your (manner of) speech by your mouths. But Allah tells (you) the Truth, and He shows the (right) Way. (Quran 33:44)
If a man called another's son "his son", it might create complications with natural and normal relationships if taken too literally. It is pointed out that it is only a facon de parler in men's mouths, and should not be taken literally. The truth is the truth and cannot be altered by men's adopting "sons". "Adoption" in the technical sense is not allowed in Muslim Law. Those who have been "wives of your sons proceeding from your loins" are within the Prohibited Degrees of marriage; 4:23: but this does not apply to "adopted" sons.
A family is bound not only by emotional cohesion, but it must be also supported by material and financial provisions. This is what the matrimonial and inheritance procedure is all about and these must be negotiated together. I wrote about the marriage contract earlier. I have explained that a man is obliged to give dowry and the extent of this is a matter of agreement. The principle is that this amount would ensure for the woman a chance to start a new life if the relationship did not work. So, it is not a purchase price, but the woman's exclusive property! Whoops, that's not what you see in practice? I can't do anything about that. I write about law, not the practice. So, we can see that the man has an obligation and the woman is the beneficiary. This is compensated by inheritance, where a man inherits twice as much as a woman. Yes, but keep in mind that we are talking about a society that is traditional, with women doing housework at home, and men working, earning money, fighting in war. The financial burdens of the family were on the men. These burdens are compensated by the inheritance routine.
Today the situation is different. Therefore, law must also evolve. Women and men are equally involved in the maintenance and financial burden of the family (not everywhere, but this is the trend). Sharia also provides the opportunity to move on. Indeed, the Islamic inheritance provisions apply to two-thirds of the estate. One-third is left free to the testator and is the fund for further compensation based on age, location and specific circumstances. Below are two typical quotes, but there are more and several Hadis refine further the legal interpretation. To understand logic, I think it's enough:
Allah (thus) directs you as regards your Children's (Inheritance): to the male, a portion equal to that of two females; if only daughters, two or more, their share is two-thirds of the inheritance; if only one, her share is a half. For parents, a sixth share of the inheritance to each, if the deceased left children; if no children, and the parents are the (only) heirs, the mother has a third; if the deceased left brothers (or sisters) the mother has a sixth. The distribution in all cases (is) after the payment of legacies and debts. Ye know not whether your parents or your children are nearest to you in benefit. These are settled portions ordained by Allah; and Allah is All-knowing, All-wise. (Quran 4:11)
The principles of inheritance law are laid down in broad outline in the Quran; the precise details have been worked out on the basis of the Prophet's practice and that of his Companions, and by interpretation and analogy. Muslim jurists have collected a vast amount of learning on this subject.
Here we shall deal only with the broad principles to be gathered from the Text, as interpreted by the Jurists. 1. The power of testamentary disposition extends over only one-third of the Property; the remaining two thirds are distributed among heirs as laid down. 2. All distribution takes place after the legacies and debts (including funeral expenses) have first been paid. 3. Legacies cannot be left to any of the heirs included in the scheme of distribution; or it will amount to upsetting the shares and undue preference of one heir to another. 4. Generally, but not always, the male takes a share double that of a female in his own category. Don’t forget that women gets dowry at the time of the marriage. In case of heritage man gets double. The two compensates each other. This is the general interpretation, and is confirmed by the supplementary provision in 4:176 at the end of the Surah, which should be read along with this.
The verse deals with the portions allotted to a. children, and b. parents. The next verse deals with the portions allotted to c. husband or wife of the deceased, and d. collaterals. The children's shares are fixed, but their amount will depend upon what goes to the parents. If both parents are living, and there are also children, both father and mother take a sixth each: - if only one parent is living, he or she takes his or her sixth; and the rest goes to the children. - If the parents are living, and there is no child or other heir, the mother gets a third (and the father the remaining two-thirds); - if there are no children, but there are brothers or sisters (this is interpreted strictly in the plural), the mother has a sixth, and the father apparently the residue, as the father excludes collaterals.
In what your wives leave, your share is a half, if they leave no child; but if they leave a child, ye get a fourth; after payment of legacies and debts. In what ye leave, their share is a fourth, if ye leave no child; but if ye leave a child, they get an eighth; after payment of legacies and debts. If the man or woman whose inheritance is in question, has left neither ascendants nor descendants, but has left a brother or a sister, each one of the two gets a sixth; but if more than two, they share in a third; after payment of legacies and debts; so that no loss is caused (to any one). Thus is it ordained by Allah. and Allah is All-knowing, Most Forbearing. (Quran 4:12)
The husband takes a half of his deceased wife's property if she leaves no child, the rest going to residuary; if she leaves a child, the husband gets only a fourth. Following the rule that the female share is generally half the male share, the widow gets a fourth of her deceased husband's property, if he leaves no children, and an eighth if he leaves children. If there are more widows than one, their collective share is a fourth or an eighth as the case may be; inter se they divide equally.
The word in Arabic is kalalah, which is so construed usually. But it was nowhere defined authoritatively in the lifetime of the Messenger. This was one of the three terms about which Hadhrat Umar wished that the Messenger had defined them in his lifetime, the other two being the share of grandfather, and riba (usury). On the accepted definition, we are concerned with the inheritance of a person who has left no descendant or ascendant (however distant), but only collaterals, with or without a widow or widower. If there is a widow or widower surviving, she or he takes the share as already defined, before the collaterals come in.
I was long and still we had only a brief glimpse. I am not able to present the inheritance rights of minors and orphans due to the volume of space. The responsibilities of guardians, etc. I hope I have succeeded in presenting the principle and the possibility of harmonizing it with today's conditions. If in the lifetime of the Prophet (peace be upon him) the routine could amend twice and the law could evolve, how can it not develop today? I'm just talking about law, not about doctrine!
As I stated in the marriage contract, it is possible today to record the will in a deed of public law and thereby enforce Islamic inheritance rules in a secular society, since in a harmonized form there is no conflict between Islamic and European secular law in this area.