% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/chapter14_multiple_decrement.R
\name{Pbar_trapz_ms}
\alias{Pbar_trapz_ms}
\title{Continuous premium approximation in a disability model}
\usage{
Pbar_trapz_ms(t, tp00, tp01, delta, mu02, mu12, B02 = 1, B12 = 1, R = 0)
}
\arguments{
\item{t}{Strictly increasing nonnegative time points.}

\item{tp00}{Healthy-state probabilities.}

\item{tp01}{Disabled-state probabilities.}

\item{delta}{Force of interest.}

\item{mu02}{Healthy-to-deceased intensity function.}

\item{mu12}{Disabled-to-deceased intensity function.}

\item{B02}{Benefit on death while healthy.}

\item{B12}{Benefit on death while disabled.}

\item{R}{Continuous disability income rate.}
}
\value{
A numeric scalar.
}
\description{
Approximates a continuous premium rate by trapezoidal integration.
}
\examples{
mu01 <- function(t) 0.10 * t + 0.20
mu02 <- function(t) 0.20
mu10 <- function(t) 0.50
mu12 <- function(t) 0.125 * t + 0.20

probs <- tp00_tp01_euler(
  h = 0.10,
  n = 2,
  mu01 = mu01,
  mu02 = mu02,
  mu10 = mu10,
  mu12 = mu12
)

Pbar_trapz_ms(
  t = probs$t,
  tp00 = probs$tp00,
  tp01 = probs$tp01,
  delta = 0.04,
  mu02 = mu02,
  mu12 = mu12,
  B02 = 1000,
  B12 = 1000,
  R = 1000
)

}
