Programming Forums

Programming Forums (http://www.programmingforums.org/forumindex.php)
-   Existing Project Development (http://www.programmingforums.org/forum51.html)
-   -   TI89 programming (http://www.programmingforums.org/showthread.php?t=8359)

Mouche Feb 11th, 2006 3:03 AM

TI89 programming
 
I'm not sure this is the right forum, but here is my problem. I am creating a program that solves the quadratic formula using the values you insert. You can select different menu items to obtain an approximate or exact (radicals and such) answer, or you can select whether your answers are real or complex. This program will evolve to not depend on the selection menu positive and negative, but for now, I just need to figure out how to make it work.

I keep getting a "Missing (" error on my Texas Instruments 89 calculator when I run my program:

:

quad()
Prgm
ClrIO
Dialog
Title "Quadratics Solver"
Text "              Solving Ax®+Bx+C"
Text "              By Glen Winters"
Text "                    Version 1.0"
EndDlog
If ok=0 Then
Goto end
EndIf

Lbl top

Toolbar
Title "Quadratics"
Item "Neg",n
Item "Pos",p
Title " i?"
Item "Real",r
Item "Complex",c
Title "Precise"
Item "Exact",e
Item "Approx",a
EndTBar

Lbl n
Input "A?",a1
Input "B?",b1
Input "C?",c1
(b1^2-4*a1*c1)»d1
If d1<0 Then
If (setMode("Complex Format","RECTANGULAR")) Then
Goto end2
EndIf
Disp "No real solutions"
Else
((ªb1^2+§(d1))/(2*a1))»ans1
Disp ans1
EndIf
Goto end2
Lbl p
Input "A?",a2
Input "B?",b2
Input "C?",c2
(b2^2-4*a2*c2)»d2
If d2<0 Then
If (setMode("Complex Format","RECTANGULAR")) Then
Goto end2
EndIf
Disp "No real solutions"
Else
((ªb2^2-§(d2))/(2*a2))»ans
Disp ans
Goto end2

Lbl r
setMode("Complex Format","REAL")
Goto top

Lbl c
setMode("Complex Format","RECTANGULAR")
Goto top

Lbl e
setMode("Exact/Approx","EXACT")
Goto top

Lbl a
setMode("Exact/Approx","APPROXIMATE")
Goto top

Lbl end2
setMode("Complex Format","REAL")
EndPrgm


Thanks in advance!

Indigno Feb 11th, 2006 1:00 PM

Well, remember that the calculator programming on most of those are very similar to basic. I have heard that there are a lot of problems with a particular release of the ti-89 series. I would google it. If I were you , I would use a ti-86 (If they still make those. I know that a lot of teachers hated it because it was powerful enough to put anything on it)

Mouche Feb 13th, 2006 7:37 PM

Well, I figured out that my "ans" variable was already in the system as a function, so it was looking for parentheses and parameters. I fixed that and I received another error! It points to the very end of the program around the EndPrgm section... What could be wrong?!

FredVietnam Feb 13th, 2006 8:09 PM

i find that programming on a TI-83 plus is much simpler and is very easy to learn i have been doing it for 4 years now


All times are GMT -5. The time now is 4:42 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC