This function calculates an approximation to the probability of ruin within a finite time horizon for a compound Poisson risk process that is perturbed by a Wiener process. The approximation makes use of saddlepoint methods.

1 2 | ```
ruinprob.finite.sdp(mgf, mgf.d1, mgf.d2, premium, freq, variance,
endpoint, verbose = FALSE)
``` |

`mgf` |
The moment-generating function of the individual claim amounts |

`mgf.d1` |
The first derivative of |

`mgf.d2` |
The second derivative of |

`premium` |
The premium force |

`freq` |
Frequency of the claims |

`variance` |
The variance of the Wiener process by which the risk process is perturbed |

`endpoint` |
The upper endpoint of |

`verbose` |
Return additional diagnostic information as an attribute of the output |

If neither or only the first derivative of `mgf`

is provided,
a numerical approximation to the missing derivative(s) will be used
instead (see grad and hessian).

The argument `endpoint`

is the (smallest) positive pole of
`mgf`

. Omitting this information will issue a warning and the value
1.0e+6 will be used instead, possibly yielding unexpected and unreliable
output or leading to further errors.

A function `psi(x, t)`

taking as inputs the initial capital `x`

and the time horizon `t`

. This function returns a list, the first
element of which contains a Lugannaniâ€“Rice-type approximation, the second
one contains a Skovgaard-type approximation.

Gatto, R. and Baumgartner, B. (2016) *Saddlepoint
approximations to the probability of ruin in finite time for the compound
Poisson risk process perturbed by diffusion*. Methodology and Computing in
Applied Probability **18**(1), pp. 217-235.

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

All documentation is copyright its authors; we didn't write any of that.