It's very hard to do efficiently. And I'm not sure how we'd put
it in the language. But we can compute Jacobians with auto-diff
(just not very efficiently) and also log absolute determinants.
But there's not a good way to recognize triangular Jacobians and
save computation. Or a good way to separate out which Jacobians
are needed (only variables appearing on left of sampling statements).
In fact, we're going to have to do something like this for the
more sophisticated ODE solvers, where we integrate both the
original equations and their Jacobian (rather than auto-diffing
the integrator itself, which has issues with error bounds on
the Jacobians).
- Bob
>
stan-dev+u...@googlegroups.com <mailto:
stan-dev%2Bunsu...@googlegroups.com>.