poem or song of lamentation; poem or song expressing sadness at someone's death
When his friend the poet John Keats died, the poet Percy Shelley wrote an elegy for him that is considered to be one of the greatest in any language.
elegos (poem or song of lament) (Greek)
E (a)-LEGY (legendry). so if a legendry person dies. people sing a mournful poem or people lament or regret for his death. sounds like eulogy.