Results 1 to 5 of 5
Like Tree2Thanks
  • 1 Post By Idea
  • 1 Post By SlipEternal

Thread: trapezium rule question

  1. #1
    Member
    Joined
    May 2009
    Posts
    243
    Thanks
    3

    trapezium rule question

    Hi folks,


    This one looks easy, but I'm not getting there.


    The integral $ \int_{0}^{1} e^x dx$ is approximated using the trapezium rule, dividing the range into intervals of length h = 1/n.


    Show that the result is $\dfrac{(e - 1)(p + 1)}{2n (p - 1)}$ where $p = e^h$ ..................................(1)


    so the ordinates are:


    \( \begin{array}{llllllll}


    x & 0 & 1/n & 2/n & 3/n & ... & n-1/n & 1 \\


    & & & & & & & \\


    f(x) & 1 & e^\frac{1}{n} & e^\frac{2}{n} & e^\frac{3}{n} & ... & e^\frac{n-1}{n} & e


    \end{array} \)


    for a range between 0 and 1 a single interval (slice) is 1/n = h


    the trapezium rule is


    $A = h/2 \; (y_{0} + y_{n} + 2 (y_{1} + y_{2} + y_{3} \; ... \; y_{n-1} ) )$


    so


    $A = 1/2n \; (1 + e + 2(e^\frac{1}{n} + e^\frac{2}{n} + e^\frac{3}{n} + \; ... \; + e^\frac{n-1}{n}) )$


    there are n - 1 terms in the series (after the 2).


    Since $a \frac{m}{n} = \sqrt[n] {a^m}$ where a, m and n are constants.


    $A = 1/2n \; (1 + e + 2e^\frac{1}{n} (e + e^2 + e^3 + ... + e^{n-1} ) )$ .....................................(2)


    so, we have a geometric progression with n - 1 terms. The sum of this series is given by $S_{n} = b \frac{r^n - 1}{r - 1}$ for $r \ge 1$. Where b is the first term and r the common ratio.
    In our case b = e and r = e.


    $S_{n} - S_{n - 1} = b. r^{n - 1} = e^n$


    so


    $S_{n-1} = \dfrac{e(e^n - 1)}{e - 1} - e^n = \dfrac {e^n - e}{e - 1} $


    put this back into (2)


    $A = 1/2n \; (1 + e + 2 e^\frac{1}{n} \frac {e^n - e}{e - 1} )$ and we have $p = e^h = e^\frac{1}{n} $


    Now, I was hoping some straightforward algebra would get me to (1) but I cannot get this into the form required.

    Can anyone help?
    Last edited by s_ingram; May 31st 2018 at 03:54 AM.
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Super Member
    Joined
    Jun 2013
    From
    Lebanon
    Posts
    833
    Thanks
    383

    Re: trapezium rule question

    $\displaystyle A=\frac{1}{2n}\left(1+e+2\left(e^{1/n}+e^{2/n}+\text{...}+e^{(n-1)/n}\right)\right)$

    replace $\displaystyle p=e^{1/n}$ to get

    $\displaystyle A=\frac{1}{2n}\left(1+e+2\sum _{k=1}^{n-1} p^k\right)$

    use the geometric sequence sum formula and note that $\displaystyle p^n=e$
    Thanks from s_ingram
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Member
    Joined
    May 2009
    Posts
    243
    Thanks
    3

    Re: trapezium rule question

    That's pretty well what I was doing.

    Have I got sequence sum correct? $\dfrac{e^n - e}{e - 1}$?

    I end up with $\dfrac{e^2 - 1 + 2(e^n - p^n)}{e - 1}$ which is nothing like equation (1)
    Follow Math Help Forum on Facebook and Google+

  4. #4
    MHF Contributor
    Joined
    Nov 2010
    Posts
    3,455
    Thanks
    1368

    Re: trapezium rule question

    Quote Originally Posted by s_ingram View Post
    That's pretty well what I was doing.

    Have I got sequence sum correct? $\dfrac{e^n - e}{e - 1}$?

    I end up with $\dfrac{e^2 - 1 + 2(e^n - p^n)}{e - 1}$ which is nothing like equation (1)
    $e^{1/n}+e^{2/n}+\cdots +e^{(n-1)/n} \neq e^{1/n}\left(e+e^2+\cdots +e^{n-1}\right)$

    Factoring is subtraction in the exponents, not division. That is why Idea recommended that you use $p=e^{1/n}$ instead.

    $\displaystyle \begin{align*}\dfrac{1}{2n}\left(1+e+2\sum_{k=1}^{ n-1}p^k\right) & = \dfrac{1}{2n}\left(1+e+2p\sum_{k=0}^{n-2}p^k\right) \\ & = \dfrac{1}{2n}\left(1+e+2p\dfrac{p^{n-1}-1}{p-1}\right) \\ & = \dfrac{1}{2n}\left(\dfrac{(1+e)(p-1)+2(e-p)}{p-1}\right) \\ & = \dfrac{1}{2n}\left( \dfrac{p+ep-e-1+2e-2p}{p-1} \right) \\ & = \dfrac{1}{2n}\left( \dfrac{(e-1)(1+p)}{p-1}\right)\end{align*}$

    Just as you want.
    Thanks from s_ingram
    Follow Math Help Forum on Facebook and Google+

  5. #5
    Member
    Joined
    May 2009
    Posts
    243
    Thanks
    3

    Re: trapezium rule question

    many thanks.
    The error was, as you say, me thinking $e^\frac{5}{3} = e^\frac{1}{3}.e^5$ In my post I even quoted the reason I thought this was true. But $e^\frac{5}{3} = (e^\frac{1}{3})^5$ is not the same thing. When I saw Idea's post, I thought I was doing what he said! Glad that's sorted.
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Trapezium rule
    Posted in the Calculus Forum
    Replies: 2
    Last Post: Sep 9th 2011, 10:30 PM
  2. The trapezium rule
    Posted in the Calculus Forum
    Replies: 4
    Last Post: May 12th 2011, 05:27 AM
  3. Trapezium Rule
    Posted in the Calculus Forum
    Replies: 4
    Last Post: Nov 14th 2010, 10:24 AM
  4. Trapezium Rule
    Posted in the Calculus Forum
    Replies: 1
    Last Post: Nov 8th 2010, 11:33 PM
  5. Integration/trapezium rule
    Posted in the Calculus Forum
    Replies: 3
    Last Post: May 24th 2010, 03:10 AM

/mathhelpforum @mathhelpforum