Func
©
©Programmed copyright by Tip DS
©This program is free for use, provided
©no modification is made. There may be no
©charge for this program, unless
©permission is given in righting by
©Tip DS. For more information, right
©to tipds@yahoo.com
©
Local expan
1
,expan2,frac,answer,tmp
1
x+
Σ
((
⁻1
)^t*x^(2*t+
1
)/(2*t+
1
),t,
1
,iPart(digits/(
1
.4))-
1
)
→
expan
1
expan
1
|x=y
→
expan2
4*(4*expan
1
-expan2)|x=
1
/5 and y=
1
/239
→
frac
frac-3
→
frac
"3."
→
answer
iPart(
1
0^digits*frac)
→
tmp
1
answer&string(tmp
1
)
→
answer
EndFunc
Note that this is an old version of this program, and is only for demonstration purposes!
If you download this program with GraphLink, and immediately archive it, then it has a size of 520
bytes and an execution time of about 1.32 seconds per call. If you run the program once before
archiving it, it has a size of 602 bytes, and an execution time of about 1.23 seconds per call, for an
improvement of about 7%.
Bigger, more complex programs will show more improvement in execution speed. The reason is that if
you archive the program before you run it, the operating system has to recompile the program each
time it is run. If you run it once before archiving it, then the OS saves the compiled version.
On the other hand, if code size is more important to you than execution speed, you might want to
archive the programs before running them. Note that the PI() program size increases by 82 bytes, or
about 16%, if the program is run once before archiving.
If you are distributing a software package with many programs and functions, you might consider
writing a routine that would automatically execute and archive all the programs for the user.
(Credit to Lars Frederiksen)
[7.12] Access a variable from any folder with "_" (underscore)
Usually you refer to variables outside the current folder by specifying the folder name and the variable
name, like this:
folderName\variableName
However, if you precede the variable name with an underscore, like this:
_variableName
you can use it from any folder without specifying its actual folder location.
The underscore is actually intended to be used to specify user-defined units. However, you can store
numbers, strings, lists, expressions and matrices to this type of variable. Unfortunately, you cannot
7 - 12
Summary of Contents for TI-92+
Page 52: ...Component side of PCB GraphLink I O connector detail 1 41...
Page 53: ...LCD connector detail PCB switch side 1 42...
Page 54: ...Key pad sheet contact side Key pad sheet key side 1 43...
Page 55: ...Key cap detail 1 44...
Page 57: ...Component side of PCB with shield removed A detail view of the intergrated circuits 1 46...
Page 410: ...void extensionroutine2 void Credit to Bhuvanesh Bhatt 10 4...