A Turkish court has demanded a professional examination of the character Gollum from the Lord of the Rings trilogy as part of a case regarding a man who compared president Recep Tayyip Erdogan to the repulsive creature.

Bilgin Ciftci, a doctor, is accused of insulting the president after sharing a meme showing both of them eating, expressing surprise and disbelief.

The experts, including two academics, two behavioural scientists and an expert on cinema, will reportedly decided whether Erdogan was insulted in the tweet.

Ciftci, who claims that Gollum is not a bad character and that he did not insult anyone, faces up to two years in prison if convicted.

The character of Gollum appears in both the Lord of the Rings trilogy and The Hobbit books by JRR Tolkien and the film versions, directed by Peter Jackson. Always longing for the famous ring that deformed his body and mind, Gollum is described as a "small, slimy creature" in The Hobbit.

The judge opted for the expert assessment after admitting that he had not seen the whole movie series.