For all the gory details on the C++ and derivatives, see:
http://arxiv.org/abs/1509.07164
The in-between solution for external libraries without gradients
is to template out the scalar type. But if you have gradients,
then you want the above. Sorry it's so long --- you only need
the first bit on how to write simple functions.
For the interfacing with Stan itself, see:
https://github.com/stan-dev/stan/wiki/Contributing-New-Functions-to-Stan
It explains where things have to go in the symbol table to be
picked up by the Stan parser.
One of our to-do items for next year is making Stan extensible at
run time, which should be possible given that it's header only.
- Bob
> --
> You received this message because you are subscribed to the Google Groups "Stan users mailing list" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
stan-users+...@googlegroups.com.
> To post to this group, send email to
stan-...@googlegroups.com.
> For more options, visit
https://groups.google.com/d/optout.