The most compact algorithm for Simpson's rule??
|
12-14-2015, 09:04 PM
Post: #12
|
|||
|
|||
RE: The most compact algorithm for Simpson's rule??
(12-12-2015 11:02 PM)Namir Wrote: This is a slightly different version based on one of Dieter's remarks. I still don't get why you want to compute f(b) twice and generate an additional function call that is not required. Why don't you do it the classic way? Code: h = (b - a) / n If you want to count down to n=0 simply add another n=n-1 on top of the do loop. Dieter |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 2 Guest(s)