Chris Smith posted a very short implementation of a cse->Jacobian->cse'd Jacobian here:
https://stackoverflow.com/questions/79591252/do-not-expand-sub-expressions-until-required/79593030#79593030
If this works generally, we could see if it is faster than ours.
Chris Smith posted a very short implementation of a cse->Jacobian->cse'd Jacobian here:
https://stackoverflow.com/questions/79591252/do-not-expand-sub-expressions-until-required/79593030#79593030
If this works generally, we could see if it is faster than ours.