- #1
fahraynk
- 186
- 6
I have a system of equations, and one of them is this : ##\int(1-U(y))Dy - H*\int(U(y)-U(y)^2)dy=0##
Can Newtons method work if I approximate this integral to be ##\sum_y(1-U(y))-H\sum(U(y)-U(y)^2)=0##
y is a set integers in range ##[1,1000]##
I have Newtons method working for this same system without this equation, but I am trying to solve for a new variable (a), so I added this equation and changed (a) from a constant to a new variable, but Newtons method no longer converges.
Could this be because I am using rectangle left rule to approximate the integral, and maybe rectangle left has too much error for Newtons method to work?
The other thing I can try is to take the derivative of both sides giving this equation ##1-U(y)-H(U(y)-U(y)^2=0##
The only problem with this is I would have to add this equation to every point on a grid, meaning it would be 1000 new equations for 1000 grid points instead of 1 equation. I would have to rewrite the whole algorithm, so I would rather use rectangle left rule if possible because it is much less coding.
Anyway, yeah, will Newtons method work with rectangle left rule like this?
Can Newtons method work if I approximate this integral to be ##\sum_y(1-U(y))-H\sum(U(y)-U(y)^2)=0##
y is a set integers in range ##[1,1000]##
I have Newtons method working for this same system without this equation, but I am trying to solve for a new variable (a), so I added this equation and changed (a) from a constant to a new variable, but Newtons method no longer converges.
Could this be because I am using rectangle left rule to approximate the integral, and maybe rectangle left has too much error for Newtons method to work?
The other thing I can try is to take the derivative of both sides giving this equation ##1-U(y)-H(U(y)-U(y)^2=0##
The only problem with this is I would have to add this equation to every point on a grid, meaning it would be 1000 new equations for 1000 grid points instead of 1 equation. I would have to rewrite the whole algorithm, so I would rather use rectangle left rule if possible because it is much less coding.
Anyway, yeah, will Newtons method work with rectangle left rule like this?