Friday, February 15, 2019

TI-86: Sequence Graphing


TI-86: Sequence Graphing

The program Sequen86 plots one recursive sequence with one initial condition. The function is stored in variable y1, with x presenting y1(n-1). The initial condition is assumed to be y1(1).

This program was originally posted on ticalc.org on April 28, 2001. Link: https://www.ticalc.org/archives/files/fileinfo/186/18667.html

18 years, wow, how time flies.

TI-86 Program Sequen86
(354 bytes)

Func
FnOff
PlOff
ClLCD
DelVar(L1)
DelVar(L2)
Outpt(6,1,”Let y1 = u”)
Outpt(7,1,”Let x = n-1”)
InpSt “y1 =”, Y
St>Eq(Y,y1)
Input “Initial Cond: “,I
Input “# of Steps: “,S
{I} → U
For(N, dimL U+1, S+1, 1)
y1(U(N-1)) → U(N)
End
seq(x,x,1,S+1) → L1
U → L2
0 → xMin
S+1 → xMax
min(U) – 1 → yMin
max(U) + 1 → yMax
Plot1(1,L1,L2)
FnOff 1
Disp “L1 = n”
Pause “L2 = u”
DispG


Example:

u(n) = u(n-1)/3 + 1/4
Initial condition, u(1) = 1/5
Number of Steps: 10

Set up for Sequen86:
y1 = x/3 + 1/4




The 2019 Version

Here is an alternate version, SEQGRAPH. Use U for U(n-1) and N for n. The program allows the initial condition for any value of N.

TI-86 Program SEQGRAPH
(277 bytes)

InpSt “U1(U,N) = “,S1
St>Eq(S1,U1)
Input “N Start = “,N
Input “U0 = “,U
Input “Steps: “,S
S + 1 → dimL xList
S + 1 → dimL yList
N → xList(1)
U → yList(1)
For(I, 2, S+1)
xList(I-1) + 1 → N
N → xList(I)
yList(I-1) → U
U1 → yList(I)
End
FnOff
PlOff
PlOn 1
Plot1(1,xList,yList)
ZData

Example:

u(n) = u(n-1)/3 + 1/4
Initial condition, u(1) = 1/5
Number of Steps: 10

Set up for SEQGRAPH:
U1 = U/3 + 1/4
N Start: 1
U0 = 1/5 (initial condition)



Eddie

All original content copyright, © 2011-2019. Edward Shore. Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited. This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author.

  Casio fx-7000G vs Casio fx-CG 50: A Comparison of Generating Statistical Graphs Today’s blog entry is a comparison of how a hist...