Engineers from companies led by Elon Musk, the billionaire known for outside-the-box ideas like his aspiration to colonize Mars, were en route to Thailand on Saturday to offer their expertise to help rescue 12 boys and their soccer coach from the Tham Luang cave in northern Thailand.

The engineers were sent from Tesla, Mr. Musk’s electric vehicle company; SpaceX, his rocket company; and the Boring Company, which specializes in tunneling and construction, a Boring Company spokesman said.

There are two or three engineers on the ground in Thailand, with more on the way, the spokesman said. He said representatives from the companies were in discussions with the Thai government about how they could help.

Divers began a rescue mission on Sunday morning that could continue for several days, said its commander, Narongsak Osottanakorn.