Math 309 Extra-Credit

Posted bizhui

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Math 309 Extra-Credit相关的知识,希望对你有一定的参考价值。


Math 309 Extra-Credit Project 4 Fall, 2019
The amount of extra-credit will depend on the overall quality of your work. You
must submit a formal Report to show your work. The Report must be typed
and if possible prepare the Report with RMarkdown and submit both the .Rmd
file and the .html files. It is essential that you include proper comments in
your R script so the read can easily read and understand the code lines. I do
expect mathematical expressions, tables, plots, with proper explanations, interpretations,
and meaning summary of your work in the report. A work with
just plugging in numbers and plain numerical answers will get very little credit
or no extra credit at all. You must work independently and require to comply
with the university policy on academic integrity found in the Code of Student
Conduct found at
http://www.lehigh.edu/lts/official/Academic_Integrity_Vignettes.pdf.
1. (a) Show how to use Monte Carlo techniques to approximate the following
sum.∑∞k=0
cos(cos(k))/k!
(b) Use R to implement the Monte Carlo approximation of the sum in
part (a); use at least 10,000 runs.
(c) Show how to use Monte Carlo techniques to approximate the following
integration.
∫ π0cos(x/2)sin(2x)dx
(d) Use R to implement the Monte Carlo approximation of the integration
in part (c); use at least 10,000 runs.
2. (a) Show how to use Monte Carlo techniques to approximate the following
double integration.
(b) Use R to implement the Monte Carlo approximation of the double
integration in part (a); use at least 10,000 runs.
3. Let f(x) = 4/(π(1 + x2)), 0 ≤ x ≤ 1. (a) Explain how can we use the
acceptance-rejection method to generate sample from this distribution.
(b) Use R to implement the proposed algorithm in (a).
(c) Obtain the relative-frequency histogram and overly the true pdf on it.
4. We want to use the acceptance-rejection method to generate continuous
random variable X from a distribution with probability density function
f(x) = (m+n+1)!m!n!
xn(1 − x)
m for 0 ≤ x ≤ 1, n ≥ 1, n ≥ 1 and are integers;
and f(x) is zero otherwise. Suppose we use the pdf of Uniform(0,1) as the
proposal pdf (i.e., g(x) = 1, for 0 ≤ x ≤ 1).
(a) Find an appropriate constant c > 1 (i.e., as small as possible) such
that f(x)/(cg(x)) < 1 for 0 ≤ x ≤ 1.
(b) For n = m = 2, carry out the simulation with at least 5,000 runs.
Find the theoretical values of E(X) and V ar(X) and then compare with
their simulated values.
(c) Obtain the relative-frequency histogram of the simulated values; then
overlay the theoretical pdf.
(d) Repeat (b) and (c) for m = 2 and n = 4.

因为专业,所以值得信赖。如有需要,请加QQ99515681  微信:codehelp

以上是关于Math 309 Extra-Credit的主要内容,如果未能解决你的问题,请参考以下文章

cf Round #309 (Div. 2) E - Love Triangles(二分图染色)

053-309

309.最佳买卖股票时机含冷冻期

309.最佳买卖股票时机含冷冻期

LeetCode笔记:Weekly Contest 309

LeetCode笔记:Weekly Contest 309