WASHINGTON — The commander of American forces in the Pacific has ordered an aircraft carrier and several other warships toward the Korean Peninsula in a show of force by the Trump administration just days after North Korea tested another intermediate-range missile.

The officer, Adm. Harry B. Harris Jr., the head of the military’s Pacific Command, diverted the aircraft carrier Carl Vinson and its wing of fighter jets from a planned series of exercises and port calls in Australia, the command said in a statement. The Vinson and three guided-missile destroyers and cruisers steamed out of Singapore on Saturday for their new mission in the Western Pacific.

Rerouting the naval armada is President Trump’s latest escalation in force against a potential adversary. Mr. Trump ordered a cruise missile strike last week against a Syrian military air base in retaliation for a chemical weapons attack by the Syrian government that killed scores of civilians.

At a meeting last week at Mr. Trump’s Mar-a-Lago resort in Florida, he joined with President Xi Jinping of China in warning of the increasing menace posed by North Korea’s advancing nuclear weapons program. Asked on Sunday why the Navy ships were being redirected toward the Korean Peninsula, the president’s national security adviser, Lt. Gen. H. R. McMaster, said it was a “prudent” step to take.