% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/exp_series.R
\name{exp_series}
\alias{exp_series}
\alias{surv.exp_series}
\alias{sampler.exp_series}
\alias{mean.exp_series}
\alias{density.exp_series}
\alias{hazard.exp_series}
\title{Series of exponential components (closed form)}
\usage{
exp_series(rates)

\method{surv}{exp_series}(x, ...)

\method{sampler}{exp_series}(x, ...)

\method{mean}{exp_series}(x, ...)

\method{density}{exp_series}(x, ...)

\method{hazard}{exp_series}(x, ...)
}
\arguments{
\item{rates}{Positive numeric vector of length \code{m}: per-component
exponential rates.}

\item{x}{An \code{exp_series} object.}

\item{...}{Ignored.}
}
\value{
\code{exp_series()} returns an object of class
\code{c("exp_series", "series_dist", "coherent_dist", "dist_structure", "univariate_dist", "continuous_dist", "dist")}.

The associated S3 methods return:
\itemize{
\item \code{surv()}, \code{density()}, \code{hazard()}: a closure \verb{function(t, ...)}
evaluating the named quantity at \code{t}.
\item \code{cdf()} is derived via the \code{dist_structure} default and returns
a closure \verb{function(t, ...)} equal to \code{1 - surv(x)(t)}.
\item \code{sampler()}: a closure \verb{function(n, ...)} returning \code{n} random
variates from the system lifetime distribution.
\item \code{mean()}: a numeric scalar (the mean system lifetime).
}
}
\description{
Constructs a \code{dist_structure} representing a series system whose
components are independent exponentials. The system lifetime is itself
an \code{Exp(sum(rates))} distribution; all dist-level queries have
closed-form expressions that bypass the general default methods.
}
\examples{
sys <- exp_series(c(0.5, 0.3, 0.2))
algebraic.dist::surv(sys)(1)  # equals exp(-sum(rates) * 1)
mean(sys)                     # equals 1 / sum(rates)
}
