integrate_expcubic: Integration of an Exponential-Cubic Function

View source: R/integrate_expcubic.R

integrate_expcubicR Documentation

Integration of an Exponential-Cubic Function

Description

Integrates a function of the form \exp(a*x^3+b*x^2+c*x+d) over an interval.

Usage

integrate_expcubic(a, b, c, d, lower, upper, minus_const = 0)

Arguments

a, b, c, d

The coefficients of x^3, x^2, x, and the constant term, respectively.

lower, upper

Numeric values to specify the limits of integration.

minus_const

A numeric to be subtracted in the exponent to ensure the finite-ness of the integration result. Default is 0.

Value

A numeric of the integral of \exp(a*x^3+b*x^2+c*x+d) from lower to upper.

Examples

integrate_expcubic(a = 1, b = -2, c = 3, d = -2, lower = -2, upper = 2)


zhoucx1119/LogConcaveDESM documentation built on Aug. 28, 2024, 3:25 p.m.