Copenhagen police late Tuesday confirmed the identity of the suspected gunman behind the weekend's double shooting as 22-year-old Omar El-Hussein.
"The Copenhagen police can now confirm the reports published by the press about the alleged perpetrator's identity," it said in a statement.
Police also said that in his first attack on Saturday, he had unsuccessfully tried to use several entrances to a cultural centre that was hosting a debate on Islam and free speech attended by controversial Swedish cartoonist Lars Vilks. Witnesses have said that the death toll could have been far higher if the gunman had managed to enter the building.
El-Hussein, a Danish-born man of Palestinian origin
, was killed in a shootout with police early Sunday after opening fire at the cultural centre, killing filmmaker Finn Nørgaard, after which he shot dead Dan Uzan, a Jewish guard outside the city's main synagogue.
Uzan is to be buried Wednesday in Copenhagen.
Five police were injured in the attacks, all of whom are said to be recovering.
"Questioning and technical investigation shows that the perpetrator upon his arrival at the site first tried to come in through other entrances than the main entrance," police said of the first attack.
On the street outside the cultural centre where the event was being held he met his first victim, whom he shot with a weapon later found on a football field at Mjølnerparken, the low-income housing estate where he grew up, it said.
Two weapons were used in the attack outside the synagogue, both of which were found on El-Hussein when he was shot dead.
A man was also arrested in Mjølnerparken on Tuesday, but police decline to comment on reports of links to the attacks.
Also on Tuesday, the public radio station in Sweden, Sveriges Radio (SR), was forced to apologise after one of its journalists asked the country's Israeli ambassador if Jews themselves were "responsible for the progression of anti-Semitism."
Ambassador Isaac Bachman appeared shocked, and replied: "I purely and simply reject the question."
SR offered its "fullest apologies" and added: "The Jewish community has suffered a horrible act of terror and has all our sympathy."
"Tonight I want to tell all Danish Jews: you are not alone. An attack on the Jews of Denmark is an attack on Denmark, on all of us," Thorning-Schmidt told the crowd.