EasyManuals Logo

Texas Instruments TI-92+ User Manual

Texas Instruments TI-92+
507 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #217 background image
© Do the regression and calculate y = f(x)
quadreg l1,l2
regeq(x)res
© Display the result
dialog
title "QUADINT RESULT"
text "x = "&string(x)
text "y = "&string(res)
text "y saved in 'res'"
text "(Push ESC to quit)"
enddlog
if ok=0:goto exit1 © Give user a chance to quit here
goto t1
© End up here, if user forgets to separate values with commas
lbl err1
dialog
text "x and y values must"
text "be separated with commas"
enddlog
goto t1 © Go try again
© Delete global variables before exiting
lbl exit1
delvar l1,l2
EndPrgm
This program just provides a convenient interface for entering the xy-data points and displaying the
result. Since the user might want to do several interpolations before quitting, the program loops to
repeat the interpolations. The user can press [ESC] at any dialog box to quit the program. The
interpolation result is saved in a global variable res, which can be recalled at the home screen after
exiting quadint(). The global list variables are deleted when the user quits the program.
quadint() calls the function str2var() to process the user's input. str2var() must be in the same folder as
quadint(), but they may be in any folder. You must make that folder current with setfold() before
running quadint(). str2var() is shown at the end of this tip.
When the program is executed, this dialog box is shown:
Each xy-data pair is entered in a single Request field; see tip [9.13] for more details on this. The x- and
y-data values are separated with a comma. An error message is shown if the user forgets to use the
comma. The picture above shows the fields filled in with the values for the example above. When all
the values are entered, the user presses [ENTER] to do the interpolation. Another dialog box is shown
with the interpolation result.
6 - 59

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Texas Instruments TI-92+ and is the answer not in the manual?

Texas Instruments TI-92+ Specifications

General IconGeneral
BrandTexas Instruments
ModelTI-92+
CategoryCalculator
LanguageEnglish

Related product manuals