Washington has opened an investigation into the case of a Mexican migrant who died while in US Border Patrol custody, a State Department spokesman said on Wednesday.

"Certainly we are sorry for the loss of life involving Anastasio Hernandez Rojas," said spokesman Philip Crowley, referring to the dead migrant. "We are in touch with the Mexican government."

Crowley said both the US Department of Homeland Security and police in the southern California city of San Diego are investigating the case.

Hernandez Rojas, 42 and a father of five, died on Monday after a beating at the hands of US Border Patrol agents who were seeking to deport him, according to a spokesman at the Mexican consulate in San Diego.

Hernandez Rojas, who had lived in the United States for more than 20 years, died of cardiac arrest after doctors said he had already sustained severe brain damage in the beating.

US President Barack Obama has said he wants to work on comprehensive immigration reform, something that has failed in the Congress twice in recent years, in 2006 and 2007.

On a visit to Washington in May, Mexican President Felipe Calderon urged the US government to repair an outmoded immigration system and do more to ensure that illegal guns do not flow across the countries' shared border.