TI-85 BASIC Question


[Prev][Next][Index][Thread]

TI-85 BASIC Question



I wrote a program that ends up storing real numbers in a matrix.  Sometimes
the values display as complex numbers [i.e., the square root of 2 is
displayed as (1.414,0.000)], and sometimes they do not [i.e., the square
root of 2 is displayed as 1.414].  I need help figuring out why this
happens, because I am not very experienced using matrices.  I am also
perplexed as to why the same program will sometimes display output
differently, when only the input is changing [i.e., the y(1) expression and
x value].


I do not want the matrix values displayed as complex numbers.  I'm using
the PAUSE instruction to enable horizontal scrolling of the display, but
all those extra zeros -- the imaginary part -- result in a very wide
display.


The matrix values come from evaluating expressions stored in the y(x) list.
 Here is a condensed sample of my program, the y(x) list and the output:


----------------------------------------
Fix 3
..
.. [input y1 expression and generate y(2) and y(3)]
..
{4,3} -> dim S
..
.. [input x value; output below reflects x=root 2]
..
x -> S(1,2)
y1 -> S(2,2)
y2 -> S(3,2)
y3 -> S(4,2)
..
.. [remaining 8 matrix values come
..  from evaluating x-0.1 and x+0.1]
..
Pause S
Float
----------------------------------------




y1=(9/14)x^(1/3)(x^2-7)
y2=nDer(y1,x,x)
y3=nDer(y2,x,x)




[[(1.314,0.000)  (1.414,0.000)  (1.514,0.000) ]
  (-3.713,0.000) (-3.608,0.000) (-3.475,0.000)]
  (.909,0.000)   (1.191,0.000)  (1.471,0.000) ]
  (2.825,0.000)  (2.806,0.000)  (2.797,0.000) ]]




Thank you for any insight you may provide.


        ~ Mark