So, this program is useful if you are in "Advanced Math" or "Pre-Calculus", but it's not really useful anywhere else. Anyway, let's get right into it:
Create a new program and name it TRAPSUM (or something that you will remember it by)
Press prgm, go to the I/O tab, and select ClrHome. Start a new line by pressing enter
Press prgm, go to the I/O tab, and select Input
Type out "EXPRESSION: " and press comma
Press vars, go to String, and select Str1. Start a new line
Repeat step 3 and type "START: "
Press comma, type S, and start a new line
Repeat step 3 and type "END: "
Press comma, type E, and start a new line
Repeat step 3 and type "INTERVALS: "
Press comma, type I, and start a new line
Get Str1 again, then press sto→
Press vars, go to the Y-VARS tab, select Function, and select Y₁. Start a new line
Type (E-S)/I→N and start a new line
Type E-N→O and start a new line
Type S+N→P and start a new line
Type N, then press 2nd stat, go to the MATH tab, and select sum(
Press 2nd stat, go to the OPS tab, and select seq(
Get Y₁ again and press comma,
Type X,S,O,N))→L and start a new line
Repeat steps 17-19 and type X,P,E,N))→R
Type (L+R)/2→T
Press prgm, go to the I/O tab, and select Disp, then type "LEFT:",L
Press prgm, go to the I/O tab, and select Disp, then type "RIGHT:",R
Press prgm, go to the I/O tab, and select Disp, then type "TRAP:",T
Your program should look like:
:ClrHome
:Input "EXPRESSION: ",Str1
:Input "START: ",S
:Input "END: ",E
:Input "INTERVALS: ",I
:Str1→Y₁
:(E-S)/I→N
:E-N→O
:S+N→P
:Nsum(seq(Y₁,X,S,O,N))→L
:Nsum(seq(Y₁,X,P,E,N))→R
:(L+R)/2→T
:Disp "LEFT:",L
:Disp "RIGHT:",R
:Disp "TRAP:",T
If you found this helpful give it a like. If you have any questions or need help, drop a comment. Thanks for taking the time to do some programming!
-Nate