How to do integral in stan

Take a look at: PDA in Stan?

Maybe in the next release or the other we will also have https://github.com/stan-dev/math/pull/566