If the price is a second, then it is not a crazy idea. Especially since he has some ability to score and the Celtics bench unit, well, doesn't. A flyer on him wouldn't necessarily be a bad thing.
To do it without the DPE, they would need to send at least $3.92 million back. That's possible, but seems unwise.
They could send Morris ($5 MM), but that doesn't seem like a move that would help them. And Philly may not want to add Morris' contract for next year. They aren't sending Baynes (4.3 MM).
That leaves them combining salaries. But they aren't going to send Theis ($0.815 MM). Ojeleye ($1.29 MM), or Rozier ($1.99 MM) in an Okafor deal.
That leaves 3 players: Yabusele ($2.25), Larkin ($1.47 MM), and Nader ($1.17 MM). All 3 of them would have to be included in an Okafor deal, and that would bring them down to 11 healthy players. I suppose they could sign Jabari Bird and he might even be an improvement on Nader. And maybe if they can bring in a decent backup PG with the DPE deal, it would all work. But you are still dealing a 2nd, a useful deep bench role player, and a project type prospect for Okafor. Not sure it makes sense (or if Philly would even want Yabu et al).
But taking him in via the DPE would not be a bad idea at all. In effect, the $8.4 MM DPE is replaced by Okafor's $4.95 MM salary. But you get more than a flyer on a highly drafted player who has struggled - you also get the chance to ship him out in a deadline deal.
Package Okafor with Morris and draft pick(s) at the deadline, and they can take back $12.5 MM in salary. Throw in Larkin, Yabusele, and Nader, and they can take back $18.5 million in salary.
It's not crazy to think that if Okafor comes here and continues to be a bust (not unlikely), they can still get some value out of including him in a deal.