Here in our city, when a person dies it is the usual practice that his relatives arrange meals for all the relatives for about 3 days. It looks like that they have arranged an invitation for the family/caste. One time one of the relatives arranges and the other time some one else. All the people /relatives eat food at the residences if the dead. What is the logic of such tradition in Islam?
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.
What is being done in your city is among help in transgression and innovation. So, it is contrary to the Sunnah of the Prophet . Now, they must refrain from such acts even if they do represent a permanent custom or tradition for them. In fact, any tradition that contradicts Islam must be given up. What these people are doing is among the lamentation on the dead which is forbidden.
Jareer ibn ‘Abdullah Al-Bajali said: “We used to consider gathering at the dead person's home and making meals for that a kind of lamentation.” [Ahmad]
Imam An-Nawawi said in al-Majmoo’: “Imam Ash-Shaafi’i and his companions () said: 'it is undesirable to sit down while presenting condolences. Sitting here means that the dead person's family gather in a place and people come to present their condolences. What is appropriate is that everyone goes about their work and needs.”
It is Sunnah that some meal be prepared for the family of the deceased. Ahmad reported from ‘Abdullah ibn Ja’far who said: “When the news of the death of Jaafar came, the Prophet said: “Prepare a meal for Jaafar 's family. Indeed, an important matter has befallen them and it occupies them.” Similarly, it is unlawful for the family of the deceased to prepare food for visitors if that food is from the inheritance of the dead person unless all the inheritors agree to it.
Finally, everyone should reject this innovation and try to eradicate it from the community.
Allah knows best.
You can search for fatwa through many choices