By Damien McGuinness
BBC News, Riga
Latvian-born Dmitrijs Afanasjevs can't vote or work in many government jobs
What is it like being a non-citizen in the country where you have lived all your life? That's the experience of many ethnic Russians in the Baltic state of Latvia.
In a classroom in the Latvian capital, Riga, 23-year-old student Dmitrijs Afanasjevs takes a seat nervously. He is one of a dozen people about to sit a Latvian language exam, as part of a test to become a Latvian citizen.
But Dmitrijs is not an immigrant. Like most of the people in this room, he was born in Latvia. In fact, even his parents were born here.
But his family is ethnically Russian. And because they moved here while Latvia was part of the USSR, he is not automatically eligible for Latvian nationality.
Instead he is classed as a so-called resident alien. Only those born after Latvian independence in 1991 automatically receive citizenship.
The words in Latvian for "non-citizen" are printed in large bold letters on the cover of Dmitrijs' passport.
This means he can't vote, can't work in many state-employed positions and often has trouble crossing borders.
"I can travel with my passport, but when I am in France in the airport, and I show my passport, they say, 'Sorry, which country are you from? What is this?' And I have to say I am not a citizen," he said before sitting the test. "I need citizenship to be a human."
In Latvia, a country of just over 2.2 million people, around a third of the population is defined as ethnically Russian - a category used to include Russian-speakers from all over the former Soviet Union.
More than 250,000 of these ethnic Russians are not Latvian citizens. But almost 90% of them do not have Russian citizenship either. They are in a limbo between states.
According to Riga's first ethnically Russian mayor, Nils Usakovs, older ethnic Russians feel particularly let down by the Latvian state.
"Some of them feel that they were cheated. They voted for Latvian independence in 1990 and they didn't get Latvian passports despite the fact they have lived here all their lives."
Scars of history
Latvia's ethnic mix is a legacy of almost half a century of Soviet rule, before the country achieved independence in 1991.
Nationalist protesters decry Russian "colonialism" in Latvia
Until the 1980s, large numbers of Russian workers were sent to Latvia, ostensibly to provide manpower for Soviet factories.
But Latvian historians believe the Russian influx was a conscious decision by Moscow to dilute native Baltic culture.
Most settled in urban areas, and today in the capital, Riga, almost half of the population speaks Russian as a first language. In Latvia's second-largest city, Daugavpils, 75% of residents are ethnically Russian.
"You have more daily newspapers in Russian than in Latvian," says Roberts Zile, head of the Latvian nationalist For Fatherland and Freedom party, a partner in the country's governing coalition.
"Our language survived decades of Soviet oppression. That's why we are really worried now about the increase of Russian-language media in the public space here in Latvia."
Mr Zile has launched a campaign for a referendum to ban Russian-language state schools, which account for about 14% of Latvia's high schools.
But Russian-speakers say the ban would discriminate against their rights as an ethnic minority and Mr Zile's political opponents accuse him of pandering to nationalist voters ahead of October's general election.
'Back door colonialism'
In any event, Mr Zile is unlikely to garner the 10% of public support needed to launch a referendum.
Independent from 1918 to 1939
Part of the USSR after World War II
Regained independence in 1991
700,000 Soviet-time migrants and their children became non-citizens
By the time Latvia joined the EU in 2004, this figure had dropped to around 450,000
Country's total population is 2.2m (including non-citizens)
On the steps of the national parliament in Riga, Latvian nationalists, some of whom belong to Mr Zile's party, are protesting against a new bill which they say is Russian colonialism by the back door.
The law would give wealthy foreigners residency rights in Latvia if they start a business or buy property. These protestors claim this would allow rich Russian oligarchs to take over Latvia. It is Russian imperialism all over again, they say, but this time with money instead of tanks.
Tensions are also likely to come to the surface on 9 May, when Russians from all over the country come to the Soviet Victory Monument in Riga to celebrate victory over Nazi Germany in World War II.
For Latvians, the riotous celebrations are hard to stomach. For them this date marks the beginning of half a century of Soviet occupation.
Considering Latvia's painful history, the two communities rub along remarkably well. There are no violent clashes and only a minority of extremists from either side express intolerant views.
But young people, like Dmitrijs, are still feeling the effects of the region's tortured history.
Back at the exam centre, he has just collected his results for his citizenship test.
"It's very funny... I didn't pass," he said. "They said my spoken Latvian was perfect, but I had some problems with writing."
Dmitrijs now has to wait until September until he can re-take the test. Until then he remains a non-citizen in the country where he was born.