EasyManuals Logo
Home>Texas Instruments>Calculator>TI-92+

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 #310 background imageLoading...
Page #310 background image
expr("foofold\"&pname)
where "foofold" is the folder where the program in pname resides.
This is useful when you want to execute one or more programs from your program, but you don't know
in advance which program.
[7.21] Use undef as an argument
undef, which means 'undefined', can be used as an argument in some functions and commands. For
example, if this expression is entered in the Y= editor,
y1(x)=when(x<2,when(x<0,undef,x^2),undef)
then x^2 is plotted only for x>0 and x<2.
(Credit to Rick A. and Ray Kremer, submitted by Larry Fasnacht)
[7.22] Local documentation for functions and programs
As you collect more programs on your calculator, it can be difficult to remember what the program
does, or what arguments it takes, or what limitations it has. Frank Westlake shows a method to embed
the documentation as comments within the program itself, such that it can be displayed with the
'Contents...' command in Var-Link. Check here for more details:
http://members.web-o.net/westlake/ti/intdoc.html
The basic idea is to use char(10) and char(12) to format the text to make it easy to read.
[7.23] Passing user function names as program/function arguments
You cannot directly pass user functions as arguments to programs or functions, because the 89/92+
will try to evaluate them when the function is called. Many routines require a function as an input.
The general method is to pass the function name as a string. The called function then evaluates the
function using either expr() or indirection.
Using expr()
To pass a function successfully, pass the name and argument variables (or variables) as a string, like
this:
t("f1(x)","x")
where f1(x) is the function to be evaluated, and x is the function argument variable. To evaluate this
function in program t(), build a string and evaluate the string with expr(). We want a string of the form
f1(x)|x=xval
where xval is the value at with to evaluate the function. So, the complete program looks like this:
7 - 21

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