Question

In: Statistics and Probability

A mathematician requires the calculation of the integral y[n] = \int_0^1 x^n exp(-x) dx where \int_0^1...

A mathematician requires the calculation of the integral
y[n] = \int_0^1 x^n exp(-x) dx

where \int_0^1 means the integral with limits 0 and 1.


A) Using integration by parts, show that y[n] satisfies the recursion  y[n+1] = -1/e + (n+1) y[n]

B) Write a function that uses this recursion to calculate y[1:n] using R

@param n A postive integer
@return A vector of values y = c(y[1], ... , y[n])

Use this function to produce a vector y = c(y[1], ... , y[20]) in the object YInt

C) Recompute Yint using the pgamma and gamma functions in R.
Note that gamma(n+1)=factorial(n).

Solutions

Expert Solution

A)

B)

C)

Interestingly for n>16, the recursive approach is giving the wrong results.


Related Solutions

1) Evaluate the double integral ∬Dx^2 y dA, where D is the top half of the...
1) Evaluate the double integral ∬Dx^2 y dA, where D is the top half of the disc with center the origin and radius 2 by changing to polar coordinates. 2) Use a double integral to find the area of one loop of the rose r= 6cos (3θ). 3) Use polar coordinates to find the volume of the solid below the paraboloid z=50−2x^2−2y^2 and above the xy-plane.
Consider the definite integral ∫05 ((3x − 1)/(x + 2)) dx a. How large an n...
Consider the definite integral ∫05 ((3x − 1)/(x + 2)) dx a. How large an n do we need to use to approximate the value of the integral to within 0.001 using the Midpoint Rule? b. How large an n do we need to use to approximate the value of the integral to within 0.001 using Simpson’s Rule?
using / for integral Evaluate the double integral //R cos( (y-x)/(y+x) )dA where R is the...
using / for integral Evaluate the double integral //R cos( (y-x)/(y+x) )dA where R is the trapezoidal region with vertices (1,0), (2,0), (0,2), and (0,1)
Solve the following integral  ∫ (x^2 + x + 2) / (x + 1)(x^2 + 1) dx....
Solve the following integral  ∫ (x^2 + x + 2) / (x + 1)(x^2 + 1) dx. Use partial fraction decomposition. Show all work and steps to get to solution.
Given Fxy(x,y)=u(x)u(y)[1-Exp(-x/2)-Exp(-y/2)+Exp(-(x+y)/2)]. Note: The step functions mean that Fxy(x,y)=0 for either or both x<0 and y<0....
Given Fxy(x,y)=u(x)u(y)[1-Exp(-x/2)-Exp(-y/2)+Exp(-(x+y)/2)]. Note: The step functions mean that Fxy(x,y)=0 for either or both x<0 and y<0. Any x or y argument range below zero must be truncated at zero. Determine: a) P{X<=1,Y<=2} Ans: 0.2487 b) P{0.5<X<1.5} Ans: 0.3064 c) P{-1.5<X<=2, 1<Y<=3} Ans: 0.2423
setup the calculation for the arclength of f(x)=exp(x) for x €[0,1]
setup the calculation for the arclength of f(x)=exp(x) for x €[0,1]
Problem 7. Consider the line integral Z C y sin x dx − cos x dy....
Problem 7. Consider the line integral Z C y sin x dx − cos x dy. (Please show all work) a. Evaluate the line integral, assuming C is the line segment from (0, 1) to (π, −1). b. Show that the vector field F = is conservative, and find a potential function V (x, y). c. Evaluate the line integral where C is any path from (π, −1) to (0, 1).
Evaluate the integral. ∫4−2. (1/(x+5)((x^2)+16)) dx
Evaluate the integral. ∫4−2. (1/(x+5)((x^2)+16)) dx
Where y=y(x) solves... (5.9y-(23.6)x)dx+(5.9x-1)dy=0   y(0.27)=2.15 (5xy-(-1.1)ye^x -1)dx+(2.5x^2-(-1.1)e^x)dy=0     y(1.2)=2.3
Where y=y(x) solves... (5.9y-(23.6)x)dx+(5.9x-1)dy=0   y(0.27)=2.15 (5xy-(-1.1)ye^x -1)dx+(2.5x^2-(-1.1)e^x)dy=0     y(1.2)=2.3
Find the series solution of the following equation x(d^2y/dx^2+(1-x)dy/dx+ny=0. where n=0,1,2
Find the series solution of the following equation x(d^2y/dx^2+(1-x)dy/dx+ny=0. where n=0,1,2
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT