Image copyright Getty Images Image caption Ben Carson backed Donald Trump after pulling out of the presidential race

US President-elect Donald Trump has named Ben Carson, his former rival for the Republican nomination, as secretary of housing and urban development.

"Ben Carson has a brilliant mind and is passionate about strengthening communities", the president-elect said in a statement, adding that the two had discussed his "urban renewal agenda".

Mr Carson is the first African-American to be nominated for Mr Trump's cabinet.

He endorsed Mr Trump in March after ending his own bid for the White House.

"Ben shares my optimism about the future of our country and is part of ensuring that this is a presidency representing all Americans,'' the statement from Mr Trump said.

Media playback is unsupported on your device Media caption Where do Donald Trump supporters get their news from?

But Democratic House leader Nancy Pelosi criticised the nomination of Mr Carson, a retired neurosurgeon, calling him a "disconcerting and disturbingly unqualified choice to lead a department as complex and consequential as housing and urban development".

The agency has an annual budget of about $50bn (£40bn).

What Carson has said about housing

Dr Carson has made some pointed comments in the past over the work of the US Department of Housing and Urban Development (HUD). They provide some insight into how a Carson-run Hud might approach desegregation and the agency's role in tackling poverty.

A report issued by HUD in 2011 criticised the city of Dubuque, Iowa, for withholding the rent-assistance vouchers in a way that disproportionately affected black tenants. In 2015, Dr Carson derided Hud's action as government overreach. "This is what you see in communist countries," he said.

Under the Obama administration, HUD attempted to proactively tackle segregation in American cities by incentivising wealthier areas to build affordable housing.

"These government-engineered attempts to legislate racial equality create consequences that often make matters worse," he wrote in June 2015. "Based on the history of failed socialist experiments in this country, entrusting the government to get it right can prove downright dangerous."

Mr Trump has not always been so positive about the man he has chosen to join his administration.

In November 2015, when Mr Carson briefly overtook him in the polls for the Republican nomination, Mr Trump launched sustained attacks on his rival's character.

In one tweet, he brought together three of Mr Carson's most controversial statements, bringing up Mr Carson's own admissions about his violent behaviour growing up in a poor family in Detroit.

Image copyright Twiiter

Mr Carson has since reiterated statements about his teenage years first made in his autobiography, in which he admitted to wanting to hit his mother on the head with a hammer and to trying to stab a friend.

His assertion that the Egyptian pyramids were not built to entomb pharaohs but instead by the Biblical figure Joseph to store grain were widely ridiculed when they emerged in November.

Mr Carson is a devout Protestant Christian who is a member of the Seventh Day Adventist church.

Cabinet appointments need to be confirmed by the US Senate.

There are still major cabinet positions yet to be announced, including the next secretary of state.

As well as his top team, the president-elect has about 4,000 government positions to fill.

More on Trump preparing for White House

Trump's presidential cabinet takes shape

The people around Donald Trump

Can Donald Trump get what he wants?

The Trump resistance movement

Can Trump outlaw gay marriage?