The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Courses » ap-calculus

Topic: Slope field and solutions program for TI calcs
Replies: 0  

Advanced Search

Back to Topic List Back to Topic List  

Posts: 63
Registered: 12/6/04
Slope field and solutions program for TI calcs
Posted: Jan 12, 1998 11:53 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Flow Fields and Solution Curves on TI Calculators

This draws the flow field for dy\dx = Y1

:Lbl 1
:Lbl 2
:If abs(T-S)>V
:Goto 3
:Lbl 4
:X+H\ra X
:If C<W
:Goto 2
:If R<L
:Goto 1
:Lbl 3
:Goto 4

This program calls the preceding, and draws a solution curve
through the cursor position each time you press [Enter]:

:Disp "STEPS"
:Input N
:Lbl G
:Lbl R
:If U=1
:Lbl Q
:If abs(J)>1000000
:Goto F
:If U=0 and X(< or =)Xmax
:Goto Q
:If U=1 and X(> or =)Xmin
:Goto Q
:If U=1
:Goto F
:Goto R
:Lbl F
:Goto G


0. Y1 denotes the variable "Y sub 1" on the TI82 and "y sub 1"
on the TI85.

1. The program SLPFLD draws the slope or flow field for the
differential equation dy/dx = Y1.

2. The program RKG calls SLPFLD to draw the flow field, then
enables you to move the cursor to choose an initial point.
When you press [ENTER], the program draws a solution curve
passing through that point, using the Runga-Kutta algorithm.
When the program starts, it asks for an input called "STEPS:";
this is comparable to the number of subdivisions in Simpson's
rule or Euler's method. The more steps, the greater accuracy;
using 50 is usually more than enough.

3. The programs SLPFLD and RKG will work as is on the TI82
calculator. The only change needed for the TI85 is to change X
and Y to lower case: x and y. (This also means changing the
function "Y sub 1" to "y sub 1") On the TI81 the program
SLPFLD should work pretty much as is, except that the
instruction :RETURN should be End; in RKG, the command SLPFLD
should be replaced by Prgm?:SLPFLD which is gotten from the
PRGM EXEC menu choice.

4. Programing words such as Disp, Goto, Lbl, Input should be
entered from the menus provided on the various calculators;
see the ``Table of Commands'' in the back of your instruction
book to find which menu to use. For example, the symbols "< or
=" and "==" (test for equals) can be gotten from the TEST
menu. The variable Y1 is gotten from the Y-VARS menu on the
TI82/82; on the TI85 you can get it from the vars menu, but
it's easier to type it as: y1 (note lower-case y).

Mark Bridger
Math. Dept.
Northeastern University


Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2017. All Rights Reserved.