Forum archive 2000-2006

Michael Gage - inv_romberg

Michael Gage - inv_romberg

by Arnold Pizer -
Number of replies: 0
inactiveTopicinv_romberg topic started 8/28/2001; 8:18:46 PM
last post 8/28/2001; 8:18:46 PM
userMichael Gage - inv_romberg  blueArrow
8/28/2001; 8:18:46 PM (reads: 1845, responses: 0)

inv_romberg

Syntax
$right_hand_endpoint = inv_romberg($rf_func, $left_hand_endpoint, $value) ;

Params

$rf_func refers to a subroutine of one variable defining the function.
$left_hand_endpoint is the left hand endpoint of the integral.
$value is the desired value for the integral.

Returns

A number representing the right hand endpoint of the interval whose definite integral has the desired value.

Examples

$b = inv_romberg(sub { my $x=shift; (1/sqrt($PI) )*exp(-$x**2); }, 0, 1/4);
# find the upper limit b so that the area under the normal distribution on the inteval between 0 and b is 1/4.

Notes

Can be used, for example, to find intervals under a normal distribution curve that have a desired value. Used in many statistics problems.

See Also

trapezoid, romberg

 

<| Post or View Comments |>