David Bailey, 28, from Britain, has started a business in Brazil and, as a pianist, he also has soaked up the country’­s rich music scene. (Juan Forero/The Washington Post)

It just made sense to be in South America’s economic heart, Jonathan Rosenthal reasoned, no matter that he had been working on Wall Street with some of the investment world’s most heady firms.

The fact was, the United States was in a sustained slump and Europe was tanking, but there were promising opportunities in Brazil. So like a growing number of young, highly educated professionals, Rosenthal made the leap to Brazil’s Wall Street, Faria Lima Avenue, to start a hedge fund that has ridden the country’s economic boom.

With an economy that recently surpassed Britain’s to become the world’s sixth largest, Brazil is offering a sunny and often lucrative alternative to the downcast prospects in the United States and Europe. In a sort of reverse brain drain, foreigners are flocking to Brazil.

The number of foreigners residing in Brazil reached nearly 1.5 million last year, up from 961,000 in 2010, said Paulo Abrao, the government’s highest-ranking immigration official. Work authorizations shot up 32 percent in the first nine months of 2011 compared with the corresponding period in 2010. Americans have led the way, with 7,550 receiving work permits in 2010. In addition, 2 million Brazilians who had been living overseas have returned home since 2005.

“While there is crisis in other countries, we have this phenomenon developing here,” Abrao said. “Employment levels are high, and countries that normally were the destination for Brazilians, like Portugal, the United States and Spain, are now sending people to Brazil.”

Those arriving here clearly have an adventurous streak. But they also made their decision based on pragmatic considerations: Brazil is an emerging economic power whose economy has grown by 4.4 percent a year since 2004. It has also received about $200 billion in foreign direct investment in the past six years.

And despite the formidable red tape for foreign workers, this country of 194 million has an increasingly diverse economy with room for those in finance, engineering, Web design, petro-engineering and other highly technical professions.

“When you’re talking about skilled labor, there’s a huge lack of supply, so as a result if you have the courage to come down to Brazil, or you have the language skills, or you’re Brazilian American, it’s a no-brainer to come down here,” said Rosenthal, 31, who runs Newfoundland Capital Management with a Brazilian partner.

In New York, Rosenthal had a golden career. At 22 he joined Morgan Stanley, and he later worked for one of Julian Robertson’s Tiger Cub funds. But the culture of New York’s financial world can be stiff and closed, Rosenthal said, and he was attracted by the investment possibilities in Brazil and neighboring countries.

Here, Rosenthal said he runs into the executives of big firms at the gym, and he is a cab ride away from 80 percent of the firms on the Sao Paulo exchange. “Those interactions are priceless,” he said. “You don’t get that in New York.”

And then there is the music, the spicy cuisine of northeastern Brazil and the ingenious soccer of the nearby team in Santos, which has had to replace Rosenthal’s beloved New York Jets.

‘Everything was about crisis’

Brazil has always attracted outsiders with its beaches, sultry samba and continental proportions. Poor immigrants from Italy, Spain, Portugal and Germany came by the boatloads for decades. In the 1950s, the glitz and striking beauty of Rio de Janeiro’s Copacabana attracted Hollywood stars and musicians. More recently, Brazil has been a magnet for low-skilled labor from poorer, neighboring countries.

But in recent years, Brazil also has beckoned people like Stephane Rogeau, 36, a Parisian who had sold software in the defense industry and decided his best career move would be to come here and get an MBA.

“I could see the news,” he recalled as he and his Brazilian girlfriend moved into their new apartment. “This company would be firing 2,000 people and that company would be closing. So I thought, it’s not the best time to be looking for a job.”

A fellow Frenchman, Franck Turquet, 28, recalled how in Europe “everything was about crisis, the social crisis, the economic crisis, the identity crisis.” He is now living near the beach in Rio de Janeiro and is engaged to a Brazilian woman. “My life here is really nice,” he said.

Not all, of course, is rosy. The economy has cooled in recent months, a byproduct of the global economic crisis, and growth is expected to reach only 3.5 percent this year, according to Itau, Brazil’s biggest bank. The stock market has been performing poorly lately, and President Dilma Rousseff is hamstrung in her efforts to push through economic reforms.

Still, the economic output is an improvement over Europe and the United States, and unemployment has fallen to just above 5 percent. Sectors such as oil and construction are expected to remain buoyant. The possibilities in upper-echelon jobs, the place for foreigners with sterling qualifications, remain promising.

Indeed, salaries in high-end jobs can often top those of New York or Paris, said Edmar Perfetto, a partner at the international auditing firm PwC, adding that 80 percent of foreign multinationals have operations in Brazil.

General Electric, with operations in 100 countries, moved its Latin American headquarters from Mexico to Sao Paulo, went from 7,000 to 8,000 employees in Brazil last year and is going to open a regional center for management training in Rio de Janeiro. Paul Fama, an American who is the senior human resources manager for GE here and a newcomer to Brazil, said the company has managers from several Latin American countries.

“That kind of diversity breeds better ideas,” Fama said.

A strong demand

In Belo Horizonte, 360 miles northeast of Sao Paulo, Google has actively sought engineers for its research unit. Of the 100 engineers whom engineering director Berthier Ribeiro-Neto oversees, about 10 percent are foreigners — from the Netherlands, France, Germany, India and other Latin American countries.

“The economy is growing faster than the university engineering departments in the country,” Ribeiro-Neto quipped.

One vital job was filled by Olivier Teboul, 28, a Frenchman who arrived a few months ago. He had finished a doctorate in applied mathematics in Paris and, on a whim, applied at Google in Brazil. “Being in a country which is growing and offering very attractive positions — you know, I didn’t have to think too much about it,” he said.

Other foreigners here, like David Bailey, a Briton who lives in a Rio apartment with three other Europeans, are joining the growing world of Internet startups.

He is launching a Web site called the Flying Fork that permits diners to order takeout food online. The number of restaurants in Brazil that deliver food has doubled to 50,000 since 2005, Bailey said, a clear sign that Rio is ready for his initiative.

Bailey, 28, who is also a musician, said Brazil offers both a rich culture and business possibilities.

“It’s a really fun place to live, it’s sunny, it’s a place where there’s a strong culture of music, of going to the beach, having fun,” he said. “And on the other hand, it’s a place — one of the few places, actually — where the economy is growing and there are significant opportunities.”