simp_int: The Simpson method to compute integral

Description Usage Arguments Value Author(s) Examples

Description

This function computes the Simpson method to calculate an integral.

Usage

1
simp_int(x, fx, n.pts = 256, ret = FALSE)

Arguments

x

The vector where the integral is computed

fx

The function to integrate

n.pts

The number of points used to compute the integral through the Simpson technique.

ret

A boolean control parameter. Default value is FALSE.

Value

Returns the value of the integral.

Author(s)

W. E. Wansouwé, F.G. Libengué and C. C. Kokonendji

Examples

1
2
3
Vec=rgamma(100,1.5,2.6)
x=seq(min(Vec),max(Vec),length.out=100)
simp_int(x,dgamma(x,1.5,2.6))

Conake documentation built on May 2, 2019, 2:07 a.m.