Tesla and SpaceX CEO Elon Musk. Tesla During the 2016 presidential election, Elon Musk was no fan of Donald Trump — the Tesla and SpaceX CEO didn't think the celebrity businessman was the right guy for the job.

But now that President Trump has the job, Musk has shifted his views. He's joined Trump's council of business advisors and also has become a member of a Trump administration initiative to create more US manufacturing jobs.

I don't think there are two brains more un-alike that Musk's and Trump's on planet Earth. Adding to all this is Musk's endorsement of former ExxonMobil CEO Rex Tillerson as Secretary of State — a stunning development given Musk's ardent belief that global warming is an existential threat and that humanity needs to exit the fossil-fuel era as quickly as possible.

So what gives?

A visionary who also has to be a businessman

It's important to remember that Musk runs two companies (and really three, given Tesla's 2016 acquisition of struggling SolarCity) that have been highly dependent on the US government for everything from Department of Energy loan guarantees back when Tesla was facing extinction in 2008-09 to SpaceX's billion-dollar-plus launch contracts with NASA.

Musk has often been dinged for this — often by right-leaning GOP and probably Trump supporters who thinks Musk lives off government handouts — but Musk hasn't sought to diminish the debt his companies owe to the American people. You could argue that he's now going about paying it back, in a Trump-friendly manner, by increasing his US-based manufacturing operations at Tesla and SpaceX, including the construction of a massive battery factory in Nevada.

Musk could be hiring tens of thousands of American workers over the next decade. He could build numerous factories. He could colonize Mars and create vast new opportunities to construct Red Planet casinos, golf courses, and gilded human habitats for the Trump Organization.

Seriously, Musk is by nature a visionary who also has to function as a businessman, which I quite honestly think isn't second-nature to him. Instead, he operates opportunistically, and in Trump and possibly even more so Tillerson he sees a very big opportunity, once that he's already enhanced by gaining White House access.

Rex Tillerson could be a Musk carbon-tax ally. REUTERS/Mike Stone/File Photo

'The unpriced externality'

With Tillerson, Musk has clearly found a person who can pressure Trump on a carbon tax, something that Musk called for in late 2015, during a speech at the Sorbonne in Paris.

"We have to fix the unpriced externality," he said, pointing out that pollution is classic negative externality in economic terms that causes harm to all, but cost to none. He called it a "hidden carbon subsidy of $5.3 trillion per year."

Tillerson supported a revenue-neutral carbon tax when he was at ExxonMobil as the best way to de-incentivize carbon generation. Economist and policymakers often agree, but some also think a carbon market would be a more effective means to halting global warming.

So with Musk, in the first order, we have a connect-the-dots between his reversal of sorts on Trump and his enthusiasm for Tillerson.

Going to Mars? Elon Musk/SpaceX/Flickr (public domain)

Secondarily, Musk knows that Tesla — and to a lesser degree SpaceX — can give Trump winning headlines about jobs, although detrimentally for Trump they would be jobs in California and Nevada rather than in Ohio or Pennsylvania (SolarCity operations are another story, as the company is now doing business in Buffalo, NY). For Trump, that's a priceless externality and his administration may be willing to reward Musk copiously, with everything from tax breaks to environmental regulations.

Finally, as many have pointed out, if Trump wants to give a speech about going to Mars and become a terra-cotta-tinged JFK, Musk will be more than happy to see his and SpaceX's stock rise with NASA, where although SpaceX is a customer, it's now confined to low-Earth orbits, leaving the deep-space fun to the guys who went to the Moon.

Outdealing the deal king

Musk has now joined the auto industry in quickly figuring out that Trump cares more about his brand than he does about the specifics of any deal — regardless of his fading reputation as the greatest dealmaker of all time.

Car companies are thrilled about Trump's plans to cut corporate taxes and roll back fuel-economy regulations, and their excitement has been dampened by the threat of a border tax on imported cars and parts (they'll just haggle over the specifics while they swell their balance sheets and continue building highly profitable pickups and SUVs).

To appease Trump, they'll invest some millions and hire at the margins in the US, while hedging against an inevitable sales downturn. The President gets the headlines, and they the get the sweet deal.

Likewise, Musk sees the best chance he's ever likely to have to get his carbon tax. And he knows that he was going to hire potentially tens of thousands of workers anyway, given that he has to fulfill almost 400,000 advance orders for Tesla's Model 3 mass-market vehicle and increase Tesla deliveries to 500,000 annually in less than two years. He already had the job-creating headlines, ready to go.

Trump with the CEO of GM, Mary Barra (L) and FCA, Sergio Marchionne (R). Getty Images

Give the CEOs what they want

I know this is going to sound cynical, but although Trump ran on being a business guy who would show the Washington political elites how it was done, he really hasn't been much of business force for a long time. And he's certainly no match for contemporary CEOs, especially the technologically sophisticated ones from Silicon Valley and the Big Kahunas from the multinational sphere, the crowd that Tillerson has run with.

Musk has always been a bit outside this framework because he truly is in it for the species — his companies are just a means to an end: saving the planet. But he knows how to grab his piece of the pie. He didn't secure NASA launch contracts and turn Tesla into a $40-billion-market-cap company because he's an amateur.

While he was doing that, Trump was hosting TV shows, peddling his brand around the globe, and exploiting the political prospects of conspiracy theories. Everything the new President did was spectacularly visible, of course, and that enabled him to undertake a hostile takeover of the US electorate, fueled by rage, mendacity, and heightened economic inequality, post-financial crisis, in the US.

So we're seeing what look like win-wins for Trump and the business world. In truth, they're ephemeral victories for the President and outright conquests for industries who priorities can rapidly dovetail with Trump's needs.

And for Musk, the possibilities are boundless. I'm not kidding: Mars is a two-year spaceflight away, on a SpaceX rocket. Tesla is already worth almost as much on paper as Ford, and Tesla only sold about 80,000 vehicles last year. Of course he's changed his tune on Trump. He can't lose.