All perfect praise be to Allah, The Lord of the Worlds. I testify that there is none worthy of worship except Allah, and that Muhammad is His slave and Messenger.
There is a disagreement among the scholars about whether or not the reward of the prayers can reach the dead person. The Maliki and the Shafi’i Schools of jurisprudence are of the view that it does not reach him and their evidence is the following verse: Allah Says (what means): {… And that there is not for man except that [good] for which he strives.} [Quran 53:39] Moreover, the Prophet said: “When a man dies, his deeds come to an end, except for three: A continuous charity, knowledge by which people derive benefit, a pious child who supplicates for him”. [Muslim] They said that the dead person only receives after his death what comes from the three sources mentioned in the Hadeeth or the reward of fasting as mentioned in the Hadeeth reported by Al-Bukhari and Muslim that a man came to the Prophet and said: “O Messenger of Allaah, my mother died and a month's fasting was due on her. Should I fast on her behalf?” The Prophet asked: “If your mother had a debt would you fulfill it for her?” He said, “Yes”. Thereupon, the Prophet observed: “A debt to Allah has more of a right to be fulfilled”. [Ahmad, At-Tirmithi, An-Nassa'i, Abu Daawood and Ibn Majah]
The reward of pilgrimage also reaches the dead person as narrated in a Hadeeth from Ibn ‘Abbaas who said that a woman from the tribe of Johaynah came to the Prophet and said: “My mother had vowed to perform Hajj but she died before fulfilling her vow, should I perform Hajj on her behalf? The Prophet said: “Yes, perform Hajj on her behalf. Would you not pay off any debts your mother might have left behind upon her death? Pay off what you owe to Allah, for He is most deserving of settlement of His Debt”. [Al-Bukhari]
Moreover, Imam An-Nawawi is of the opinion that the reward of prayer does not reach the dead person. Ibn ‘Abdul Barr even reported a consensus on this opinion.
However, the Hanafi and Hanbali Schools of jurisprudence claim that the reward of prayer reaches the dead person like fasting, pilgrimage and alms. Ibn Al-Qayyim said: 'the forms of worship are of two kinds: physical and financial. Paying alms (Sadaqa and Zakah) on behalf of a dead person is valid and its reward reaches him, this means that the reward of all financial forms of worship reach the dead person. Similarly, the fact that the reward of fasting reaches the dead person means that the reward of all physical forms of worship reaches the dead person. In addition, the Hadeeth prove that the reward of Hajj also reaches the dead person. The Hajj consists of both forms of worship, the physical as well as financial'.
However, the scholars who hold the opinion that the reward reaches the deceased stipulate that the person who performs the good deed should not take any compensation for his deeds.
Imam Ibn Taymiyyah said that ‘those who hold the opinion that the reward of good deeds reaches the dead person specifically mean those deeds which are performed only for the Sake of Allah’.
In the light of the above details, we conclude that the will left by your father is null according to both opinions. According to the first opinion the reward does not reach him at all, and according to the second opinion, the deed should only be performed for the Sake of Allah without gaining any material benefit. The Prophet said: “Whoever performs an act which is not in accordance with ours [our religion], it will be rejected from him.” [Al-Bukhari and Muslim]
Finally, we advise you to give charity on behalf of your father and ask Allah to forgive him. This will benefit him, Allah willing.
Allah knows best.