Setting up Newton Raphson integral with matlab

  • MATLAB
  • Thread starter Moly
  • Start date
  • #1
Moly
21
0
Hi All.

I have an equation that i want to numerically find the root of by using Newton Raphson. However the equation involves an integral which i am using the trapazoidal rule to evaluate. And here is the simplified version of it:
[tex] 1 = e^{-cy} \int_0^1 e^{-y(1-x)} dx [/tex]

So i am supposed to integrate for x and then solve the resulting equation for values of y. How do i do that??

If i just wanted to do the integration, i would have used "syms" and found the result in terms of y... but i am totally stumped with this... please... SOS!
 

Answers and Replies

  • #2
Gib Z
Homework Helper
3,352
7
Well, look inside the integral. The variable is x, y is a constant inside the integral. We can easily solve that integral exactly, no need to approximate that integral.

After that, you will have on the RHS some exponential terms divided by y, which is easy to apply Newtons Method to.
 
  • #3
Moly
21
0
Thanks Gib.
I figured where i went wrong.. i still have a question that i will post later today
 

Suggested for: Setting up Newton Raphson integral with matlab

  • Last Post
Replies
6
Views
122
  • Last Post
Replies
4
Views
219
  • Last Post
Replies
2
Views
651
Replies
1
Views
738
  • Last Post
Replies
2
Views
623
Replies
1
Views
2K
  • Last Post
Replies
2
Views
761
  • Last Post
Replies
1
Views
649
Replies
1
Views
455
Replies
10
Views
1K
Top