NAMAZ E MAYYAT
The following is quoted, yet briefly, from the book entitled Zad al- Ma’ad by ‘Allamah al-Majlisi, may Allah show him mercy, under the title: Chapter: the Deceased Prayer:
The performance of the ritual Deceased Prayer is obligatory upon every Muslim individual who knows about the death of somebody. If one Muslim performs this prayer, the other Muslims will be exempted from this obligatory duty. Unanimously agreed by all scholars, the Deceased Prayer is obligatory upon all mature Twelver Shi’ites. However, it is most famous and most acceptable that this prayer is obligatory upon even the immature who are more than six year old. Apparently, it is sufficiently acceptable to intend seeking nearness to Almighty Allah (rather than pronouncing the words of intention). To perform the Deceased Prayer for the dead bodies of the less than six month year old babies who have been born alive is deemed highly recommended by some scholars, but deemed heretic by some others. However, it is precautious to neglect performing this prayer for these babies.
According to the religious law, the foremost people to perform the Deceased Prayer are the nearest to the deceased people and who deserve the largest quantity of his/her inheritance. This is the most familiar law. Thus, a husband must precede others in performing the Deceased Prayer of his wife.
The performer of the Deceased Prayer must face the kiblah direction and stand to the right side of the head of the dead body, which must be laid down on the back.
Validity of the Deceased Prayer is not conditional upon ceremonial purity; therefore, it is valid for the ceremonially impure, the menstruating women, and those who have not performed the ritual ablution (wuzu’) to perform such prayers, although it is recommended for the performers of this prayer to have performed the ritual ablution. If water is not available, there is something prevents from using water, or there is not enough time to perform the ritual ablution, it is then highly recommended, according to traditions, to perform the dry ablution (i.e. tayammum). However, it is understood from the apparent meanings of some traditions that dry ablution should be used even if there is nothing prevents from performing the ritual ablution.
It is also traditional that the performer of the Deceased Prayer should stand in the middle of the dead body of a man and in front of the breast of the dead body of a woman. This is the most familiar rule. Besides, the performer of the Deceased Prayer should take off the shoes and must intend performing the Deceased Prayer. He must then repeat the takbir statement five times. It is also traditional that he raises his hands to the level of his ears while uttering these statements.
Familiarly, he should say the following words after uttering the first takbir statement:

These words should be advisably said after uttering the second takbir statement:

These words should be advisably said after uttering the third takbir statement:

These words should be advisably said after uttering the fourth takbir statement:

Then, the fifth takbir statement should be uttered, and thus the prayer has been accomplished utterly and acceptably.
As another method, it is familiarly better to say these words immediately after determining the intention of performing the Deceased Prayer:

After that, it is recommended to say these words:

After that, it is recommended to say these words:

After that, it is recommended to say these words:

The performer of the Deceased Prayer should then say one more takbir statement and finish the prayer.
If the dead person is female, the following words should be said by the performer of the Deceased Prayer instead:

If the dead person is of those whom are deemed enfeebled, then the performer of the Deceased Prayer should say these words:

.
If the dead person is an immature child, the performer of the Deceased Prayer should say these words:

.