(38G) Simpson's Rule
|
11-01-2019, 01:41 PM
Post: #1
|
|||
|
|||
(38G) Simpson's Rule
An excerpt from Appendix E: Graphing Utility Programs, Applied Calculus 6e (Larson);
Programs for graphing calculators are referenced in several sections in the text. This appendix contains translations of these programs for the TI-82, TI-83, TI-85, TI-86, TI-89, TI-92, Casio CFX-9850G, HP 38G, and Sharp EL 9200/9300, arranged by calculator model. Similar programs can be written for other brands and models of graphing calculators. Enter a program in your calculator, then refer to the text discussion and apply the program as appropriate. Simpson's Rule This program uses Simpson's Rule to approximate the definite integral a∫b ƒ(x) dx. Enter both programs into the calculator. Store the expression ƒ(x) dx in the F1 function in the Function aplet. Be sure F1 is checked. The program itself will prompt you for the limits a and b and for half the number of subintervals you want to use. SIMPSON PROGRAM INPUT A;“ENTER LOWER LIMIT”; “ENTER A”;“ ”; 1: INPUT B;“ENTER UPPER LIMIT”; “ENTER B”;“ ”; 1: INPUT D;“N/2 DIVISIONS”; “ENTER D”; “ ”; 1: 0►S: (B-A)/(2D)►W: 1►J: WHILE J≤D REPEAT RUN “SIMPSONLOOP” END: ERASE: DISP 3; “APPROXIMATION”: DISP 5; S: FREEZE: SIMPSONLOOP PROGRAM A+2*(J-1)*W►L: A+2J*W►R: (L+R)/2►M: L►X: F1(X)►L: M►X: F1(X)►M: R►X: F1(X)►R: W*(L+4M+R)/3+S►S: J+1►J BEST! SlideRule |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)