home *** CD-ROM | disk | FTP | other *** search
- 10 CLEAR SCREEN
- 20 LOADSUB ALL FROM "..\mathlib\Mathlib.hts"
- 30 REAL A(8) ! holds nine values
- 40! Build array where x goes from 1 to 3 step .25
- 50 INTEGER Loop
- 60 FOR Loop=0 TO 8
- 70 A(Loop)=(1+.25*(Loop))^4 ! put the x^4 value in a(Loop)
- 80 NEXT Loop
- 90 ! Display
- 100 S=.25
- 110 PRINT "Integration using the Trapezoid Rule."
- 120 PRINT "Function (x^4) to intigrate from 1 to 3"
- 130 PRINT "The aproximated answer is";FNTrapezoid(A(*),S)
- 140 DELSUB FNAi TO END
- 150 END
-