Mr. Panetta came to India in hopes of further strengthening the military relationship between India and the United States. But India has long been less enthusiastic than the Americans about closer ties, in part because of worries that such bonds would anger the Chinese, who, like the Pakistanis, also share a disputed border with India.

“Today, we have growing economic, social and diplomatic ties that benefit both of our nations, but for this relationship to truly provide security for this region and for the world, we will need to deepen our defense and security cooperation,” Mr. Panetta said. “This is why I have come to India.”

Mr. Panetta is near the end of a swing through Asia during which he has promised to enhance the American military’s presence in the region despite budget constraints at home. This will be accomplished in part by increasing the share of Navy ships in the Pacific Ocean while lowering them in the Atlantic, he said. On Thursday, he arrived in Afghanistan, The Associated Press reported.

The change is widely seen as an attempt to check China’s growing clout and posturing in the region. The United States sees India as a crucial partner in that effort.

On Tuesday, Mr. Panetta held what the Americans described as “productive meetings” with Prime Minister Manmohan Singh and Shivshankar Menon, the national security adviser. In his speech on Wednesday, Mr. Panetta said that when he worked for President Bill Clinton in the 1990s, the relationship between the two countries was strained. But he noted that President Obama had called the American relationship with India one of the defining partnerships of the 21st century.

“We will expand our military partnerships and our presence in the arc extending from the Western Pacific and East Asia into the Indian Ocean region and South Asia,” Mr. Panetta said. “Defense cooperation with India is a linchpin in this strategy.”