Disaster
#header,
#side-bar,
#top-bar,
#footer,
#license-area,
#page-title,
#navi-bar,
#navi-bar-shadow,
#breadcrumbs,
.page-tags,
#page-info,
.page-watch-options,
.page-options-bottom,
#footer-bar,
#login-status,
.search-top-box,
.note-block,
#edit-cancel-button{
    display: none !important;
}
 
#action-area h1, #edit-page-form tbody tr:first-child{
    display: none !important;
}
 
#main-content, #container-wrap, #container{
    margin: 0;
}
 
table.form-table,
div.field-content,
textarea.field-content{    width: 100%; }
td.form-labels{    width: 50px; }
 
tr.form-row p{    margin: 0; }
div.field-charOne,
div.field-charTwo{
    margin-left: 92px; //30px;
    font-family: 'Andale Mono', 'Courier New', Courier, monospace;
    font-size: 9pt;
    color: #11119C;
}
 
div.field-content textarea{
    border-radius: 4px;
    opacity: .4;
    transition: opacity 500ms;
    -moz-transition: opacity 500ms;
    -webkit-transition: opacity 500ms;
    -o-transition: opacity: 500ms;
}
div.field-content textarea:focus{
    opacity: 1;
}
span.field-attachment input,
span.field-name input{
    opacity: .4;
    transition: opacity 500ms;
    -moz-transition: opacity 500ms;
    -webkit-transition: opacity 500ms;
    -o-transition: opacity: 500ms;
}
span.field-attachment input:focus,
span.field-name input:focus{    opacity: 1; }
 
#edit-save-button{
    border-radius: 4px;
    box-shadow: 0 0 2px -2px rgba(0,0,0,.3);
    margin-left: 58px;
}
.page-tags{    visibility: hidden; }
 
.werecode{
    font-family: 'Andale Mono', 'Courier New', Courier, monospace;
    font-size: 9pt;
    color: #11119C;
}
div.werecode{    padding-left: 1em; }

content: "Some code.\n\n[[div class=\"werecode\"]]\n:{0,1→L₁\n:{0,N→L₂\n:LinReg(ax+b) Y₁\n:Equ►String(Y₁,Str1\n:sub(Str1,1,length(Str1)-3→Str1\n[[/div]]"
attachment: null

content: "Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Phasellus arcu libero, aliquet sit amet, ornare quis, vulputate a, nibh. Aliquam sit amet lectus vitae ligula feugiat condimentum. Proin eu mauris. Suspendisse ac sem. Cras in quam in augue fringilla porttitor. Nulla facilisi. Aliquam erat volutpat. Morbi consectetuer, libero at iaculis fermentum, dolor velit tincidunt sapien, lacinia ultricies ligula dui eget orci. Maecenas magna quam, volutpat ut, auctor et, malesuada quis, quam. Fusce semper pharetra mi. Aliquam facilisis tortor ut ante. Nam dignissim, ipsum et pharetra pretium, est sem feugiat sapien, a mattis elit sem vitae neque. Ut nec nibh. Ut sagittis magna nec velit. Maecenas ut eros. Duis lectus. Sed venenatis. Fusce iaculis urna euismod neque.\n\nLorem ipsum dolor sit amet, consectetuer adipiscing elit. Phasellus arcu libero, aliquet sit amet, ornare quis, vulputate a, nibh. Aliquam sit amet lectus vitae ligula feugiat condimentum. Proin eu mauris. Suspendisse ac sem. Cras in quam in augue fringilla porttitor. Nulla facilisi. Aliquam erat volutpat. Morbi consectetuer, libero at iaculis fermentum, dolor velit tincidunt sapien, lacinia ultricies ligula dui eget orci. Maecenas magna quam, volutpat ut, auctor et, malesuada quis, quam. Fusce semper pharetra mi. Aliquam facilisis tortor ut ante. Nam dignissim, ipsum et pharetra pretium, est sem feugiat sapien, a mattis elit sem vitae neque. Ut nec nibh. Ut sagittis magna nec velit. Maecenas ut eros. Duis lectus. Sed venenatis. Fusce iaculis urna euismod neque."
attachment: null

This is a test category

Welcome to the TI-83/84/+/SE section of TI-Basic Developer (TI|BD), the TI-Basic information repository! If you are a first-time visitor, please check out the welcome pack to get you up to speed on using the site. We encourage you to become a member and to get involved in the community, and to come back often to see what changes have occurred. And above all else, enjoy your stay!
New to TI-Basic?

These pages provide an overview of TI-Basic, and are designed to help you quickly get started learning and using TI-Basic.

Did You Know...
The ListPages module does not work recursively.
Development
The ListPages module does not work recursively.
Recent News Recent Posts Recent Edits
The ListPages module does not work recursively.
The ListPages module does not work recursively.
I agree, I'm a little lost but it was just interesting. I did not use BasicOS for this though....
(by Deoxal 16 Oct 2018 04:39, posts: 7)
Very cool idea, I'd definitely like to join in since projects are how you really get useful...
(by Deoxal 16 Oct 2018 04:19, posts: 2)
What makes a community great is that community's accomplishments. I want to do a community...
(by Misfire 15 Oct 2018 20:55, posts: 2)
The ListPages module does not work recursively.
Search the Site

There is a wide range of TI-Basic content available on this site, so we recommend using the search engine or referring to the sitemap. If you can't find what you're looking for, leave a post in the forums and somebody will assist you.

counter free hit unique web

author: Viktor
description: 'Another pong game, doesn''t loop, fast gameplay and gets harder over time. Has an interesting highscore feature. Multiplayer on two calculators coming soon!'
arcade: '1'
graphics: '0'
platform: '1'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '0'
image: '/archives:a-viktor-s-pong-2-5/pong2.5titlescreen.gif'
download: Viktor%27s%20Pong%20v2.5.1.zip
size: '1665'
unit: '1'

friendlyjoefriendlyjoe since 15 Oct 2018 10:00
BASSIRO TRAOREBASSIRO TRAORE since 14 Oct 2018 19:39
RedstoneCyborgRedstoneCyborg since 11 Oct 2018 19:44
James MoultonJames Moulton since 10 Oct 2018 22:07
FakeFishermanSamyFakeFishermanSamy since 10 Oct 2018 14:24
CreativeCodingCatCreativeCodingCat since 09 Oct 2018 16:27
jodastjodast since 08 Oct 2018 23:18
Gustavosky1Gustavosky1 since 07 Oct 2018 14:32
Bio_Hazard1282Bio_Hazard1282 since 03 Oct 2018 15:35
SlimeEnergySlimeEnergy since 30 Sep 2018 11:44
giant potatogiant potato since 30 Sep 2018 02:44
59m5959m59 since 28 Sep 2018 16:17
Misael AvilaMisael Avila since 26 Sep 2018 15:12
zachp4zachp4 since 26 Sep 2018 13:26
JusssJusss since 25 Sep 2018 01:17
MetroidTI92MetroidTI92 since 21 Sep 2018 19:58
hayden2shayden2s since 15 Sep 2018 01:02
SoshJamSoshJam since 13 Sep 2018 12:24
TriforceyTriforcey since 11 Sep 2018 21:44
Lukep123Lukep123 since 11 Sep 2018 01:43
CloudVariableCloudVariable since 10 Sep 2018 22:53
CerebralDatabankCerebralDatabank since 07 Sep 2018 22:08
Watson221Watson221 since 30 Aug 2018 04:03
faraujofaraujo since 27 Aug 2018 04:54
TIce ColdTIce Cold since 26 Aug 2018 20:45
SolcaminoSolcamino since 26 Aug 2018 01:38
n1776n1776 since 23 Aug 2018 19:39
danielhaishdanielhaish since 21 Aug 2018 20:19
JungomoJungomo since 19 Aug 2018 22:32
rohan_CErohan_CE since 18 Aug 2018 21:38
SharkMafiaSharkMafia since 18 Aug 2018 17:28
Ataul NoorAtaul Noor since 15 Aug 2018 14:30
GeireannGeireann since 12 Aug 2018 19:38
vtaggerungvvtaggerungv since 12 Aug 2018 06:32
Bey145Bey145 since 10 Aug 2018 23:19
Ziyang LiZiyang Li since 03 Aug 2018 03:28
TIBOY117TIBOY117 since 02 Aug 2018 01:14
FrankzeeTankFrankzeeTank since 01 Aug 2018 19:52
Kot5Kot5 since 01 Aug 2018 02:30
nostepnostep since 29 Jul 2018 22:47
mrbigguymrbigguy since 24 Jul 2018 20:52
MisfireMisfire since 24 Jul 2018 20:41
James macklerow321James macklerow321 since 23 Jul 2018 19:04
Kaushik SrikrishnanKaushik Srikrishnan since 22 Jul 2018 17:21
bblackburnbblackburn since 17 Jul 2018 18:39
AlistairyAlistairy since 16 Jul 2018 06:48
Mike1950Mike1950 since 12 Jul 2018 05:53
foroplusforoplus since 10 Jul 2018 20:34
Keshav BhandariKeshav Bhandari since 10 Jul 2018 08:24
IucyintheskyIucyinthesky since 08 Jul 2018 23:10
TienPlayzTienPlayz since 07 Jul 2018 17:52
06Mongoose06Mongoose since 06 Jul 2018 07:28
moomastermoomaster since 05 Jul 2018 17:27
dolkdolk since 02 Jul 2018 04:34
conleycoreyconleycorey since 02 Jul 2018 02:52
Decepticon7Decepticon7 since 30 Jun 2018 14:06
SchizalSchizal since 29 Jun 2018 20:34
EravanEravan since 28 Jun 2018 20:38
Eli_wannabeEli_wannabe since 17 Jun 2018 06:13
RyanTNDRyanTND since 14 Jun 2018 14:21
Coding NightmareCoding Nightmare since 12 Jun 2018 03:11
Binary 6Binary 6 since 11 Jun 2018 20:56
changpresleychangpresley since 08 Jun 2018 06:26
c64z80c64z80 since 06 Jun 2018 16:16
DeoxalDeoxal since 01 Jun 2018 06:26
TrashyGamesTrashyGames since 30 May 2018 01:58
Fred2000Fred2000 since 23 May 2018 16:11
AlexlbAlexlb since 22 May 2018 08:59
PythagorianPythagorian since 21 May 2018 18:57
WoodieloWoodielo since 21 May 2018 18:51
Mosaic_the_jMosaic_the_j since 18 May 2018 22:05
WireLord55WireLord55 since 17 May 2018 05:47
absoluteAquarianabsoluteAquarian since 15 May 2018 13:31
Seb GrantSeb Grant since 12 May 2018 11:04
Chillie43Chillie43 since 10 May 2018 14:31
Shards853247Shards853247 since 04 May 2018 20:12
ItsJustSomeDudeItsJustSomeDude since 30 Apr 2018 17:43
GreenGuy5294GreenGuy5294 since 27 Apr 2018 03:18
amyxamyx since 24 Apr 2018 19:41
Yang ShenlaiYang Shenlai since 24 Apr 2018 18:37
maxprigentmaxprigent since 20 Apr 2018 11:55
Catfisher4Catfisher4 since 20 Apr 2018 02:43
master_programmermaster_programmer since 14 Apr 2018 19:46
Boomcar127Boomcar127 since 13 Apr 2018 21:33
MMMMMMMMMMMMMMMMMMMMMMMMMM since 12 Apr 2018 20:39
master_of_nothingmaster_of_nothing since 11 Apr 2018 15:38
PurpziePurpzie since 10 Apr 2018 16:26
MandragolaMandragola since 09 Apr 2018 21:42
D33B33D33B33 since 04 Apr 2018 17:06
ChultmannChultmann since 03 Apr 2018 19:00
iferocheiferoche since 02 Apr 2018 12:01
AlexH113AlexH113 since 31 Mar 2018 23:35
Kylo BenKylo Ben since 31 Mar 2018 22:24
BrianDaniloBrianDanilo since 30 Mar 2018 14:03
Shadi DelshadShadi Delshad since 28 Mar 2018 19:21
GeneralCobraGeneralCobra since 27 Mar 2018 22:07
ElsterflutElsterflut since 26 Mar 2018 11:54
My_TriumphMy_Triumph since 26 Mar 2018 02:47
Andrew L JrAndrew L Jr since 21 Mar 2018 18:54
SeanNoSpaceSeanNoSpace since 21 Mar 2018 01:46
page 1 of 14123...1314next »

New Members

The ListPages module does not work recursively.

Member Count

The ListPages module does not work recursively.

Last 3 Members

The ListPages module does not work recursively.

Currently Active Users:

The ListPages module does not work recursively.

Jan 16 There are discussions about redesigning the forums to be more robust.

"This page is still in development. It should be finished within a few months. I appreciate your patience! :D"

~Joshuasm32 does not match any existing user name

Sharing is Caring!

BlinkListblogmarksdel.icio.usdiggFarkfeedmelinksFurlLinkaGoGoNewsVineNetvouzRedditYahooMyWebFacebook

Preface:

First, I need to give the essentials to program with my tutorial:

Requirements:

A TI-82/83/84 (Plus) (SE) graphing calculator or emulator.

If you have that, you're set to go!

Key:

Here is a simple key to symbols that I use:

//= A comment on codes.

[___]= A description of something shortening the code.  (I.E., [The code that I used above] )

->= The symbol '→' in programming.

Programmer's Trick's:= A handy trick you can use.

Handy Hint:= A hint for programming.

Beware!= Something to avoid in coding.

Buzz Word:= A handy morsel of information.

Advice:

Before we start, I would like to give a few words of advice:

  1. Never give up on a program, even if it seems impossible to complete, for you can program pretty much anything on a calculator (except color). ;-)
  2. Remember, there is no "wrong way" to program; there are more efficient and less efficient ways, but feel free to stretch the limits and build your own style to program.
  3. Bend the Codes!

So, lets get started!

Basic Concepts

Alright, now that you are ready to start, lets kick off with the basics.

Making Programs:

Let's start with how to create, edit, and run programs. First, tap the [PRGM] key on your calculator. If you use your arrow keys, you can see the cursor move left/right and up/down. Look at the top bar: if your cursor is on the 'EXEC' label, you can move your cursor up and down and run any programs that you may have made. By pressing the right arrow once, you can edit programs. Lastly, if you cursor is on new, you can create a new program.

Go ahead and create a program by pressing [ENTER]. Now, you are prompted for a title. You can enter any name for your program that you want that is 8 characters or less and uses numbers, letters (activated by pressing alpha and the green text above a key), and a theta ('θ'). (A theta is a symbol you can use like a character.) Now, name your program "TUTORIAL" and tap [ENTER] again. Now you are ready to begin making the program. :D

The Command lines, the [PRGM] Key, and deleting programs:

If you have learned other programming languages before, you know that a "Command Line" is a line of commands that the computer reads through. Each command line is represented by the symbol ':.' (You should see a blank command line on your screen.) The computer reads through a command line in the same way we read a book: left-to-right. As it finishes each line of code, it jumps to the next line and continue until the program ends.

Now, to make code for the computer to read, press the [PRGM] key once. This is a list of common commands. (For a full list of commands and symbols, press [2ND] then [0]. You can type a character and jump to different sets of alphabetically sorted commands. Also, TI-84 calculators have the built-in app under the apps menu "CTLGHELP." If you open this, you can go to catalog and press [+] when your cursor is on a command and see how it is used.) Each of these commands has its own syntax and job that it does. We will learn about each of these further on.

To select a command, move you cursor around like on the program and press enter or type the number in front of each command. (I.E., type [1] for "If" and [2] for "Then.") Learning these numeric key-strokes is essential if you want to be a fast programmer. (To learn them, try quizzing yourself on the number and arrow keys to press for each one and practice using it for programming.) After you select a command, it will appear on your command line.

To make a new line, you can press [ENTER], and to finish and save your program, you can press [2ND] then [MODE] to select the yellow text "QUIT." Now, you can delete the program by pressing [2ND], [MEM], tapping [2], [7], and for TI-82/83 calculators, by pressing [ENTER] when your cursor is on a program, and for TI-83 (Plus) (SE) calculators, pressing [DEL].

On the TI-83 Plus/TI-84 (Plus) (SE) set of calculators, you can press [ENTER] and archive a program. A '*' symbol should appear before the program name after you archive a program to represent that it is archived. Archiving is a useful tool for important programs that you do not want to loose if your calculator crashes. However, while something is archived, you cannot run or edit it (without downloading and installing the application "Doors CS7" or others like it). To unarchive, press enter again.

Graph Screen and Home Screen:

There are two "screens" on a graphing calculator: the "Home Screen" and the "Graph Screen." The home screen is the screen used when your calculator is turned on for solving problems, such as "2+2." The graph screen is the screen is the screen which you graph and use drawing commands ([2ND], [PRGM]). This can be found from your home screen by pressing [GRAPH].

Programming & Programming Commands:

Homescreen Commands:

The starting commands are the commands on the home screen. First, let's learn how to use Disp.

Disp

The Disp command (short for "Display") is used to write a line of text up to 16 characters (the width of the home screen) on the first empty row the calculator finds. To find it, tap: [PRGM], (Right Arrow), [3]. Let me give you some example code (Enter this into your TUTORIAL program.)

Disp "HELLO WORLD"

And there you go! Your very first (but not the last!) program. Now, lets go into how that worked.
When you enter "Disp," it seeks the first empty row. Then, you add a quote to the beginning of text when you enter it. To write more text then 16 characters, do this:

Disp "HELLO WORLD","HOW ARE YOU?"
Programmer's Tricks:

A simple trick is that you do not have to finish with the second quote if it is the end of a line of code. :D The calculator assumes a quote on the end. Try this:

Disp "HELLO WORLD
Disp "HELLO WORLD","HOW ARE YOU?"
Beware!

Try to avoid using finishing quotes so that calculators which download your programs that may be low on memory can use your program without worries. Remember, everything you enter requires memory.

Buzz Word:

Disp writes text on the first empty line the calculator finds.

ClrHome:

You may have noticed that it is a bit annoying to have "Prgm TUTORIAL" written on your screen every time that you run the program. Also, if you want to add more text on a blank screen, you would have to display " " a bunch of times. That is why I am glad to tell you of the command ClrHome; this clear the home screen (Clear Home). To find it, tap: [PRGM], (Right Arrow), [8]. Look at this code:

ClrHome
Disp "HELLO WORLD

See how easy that was?

Buzz Word:

ClrHome clears the home screen.

Handy Hint

I recommend using the command ClrHome at the beginning of all programs on the home screen to remove "PROGRAM:TUTORIAL" from the screen.

Output(:

Let's say you want to write "HELLO WORLD" on the bottom of the screen and "HOW ARE YOU?" on the top. Output( is used to put text on the screen at given coordinates. Look at this grid:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
1 (1,1) (1,2) (1,3) (1,4) (1,5) (1,6) (1,7) (1,8) (1,9) (1,10) (1,11) (1,12) (1,13) (1,14) (1,15) (1,16)
2 (2,1) (2,2) (2,3) (2,4) (2,5) (2,6) (2,7) (2,8) (2,9) (2,10) (2,11) (2,12) (2,13) (2,14) (2,15) (2,16)
3 (3,1) (3,2) (3,3) (3,4) (3,5) (3,6) (3,7) (3,8) (3,9) (3,10) (3,11) (3,12) (3,13) (3,14) (3,15) (3,16)
4 (4,1) (4,2) (4,3) (4,4) (4,5) (4,6) (4,7) (4,8) (4,9) (4,10) (4,11) (4,12) (4,13) (4,14) (4,15) (4,16)
5 (5,1) (5,2) (5,3) (5,4) (5,5) (5,6) (5,7) (5,8) (5,9) (5,10) (5,11) (5,12) (5,13) (5,14) (5,15) (5,16)
6 (6,1) (6,2) (6,3) (6,4) (6,5) (6,6) (6,7) (6,8) (6,9) (6,10) (6,11) (6,12) (6,13) (6,14) (6,15) (6,16)
7 (7,1) (7,2) (7,3) (7,4) (7,5) (7,6) (7,7) (7,8) (7,9) (7,10) (7,11) (7,12) (7,13) (7,14) (7,15) (7,16)
8 (8,1) (8,2) (8,3) (8,4) (8,5) (8,6) (8,7) (8,8) (8,9) (8,10) (8,11) (8,12) (8,13) (8,14) (8,15) (8,16)

When you enter the coordinates of a point, it will write text there. You must remember, instead of an "X,Y" format, you must use a "Y,X" format for Output(. Look at this example:

ClrHome
Output(1,1,"ROW 1
Output(8,1,"ROW 8

See how that worked?

Buzz Word:

Output( puts text on the screen at given coordinates using a "Y,X" format.

Pause

The Pause command does what is apparent: it pauses and wait for [ENTER] to be pressed, then proceeds. It is activated by pressing: [PRGM], [8]. Lets work out an example, shall we?

ClrHome
Disp "HELLO WORLD
Pause
ClrHome
Handy Hint

One trick about Pause is this: you can use it in the same as Disp to display text and then go on to pause. Look at this example:

ClrHome
Pause "HELLO WORLD
ClrHome

Do you see? It is a more efficient method of coding the above.

Variables and "→" vrs. "=":

Now, let's go into making Variables. The is a major function in programming. Variables a the characters A-Z and _theta_. These can be used to store and recall data. A Variable takes a snapshot of whatever data is given to it and stores it in a box, named the name of the character chosen. The symbol "→" stores data and is activated by pressing [STO]. Look at this sample code:

           123                             →                                                                   A
            ^                              ^                                                                   ^
\\This is the data to be stored.    \\This says "Take the given data and store to..."    \\This is the variable which the data is stored to.

Do you see? Now, let's try an example:

ClrHome
123->A
Disp A

(When you display a variable, do not use a quote; that is only for displaying text.)

Buzz Word

A Variable stores a number or an equation to be recalled for later use.

Now, many programmers are often confused by this: What is the difference between "→" and "="? (the symbols "=", ">", "<", "≥", "≤",and "≠" are found by pressing [2ND], [MATH] or in the catalog). Let's look more carefully, shall we?

123->A
A=123

When you store something using '→', you are doing something and performing an action. When you you use '=', you are making a statement. This will return a "1" if the statement is true and a "0" if it is false. Do you see the difference now? :D

Buzz Word

The symbol "→" stores information and the symbol "=" states information.

Strings

Now, variables are useful for storing numbers and equations, but if if you ever try to store text to them, they will not work. To fix this, you can use Strings. Strings are used in the exact same way as variables except they store text instead of numbers. There are 10 strings labeled 1-9 and 0. To access strings, press: [VARS], [7]. To give an example of how to use them, lets work out an example.

ClrHome
"HELLO WORLD"->Str1
Pause Str1
Buzz Word

Strings are exactly the same as variables except they store text.

Creating a Customized Program

Now, here is a major break-through for your programming skills: right now, when you make a program, it only has one ending: the one you programmed. However, we are now going to go into creating an individualized program experience.

Input & Prompt:

The commands Input and Prompt are the most basic way to create a program with multiple outcomes. These ask for information and store it to either a variable or a string.

Prompt:

Prompt stores a number or an equation to a Variable of choice. Look at this example:

ClrHome
Prompt A
Disp "A IS:",A

It also can store information to a string!

ClrHome
Prompt Str1
Disp "STRING 1 IS:

Once you figure out how to use it, this command is a breeze!

Buzz Word:

Prompt asks for user inputed data and stores it to the chosen location.

Programmer's Tricks:

You can also use a comma between Prompt's in the same way as Disp; look at this:

ClrHome
Prompt A,Str1
Disp A,Str1
Input:

Input works like Prompt, performing the same task, but does it in a more user-friendly method. It takes a little more time and effort to learn, but it is worth it in the end!

You can store and input to a variable or to a string. The difference is this: say you want to ask someone there name and store it to string one to be used later on in the program; using prompt, you could enter this code.

ClrHome
Prompt Str1
Disp "HELLO
Pause Str1

However, this returns: "Str1=?" for the user's name. However, if you did not write the program, what does it mean? What do they do? You could use 'Disp' before 'Prompt,' but it still looks messy… So, that is where input comes in.

ClrHome
Input "NAME IS:",Str1
Disp "HELLO
Pause Str1
Programmer's Tricks

Normally, Prompt is only used for math programs, such as a program to find, say, the area of a square (L*W=A).

ClrHome
Prompt L,W
L*W->A
Disp "Answer is
Pause A

And even then, Input could have been used for a clearer program. ;-)

Simple Menu's:
If Statements:

In my opinion, these is the most vital part of programming: the conditionals. It works like a conditional in the English language; examine this code to get a brief idea of how they work.

ClrHome
Prompt A
If A=1
Disp "A is 1

The code is saying, "Ask what A is. If A=1, then say A=1." If A does not equal 1, the program will skip the If statement and end the program, since there is nothing which comes after the if statement.

The If statement can control a game or program to make it so that you win, loose, or do whatever you want your program to do. For instance, we aren't this far into programming yet, but say you were making a game of "pong." You could say, "If the ball touches the bumper, bounce it. Otherwise, tell the player that they die." This is the primary part of most games and programs.

There are also commands which can be added on to the if command.

Then and Else:

Questions & Comments

For more details about a specific command covered or information about commands not covered, I recommend looking through the completed Command Index. If you have questions or comments about this tutorial, please discuss them below. Alternatively, you can contact Joshuasm32 does not match any existing user name directly for personal assistance.


Back to Top
<![if !(lt IE 8)]><!>
<script type="text/javascript">
(function(){var e=document.createElement("script");e.type="text/javascript";e.async=true;e.src=document.location.protocol+"//d1agz031tafz8n.cloudfront.net/thedaywefightback.js/widget.min.js";var t=document.getElementsByTagName("script")[0];t.parentNode.insertBefore(e,t)})()
</script>
<!<![endif]>

These tutorials are pages to help new programmers to get a start into TI-programming. Questions can be consulted under the "Discuss" tab at the bottom of the page.

BASIC Tutorials:

Assembly (ASM) Tutorials:

Axe Parser Tutorials:

BatLib Tutorials:

Miscellaneous Tutorials:

You are welcome to write your own tutorials as long as they pertain accurate information.

TI-Basic Developer has a slew of assembly hexcodes and the list is growing. Though these are often touted as dangerous if used improperly, there are perfectly acceptable ways of combining and creating your own codes even if you don't know assembly. This page is focused on how to create your own assembly libraries using the hexcodes on this site.

Step 1: Select your routines

First, figure out which commands you want to include. Some of the commands will not work with this method:

  • Sprite
  • Fast Keys
  • Repeat Keys

These will not work only because they use some constant addresses for routines (basically, it expects a routine to be in a specific place in RAM, so you would need to recalculate the addresses which requires some assembly knowledge).

Step 2: Organise.

Arrange the commands you selected in some order. We will be accessing them using a number in Ans starting at zero.

Step 3: Choose a template

These are four basic templates that you can use for your library to start. There are more complicated ones mentioned later for the adventurous.

  • If any of your routines require an input in Ans as a number (and none require Ans to be a string):
1817              ;skips the first chunk of code
ED5BAF84
7AB3C8
1BED53AF84
2AB184E7
22B184
EFEF4AC9

EFD74A3DC0
EB4E234623
ED43AF84
22B184
CD979D
  • If any of the routines require Ans as a string (and none require Ans to be a number), we will need to use Str1 instead:
1810
EFC541
21AA00
227984
D7
EB4E234623C9
EFD74A
EFEF4A
  • If any routines require Ans as a number and any routines require Ans as a string:
1827              ;skips the first chunk of code
ED5BAF84
7AB3C8
1BED53AF84
2AB184E7
22B184
EFEF4AC9
EFC541
21AA00
227984
D7
EB4E234623C9

EFD74A3DC0
EB4E234623
ED43AF84
22B184
CD979D
  • If Ans is not an input for any of your routines:
EFD74AEFEF4A

Step 4: Replace code.

The library needs input in Ans, so naturally there will be a conflict if any of your routines need input in Ans. In this event, if any inputs need to be numbers, we will have to use a two-element list to pass the second argument. This requires you to alter certain parts of code.
Case 1: Ans is not an input for any routines.

  • No replacing is needed! Go to Step 5.

Case 2: Ans is a number for some inputs and is never a string

  • Replace all instances of EFD74AEFEF4A with CD979D (This replaces Ans is a number input)
  • Replace all instances of EFDA4AEFEF4A with CD979D (This replaces Y is an input)
  • Replace all instances of EFE04AEFEF4A with CD979D (This replaces X as an input)

Case 3: Ans is a string for some inputs and is never a number

  • Replace all instances of EFD74AFE04C0EB4E234623 with CD979D
  • Replace all instances of EFD74AD604C0EB4E234623 with CD979D, if bugs occur, use CD979DAF.

Both of these codes do almost precisely the same thing.
Case 4: Ans is a number in some commands, and could be a string for some commands:

  • Replace all instances of EFD74AEFEF4A with CD979D
  • Replace all instances of EFDA4AEFEF4A with CD979D
  • Replace all instances of EFE04AEFEF4A with CD979D
  • Replace all instances of EFD74AFE04C0EB4E234623 with CDAE9D
  • Replace all instances of EFD74AD604C0EB4E234623 with CDAE9D

Step 5: Add your commands.

Now that we have the template for the library setup, we can add in the actual commands. To do this, some byte counting will need to be done.

4704
10**
<<code0>>
10**
<<code1>>
10**
<<code2>>
10**
<<code3>>
10**
<<code4>>
...
05C0
<<last code>>

The ** means you need to count how many bytes are in the routine following. Every two hex digits makes one byte. Every full line in the TI-BASIC editor is 8 bytes since it is 16 chars wide.
So for example, 3E02D310C9 is 5 bytes. Be careful, this value must be in hexadecimal!

Now for my own example. I will use
ScreenOn : 3E03D310C9
ScreenOff : 3E02D310C9
ScreenToggle : DB10CB6F3E0220013CD310C9
QuickKey : 3A3F84EF8C47EFBF4AC9
LowerCase On : FDCB24DEC9
Lowercase Off : FDCB249EC9
Indicator Off : EF7045C9
Set Contrast : EFD74AEFEF4AC6D8D8D3107B324784C9

Since Set Contrast uses Ans as an input and none of the other routines need Ans as a string, I will use the first starting code:

1817              ;skips the first chunk of code
ED5BAF84
7AB3C8
1BED53AF84
2AB184E7
22B184
EFEF4AC9

EFD74A3DC0
EB4E234623
ED43AF84
22B184
CD979D

I will need to modify the code for Set Contrast:
EFD74AEFEF4AC6D8D8D3107B324784C9 turns into:
CD979DC6D8D8D3107B324784C9
And now I need to add this:
4704
1005
3E03D310C9
1005
3E02D310C9
100C        ;0C is hexadecimal for 12
DB10CB6F3E0220013CD310C9
100A        ;0A is hexadecimal for 10
3A3F84EF8C47EFBF4AC9
1005
FDCB24DEC9
1005
FDCB249EC9
1004
EF7045C9
05C0
CD979DC6D8D8D3107B324784C9

So now here is how to use your program:

  • If your program has any commands that use Ans as a string input, the string must be in Str1 instead
  • If your program has any commands that use Ans as a number input (or X or Y), the inputs are now passed as list elements.
  • If Ans is not needed as a number input by any of the routines, you will simply pass a number to your program

So for example, my program takes a list input. The first element is the command number (I have 8 commands, so use 0 to 7) and the second argument is for any additional inputs the routine may need.
So SetContrast would be {7,«contrast»:Asm(prgmLIB
If you omit an argument, the program will read it as 0. So {7} passed to my program will set the contrast to zero.

So now you have your own, personalised assembly library! Compress it using AsmComp(and it is ready for release with your games.

Alternate Templates

If Ans is never a string input for your commands, you can use this code as an alternative. It is bigger, but it has a few perks. Instead of using a one element list, you can simply use the number. For example, {3:Asm(prgmLIB will be read the same as 3:Asm(prgmLIB. Omitted arguments are read as zero, but you can also make your library execute several commands. For example, if 3 and 4 are both separate commands and command 4 has an input, then {3,4,«arg»:Asm(prgmLIB will execute the two commands.

Note: If a command outputs a value in Ans, make sure it is the last command in the sequence. (otherwise it overwrites the input list!)

1818
ED5BAF847AB3C8
1BED53AF842AB184
E722B184EFEF4A37C9
EF524BD7EB
B720050101001806
3DC04E234623
ED43AF8422B184
CDCE9D18FBCD979D3802E1C9

author: dan769
description: "A very compact (610 bytes) clock with accurate hands and a day indicator.\n\nAdding Soon:\n-Moon Phase Calc "
arcade: '0'
graphics: '1'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '1'
misc: '1'
image: 'archives:digital-anoluge-clock-v1-0/ClockScreenshot.gif'
download: CLOCK.zip
size: '610'
unit: '1'

Moderator

F

author: 42maelstrom
description: "A fully customizable, scrolling menu created for Codebender's custom menu contest. \nFeatures a side scroll bar and supports however many options as you want! To use, store a string as Ans like so:\n:\"Title,option 1,option 2, option 3, option 4\n\nFor however many options you want, each seperated by a comma. \n\nUses variables LQ, Str1, GDB 0,\n\n"
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '1'
misc: '0'
image: '/archives:cstmmenu/SCREENMENU.png'
download: MENU42(1).8xp
size: '970'
unit: '1'

Zelda
Zedd Physics Library
xPegz
Aura
xLib xLib Revolution
War
Virtual Poker
Tetris
Spider
Snake
Slayer 2
Shift
Senilym
Reversi
Portal X
Pipes
Nibbles Arcade
Nibbles
Nemesiat
Minesweeper
Metroid Pi
Metroid II
Metroid
Lode Runner
Lights Out
Ground Assault
Frogger
Flash Flash Revolution
Final Fantasy
Final Fantasy: Tales of Magic
Factory
Dstar
Dotz
Doodle Jump
Donut Quest
Diortem
Connect 4
Chrono Trigger
Brick Block
Breakout
Bowling
Black Jack
Beta Tetris
Anti Nibbles
Absolute Insanity
Dec 27 Mr Dino was made a site moderator due to his commitment and dedication to the forum

Routine Summary

Determines whether an input is a number or list.

Inputs

Ans - the number or list to examine

Outputs

Ans - 1 if the input is a number, 0 if it is a list (see criteria below)

Calculator Compatibility

TI-83/84/+/SE

Author

Zeda

As long as Ans is always contains more than one element and the second element is not twice that of the first, this will determine if Ans is a list or not:

Ans(2)=2Ans(1

If Ans is a number, this will always return 1, else if it is a list meeting the above criteria it returns 0.
Dec 12 burr redesigned the main homepage to complement the respective calculator homepages

TI-Basic Developer (TI|BD) covers how to make TI-Basic programs using the many different TI-Basic commands, while discussing proper programming design and showing several techniques that can be incorporated into programs. After going through all of the information, it is hoped that the reader becomes a competent TI-Basic programmer.

The site is currently split up into three separate sections based on the version of TI-Basic that is used in the different TI graphing calculators — the TI-83, 68k, and TI-Nspire series. It is recommended that you have one of those calculators, so that you can actually use the information contained in that section of the site.

Site Content

We've tried to create a broad base of TI-Basic information. This ensures that most readers will hopefully be able to learn something from this site. Experimentation is encouraged to fully digest all of the information. The site content can be broken up into six general, interdependent parts:

  • Preparation — Before starting TI-Basic programming, you should understand the difference between TI-Basic and Assembly, learn about the different TI calculators, and how to use them.
  • Commands — The commands are explained in thorough detail, including their description, syntax, and different uses. The commands are also grouped together based on their function and purpose.
  • Design — The design teaches how to succeed at programming, including improving program design and optimizing using the different commands. It will help the reader become a more complete programmer.
  • Techniques — The techniques are a collection of short routines, broken down and dissected to help the reader understand the underlying logic. They are not designed to be comprehensive, but rather a foundation which the reader can build upon.
  • Experimentation — The experimentation tests your comprehension of the commands, design theory, techniques, and the rest of the information on this wiki. There are review exercises, project challenges, and sample programs and games that you can try out to learn from and just have fun with.
  • References — The references are a collection of lists on different subjects, including tutorials and tools available elsewhere on the Internet, the tokens, error conditions, file extensions, and key codes used by the calculator, and the common terminology that is used in the TI community.

Each reader can read the information in whatever order they desire. For the average reader, though, the suggested approach is to just start from the beginning and read until the end. The information is presented in a sequential order, with the concepts and code getting increasingly more complex as you get further into it. You might also look at the page Using This Guide, which outlines another suggested reading order.

Site Goals

The main goal of this site is to teach TI-Basic programming. This site is targeted primarily at the beginner programmer (those with little or no programming experience), but it has information for almost everyone. We believe that if you can teach a beginner programmer good programming habits and skills, they will incorporate those habits and skills into the programs they create. The result will be higher quality TI-Basic programs.

Related to the first goal, the second goal of this site is to be the nexus for TI-Basic information. There are many different design concepts and techniques to learn and master, which are all part of the rich heritage of TI-Basic. Unfortunately, when programmers leave the TI community, they often forget to write down their programming innovations, and that information gets lost to the community. We encourage all programmers to contribute their TI-Basic knowledge to the community to prevent this from happening.

The third goal of this site is to present TI-Basic in a more connected and beginner-friendly format. The TI-Basic information is spread out across several TI forums, sites, and among individual tutorials and guides, and this problem is made even worse because of how cumbersome and confusing the information is presented. For a beginner TI-Basic programmer, it is especially hard to read through and follow. The result is a challenging barrier for learning TI-Basic.

The last goal of this site is to create more TI-Basic programming documentation. The one major underdeveloped area in the TI community is quality documentation. We believe that this is because writing tutorials is not really a fun activity, and it does not receive the same recognition as creating a program or game. Nonetheless, documentation is essential to the success of the TI community.

author: 'Jason Pavlik'
description: 'pick which piece of info you have for the photon your studying and enter the value. remember to enter info like nano-meter as E-9. '
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '1'
misc: '0'
image: '/archives:photon-lamda-nu-energy-mass-calculator/SCREEN01.BMP'
download: PHOTON.8xp
size: '4'
unit: '2'

The development of a program is essential to its ability to succeed and be good. The development is a cycle that can be repeated as many times as desired, each time making a new version. This cycle will allow you to make your program usable, efficient and clean. Here is a list of the parts of the development cycle:

author: SuperchuFrostbite
description: "The Classic arcade game….. now for Ti! \nnot sure how to upload pictures, if it runs on 83, how to fix all the bugs… etc. please comment and/xor rate!"
arcade: '1'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '1'
image: '/archives:asteroids/PIC3.JPG'
download: ASTEROIDS.zip
size: '3809'
unit: '1'

author: 'Superchu Frostbite'
description: 'A simple reflex game where a key code is generated on the screen. Push the correct key before you run out of time. A great way to learn the key codes.'
arcade: '1'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '1'
misc: '1'
image: /home/no_image_2.png
download: KEYGAME.zip
size: '268'
unit: '1'

Jun 05 burr redesigned the homepage for the TI-83 section of the site

_Abe_ is working on a futuristic RPG with several abilities and a unique style of battle called Endland.

The game features a dynamic inventory system, a graphical overworld and battle engine, and supports standard RPG stuff.

(Read more...)

builderboy is working on an RPG style platform game set in space called Serenity.

The storyline involves you captaining a cargo ship, traveling through space carrying unknown Government cargo, when your ship is attacked by space pirates! Now you will need to explore the bowels of their ship, fight off enemies, and gain special items, so you can finally escape.

(Read more...)

BUNNYGOTCHI.gif

Bunny Gotchi by James Kanjo

This is a virtual pet on your calculator. It will challenge your efforts to keep it alive, healthy and happy!

donut-quest.gif

Donut Quest by DarkerLine

On each of eight levels, you must get to and eat all the donuts, then leave through an exit.

drifter-video.gif

Drifter by ztrumpet

You slide until you hit an object on the board. The game includes 16 built-in levels and a custom level editor for endless hours of fun.

nibbles.gif

Nibbles (Snake) by Edward H

This version of snake is extremely fast and efficient, and is unique because it doesn't use any list variables to control the movement of the snake.

wabbitemu.gif

Routine Summary

A custom menu with up to 9 switchable pages.

Inputs

Str1-Str9 - one string per page
A - Number of pages the menu includes

Outputs

B - the page they're on
X - the # choice they made

Variables Used

Ans, B, C, D, X, Str#

Calculator Compatibility

TI-83/84/+/SE

Author

Mr Dino

Download

MENUZ.zip

:1→B
:While 1
:If B=1:Str1
:If B=2:Str2
:If B=3:Str3
:If B=4:Str4
:If B=5:Str5
:If B=6:Str6
:If B=7:Str7
:If B=8:Str8
:If B=9:Str9
:ClrHome
:Output(1,1,Ans
:length(Ans)/16
:If fPart(Ans
:1+iPart(Ans
:Ans→D
:2→X
:Repeat C=24 or C=26
:Output(X,2,">
:Repeat Ans
:getKey→C
:End
:If Ans=21
:Then
:X-1→X
:Return
:End
:Output(X,2," " // space
:X-(Ans=25)+(Ans=34→X
:2(X>D)+D(X≤1)+X(X≤D and X>1→X
:max(1,min(A,B+(C=26)-(C=24→B
:End
:End

To use this code, store an integer to A 1-0 representing the number of pages that will be in your menu. It will use all strings Str1-StrA. Next, store the menu pages into the strings. They will be shown with 'Output(1,1,StrA)', so make sure that the menu looks right before using it. Make sure there are 16 characters in each line (starting with the title). Use spaces to make the words fit right, and you should probably test it to make sure it works. There should probably also be something in the title that signifies what page you're on. Finally, run the code as a subprogram.

Here's how it works:

B represents what page number it's on, so we start off by storing 1 to B to put us on page 1. Then we have a While 1 loop to manage page changes. Based on the value of B, it will put one of the strings into Ans. It will output Ans onto the home screen, then determine how many rows are in the menu and store that to D. And the user will always start out on option 1 - row 2 (because of the title screen).

Now we start the choice loop: We display the cursor, then wait for a keypress. If the use presses [2nd], we subtract 1 from X (for the offset from the title) and Return back to the parent program, with B as the page number and X as the choice number. But if not, it continues: The cursor is erased, X and B are changed according to the keypress, and if the use changed the page, it exits the choice loop and enters the page loop where it displays the new page and sets up for another choice loop.

Error Conditions

It won't work properly if A isn't an integer within the bounds 1-9 or if the strings don't represent the menu pages correctly.

Related Routines

There are several routines that are similar in functionality or are used in a similar context. Make a bulleted list of them, with links to the other routines' pages. It will often be the case that several routines all link to each other.

Welcome to TI-Basic Developer (TI|BD), the premier source for TI-Basic information! If you are a first-time visitor, please check out the welcome pack to get you up to speed on using the site. We encourage you to become a member and to get involved in the community, and to come back often to see what changes have occurred. And above all else, enjoy your stay!
Recent Site News Recent Forum Posts Recent Page Edits
The ListPages module does not work recursively.
I agree, I'm a little lost but it was just interesting. I did not use BasicOS for this though....
(by Deoxal 16 Oct 2018 04:39, posts: 7)
Very cool idea, I'd definitely like to join in since projects are how you really get useful...
(by Deoxal 16 Oct 2018 04:19, posts: 2)
What makes a community great is that community's accomplishments. I want to do a community...
(by Misfire 15 Oct 2018 20:55, posts: 2)
The ListPages module does not work recursively.
Search the Site

There is a wide range of TI-Basic content available on this site, so we recommend using the search engine or referring to the sitemap. If you can't find what you're looking for, leave a post in the forums and somebody will assist you.

Featured Program Featured Challenge Recent Page Edits
The ListPages module does not work recursively.
The ListPages module does not work recursively.

You must make a Connect 4 game with an intelligent AI that plays against a human, with the first player to get four in a row winning the game. Your game should follow the standard rules, including using 6 rows by 7 columns for board dimensions.

To determine the best AI, AI's will be played against each other via two calculators, and the champion AI will be declared as the winner program.

(Participate...)

New to TI-Basic?

These pages provide an overview of TI-Basic, and are designed to help you quickly get started learning and using TI-Basic.

Did You Know...
The ListPages module does not work recursively.
Commands
The ListPages module does not work recursively.
Development
The ListPages module does not work recursively.

Moderator

FA
Apr 25 Xeda Elnara was made a site moderator due to her commitment and dedication to the forum
Apr 10 TI Story has moved to its own wiki — http://tistory.wikidot.com
Feb 01 burr started a new section of the site called TI Story for documenting the TI community history

This article is under construction and needs to be completed. You can help by expanding it.

product-screenshot.png

Filename

Summary

Authors

Site URL

Ticalc.org URL

Release Date

Compatibility

Language

Product Intro

Product Screenshot

product-screenshot.jpg
(Screenshot of Product)

Significance of Product

  • Why product was important to TI community
  • Any controversy or interesting circumstances surrounding product
  • Awards won, fond memories that people have

Documentation

  • How to use the product
  • Can copy the author's readme file (if available)

Development History

  • A chronological overview of the product's development

Miscellaneous

Related Products

This article is under construction and needs to be completed. You can help by expanding it.

Editing this page is currently blocked. Please use the discuss link at the bottom to suggest any changes that you would like to make.

TI Story has moved to its own wiki located at http://tistory.wikidot.com — please change your links accordingly.

request.png

Command Summary

Asks for a string in a dialog box.

Command Syntax

Request promptString, var

Menu Location

Starting in the program editor:

  • Press F3 to enter the I/O menu.
  • Press 1 to enter the Dialog submenu.
  • Press 2 to select Request.

Calculator Compatibility

This command works on all calculators.

Token Size

? bytes

On its own, the Request command asks for a string in a dialog box, while showing the prompt string to its left. It can also be used inside a Dialog..EndDlog block, to add a line of text to a more advanced dialog.

The text must be a single string, but you can build one out of smaller strings and other data types using the & and string() commands.

Request will give an error if the string is too long — how long varies from model to model, and depending on if text is being used inside or outside Dialog..EndDlog, but in general anything below 30 characters is safe (otherwise, you should test the dialog first to make sure everything fits). It uses the small, variable-width font on the TI-89 and TI-89 Titanium, and the normal fixed-width font on widescreen calculators.

Advanced Uses

You can add 0 as a third argument for the calculator to turn off alpha lock when typing text, but all Request commands in a dialog box must have the same alpha-lock setting. The setting can be used to ask for a number, using expr() as well.

Error Conditions

130 - Argument must be a string happens when Text is used to display other data types without using string() first.

230 - Dimension happens when the line of text is too long to fit in a dialog box.

Related Commands

See Also

exec.png

Command Summary

Executes a string of assembly opcodes.

Command Syntax

:Exec string [, expression1] [,expression2]…

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

Token Size

? bytes

The Exec command allows you to execute assembly-language opcodes. The optional expressions let you pass one or more arguments for a program.

You need to be careful though. If you make a mistake, then you could lock up your calculator and lose your data.

Optimization

Error Conditions

Related Commands

author: blue_bear_94
description: 'This is a game in grayscale. Even more surprising is that it''s in pure TI-Basic.'
arcade: '1'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '0'
image: '/archives:grayscale-bug/gbug.png'
download: Grayscale%20Bug.zip
size: '668'
unit: '1'

author: symaxian
description: 'A collection of most of the characters available on the TI, sorted by hex code and stored into Str0. Unavailable characters are represented by a "?". See http://tibasicdev.wikidot.com/83lgfont for more info.'
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '1'
image: 'archives:glyphs/glyphs.png'
download: GLYPHS.8xp
size: '399'
unit: '1'

author: 'Jack Fenlin'
description: "Battery Level Indicator\nChecks Your Batteries\nIndicator program is in TI-BASIC\nBattery Check program is in Assembly\nCombined size of both programs (when the assembly program had been compressed) is 262 bytes."
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '1'
misc: '0'
image: /home/no_image_2.png
download: Battery-Icon
size: '3560'
unit: '1'

Jan 31 burr reorganized the forum to make it easier to use.

Welcome visitors and frequent lurkers! We are excited that you are on the site, and encourage you to become a member and to get involved. If you can't find what you're looking for, please leave a post in the search help thread and somebody will assist you. We hope that you enjoy using the site and stop by often!

Jan 27 burr added a new game (mastermind) to the games page.

Mastermind is a fun game that involves trying to break a random code of five numbers (1-9) in fifteen guesses or less. To help assist you with the code-breaking, a clue is displayed below each number. If the number is correct and in the right position, a star (*) will be displayed. If the number is correct but in the wrong position, a plus (+) will be displayed. And if the number is simply wrong, a minus (-) will be displayed. Try out the game and try to understand and think through the code.

The Code

:randInt(1,9,5→L1
:For(X,1,15
:0→dim(L2
:Repeat Ans=105 and 5=dim(L2
:ClrHome
:For(Y,1,dim(L2
:Output(1,Y,L2(Y
:End
:Repeat Ans
:getKey
:End
:If Ans=22
:Goto Q
:If Ans=45
:ClrList L2
:If Ans=23 and dim(L2
:dim(L2)-1→dim(L2
:If 5>dim(L2) and 2>abs(5-abs(5-abs(Ans-83
:26-3int(.1Ans)+10fPart(.1Ans→L2(1+dim(L2
:End
:" // 1 space
:For(Y,1,5
:Ans+sub("-+*",1+max(L2(Y)=L1)+(L2(Y)=L1(Y)),1
:End
:Output(2,1,sub(Ans,2,5
:rand(E2  // scientific E ([2nd][,])
:If not(min(L2=L1
:End
:Disp sub("FAIL!WIN! ",1+5(X<16),5
:Lbl Q

Related Games

Routine Summary

Draws a triangle on the graph screen.

Inputs

L1 - X-coordinates of 3 vertices
L2 - Y-coordinates of 3 vertices
S - Whether it is shaded
D - draw if 1, erase if 0

Variables Used

L1, L2, S, D, M, N, B, C

Calculator Compatibility

TI-83/84/+/SE

:If S
:Then
:SortA(L1,L2)
:If L1(2)≠L1(1)
:Then
:(L2(2)-L2(1))/(L1(2)-L1(1))→M
:L2(1)-ML1(1)→B
:(L2(3)-L2(1))/(L1(3)-L1(1))→N
:L2(1)-NL1(1)→C
:For(I,L1(1),L1(2),ΔX)
:Line(I,MI+B,I,NI+C,D)
:End
:End
:If L1(2)≠L1(3)
:Then
:(L2(3)-L2(2))/(L1(3)-L1(2))→M
:L2(3)-ML1(3)→B
:For(I,L2(2),L1(3),ΔX)
:Line(I,MI+B,I,NI+C,D)
:End
:End
:Else
:Line(L1(1),L2(1),L1(2),L2(2),D)
:Line(L1(1),L2(1),L1(3),L2(3),D)
:Line(L1(2),L2(2),L1(3),L2(3),D)
:End

This is a routine to draw a shaded triangle, with an option to draw an unshaded triangle too.

Error Conditions

Related Routines

{$picture}

Command Summary

Turns the stat wizard off.

Command Syntax

STATWIZARD OFF

Menu Location

Press:Catalog,

  1. 2nd CATALOG to enter the command catalog
  2. T to skip to command starting with T
  3. Scroll up to STATWIZARD OFF and select it

Calculator Compatibility

TI-84/+/SE 2.55 MP

Token Size

2 bytes

The STATWIZARD OFF command disables the use of the Stat Wizard, added in 2.55MP, for statistic and distribution commands as well as seq(.

Advanced

Formulas

Error Conditions

Related Commands

Statwizard On

{$picture}

Command Summary

Turns the stat wizard on.

Command Syntax

STATWIZARD ON

Menu Location

Press:Catalog,

  1. 2nd CATALOG to enter the command catalog
  2. T to skip to command starting with T
  3. Scroll up to STATWIZARD ON and select it

Calculator Compatibility

TI-84/+/SE 2.55 MP

Token Size

2 bytes

The STATWIZARD ON command enables the use of the Stat Wizard, added in 2.55MP, for statistic and distribution commands as well as seq(.

Advanced

Formulas

Error Conditions

Related Commands

Statwizard Off

author: 'bsch2734/ Lavalamp Gaming'
description: 'The classic game of Mastermind. The calculator selects a four-digit code. Given a few hints, can you geuss it in 10 tries?'
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '1'
rpg: '0'
strategy: '1'
sports: '0'
casino: '0'
board: '1'
utility: '0'
misc: '0'
image: '/archives:mastermind/Screenshot.BMP'
download: MSTR5MND.zip
size: '2811'
unit: '1'

author: Programmingfreak
description: 'A simple game related to the old Galaga, played all on the home screen.'
arcade: '1'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '0'
image: /home/no_image_2.png
download: StarSmash.zip
size: '8'
unit: '2'

rad.png

Command Summary

Converts an angle measure to radians, if necessary.

Command Syntax

angle▶Rad

Menu Location

  • Press 2nd MATH to enter the MATH popup menu.
  • Press 2 to enter the Angle submenu.
  • Press B to select ▶Rad.

Calculator Compatibility

This command requires a TI-89 Titanium or Voyage 200 calculator with AMS version 3.00 or higher.

The ▶Rad command is used to convert both degrees and gradians into radians. (If the command is given a value in radians it returns that value unchanged).

If you do not specify what unit you want to be used (using either the r command, the ° command, or the G command), whatever default the calculator's mode is set to will be used. Here are some examples:

:setMode("ANGLE", "DEGREE")
:90▶Rad
           1
:90^r▶Rad
           90

It appears to be equivalent to the r command, but only on the TI-89 Titanium or Voyage 200.

Related Commands

With xLib grayscale is very easy and good. You might think now: Basic? Grayscale? I couldn't find a xLib command that does that? Then your right: there is not such a command. You'll have to trick a bit for it with recalling a pic very often in XOR-logic, so inversion.
So you have a normal screen and a other image that is recalled in XOR often.

For example, your screen is like this:
scaled.php?server=803&filename=screenp.jpg&res=medium
This is in pic 1:
scaled.php?server=16&filename=grauinvert.jpg&res=medium

Then you have this code:

:DelVar A
:Repeat A
:real(3,1,3,1,1
:getKey->A
:End

And till you press a key the screen will be like this:
scaled.php?server=94&filename=screenfertig.png&res=medium

Ok, as you may notice the image in pic 1 is very often recalled in XOR-logic, and that seems then as grey scale.

Now some training:
Try to make this sprite:
scaled.php?server=27&filename=spritebesipielgrau.jpg&res=mediumOk, the image that inverts everything is obvious, because it is just everywhere where it is supposed to be grey:
scaled.php?server=848&filename=spritebesipielinvert.jpg&res=mediumMore complicated is the image that should be displayed a the beginning. You might think of this:
scaled.php?server=17&filename=spritebesipieldispfalsc.jpg&res=medium
It would work out, but the grey wouldn't look to good.Better is this:
scaled.php?server=43&filename=spritebesipieldispricht.jpg&res=medium
because of the checked tiles it seems better to the eye, it is a optical solution.
So if you have dcs the code to display that in grey till a key is pressed would be:
:real(0,0  //clears the screen
:identity(5,"00003C3C3C3C0000",0,0,1,8,0,0,0  //draws the sprite that will invert the screen
:identity(1,1,1  //saves it in pic 1
:real(0,0  //clears the screen
:identity(5,"FF81A995A99581FF",0,0,1,8,0,0,0  //the sprite, the grey thing is checked
:Repeat Ans  //repeats till something is in Ans
:real(3,1,3,1,1  //inverts the screen with pic 1
:getKey  //puts the Key in Ans
:End

Routine Summary

Bitwise operations on a decimal representation of binary data

Inputs

D — the Decimal that represents the binary data
I — the Index of the bit you will check/change

Outputs

Ans the checked bit or the changed decimal representation

Variables Used

D, I, Ans

Calculator Compatibility

TI-83/84/+/SE

When you have a program with lots of bivalent information — for example, a RPG with open/closed doors, defeated/undefeated bosses, completed/uncompleted quests, etc. — you could store all of this data in a list. However, lists tend to become rather large, so compression is vital.

First let's have a glance at how this will work. For example, there are six locations in a RPG that a player might have visited or not, which is stored as 1 or 0, respectively. As a list, we would have something like this:

:{1,0,0,1,1,0

But if you know a thing about binary, you know that 100110b equals 38d in decimal notation (if this confuses you, please read through the binary and hexadecimal page first). We can store up to 44 "bits" of information in just one variable! The reason we can store a maximum of 44 bits in one variable is because of the internal rounding that the calculator does.

So imagine at a given moment the game needs to know if the player has been to area four. Continuing our example from above, we take the number 38 as the current value, which we know represents 100110, and for the sake of optimization we need to index this binary number as follows: 150403121100.

Using following routine, we extract the value of the bit with index I from its decimal representation D. In our example, I=4 and D=38

:int(2fPart(.5D/2^I

Ans will now contain the value of the bit with index I from the decimal notation D. In our example, Ans would be 0, location 4 was not yet visited by the player. Now all we need is ways to change that bit. If the player visits this location it would have to be changed to 1.

This routine deals with that, assuming Ans is the value of the flag (either one or zero, returned from the previous routine):

:D+2^Inot(Ans→D        //if Ans=1, nothing needs to be changed, and 0 is added to D
                       //if Ans=0 it needs to become 1, so 2^I is added to D, effectively setting the bit with index I to 1

Next routine does the exact opposite: it changes the value to 0

:D-Ans2^I→D

Finally, the last routine changes whatever value is in the current bit: 0 becomes 1 and 1 becomes 0.

:D+2^I(1-2Ans→D        //(1-2Ans) sets the sign: -1 if Ans was 1 and +1 if Ans was 0

Error Conditions

  • ERR:DATA TYPE is thrown if D or I is imaginary.
  • ERR:OVERFLOW is thrown if I>333 (though I shouldn't be this large with only 44 bits).
  • No errors will be thrown if I≥44 or D≥244, but data will get corrupted in the lower indexes because of rounding if D is changed.
  • No errors will be thrown if I<0, but D will become decimal if it gets changed.
  • No errors will be thrown if I or D are not whole, but data will be corrupted.

Routine Summary

These two routines convert binary to decimal and vice versa.

Inputs

D / Str1

Outputs

Ans / D

Variables Used

Str1, D, I

Calculator Compatibility

83/84+/SE

Author

Michael2_3B / BlackPilar

Bin▶Dec

:Input "BIN: ",Str1
:Delvar DFor(I,length(Str1),1,-1
:If "1"=sub(Str1,I,1
:D+2^(length(Str1)-I→D
:End

Dec▶Bin
" →Str1   //1 space character
Repeat not(D
D/2→D
sub("01",1+not(not(fPart(Ans))),1)+Str1→Str1
iPart(D→D
End
expr(sub(Str1,1,length(Str1)-1
DelVar Str1   //if you want to keep your binary number in the string, skip this

Bin▶Dec

The way that this function works is pretty simple, actually. First we get the user to tell us what the binary value they wish to convert is. Then we clear the variable D (making it zero by default), and being our loop, working backwards through the string. If the character is a "1", then that means that 2 (binary's base), is raised to that positions power, beginning with zero at the far left. We add the resulting power of two to our decimal value, and continue through the binary value.

Dec▶Bin

Here, we first initialize our string, which will hold the binary number until the end. D is the decimal number you want to convert. Our loop repeats itself until D=0, that way all values over 2 can be covered. Inside the loop, we divide D by 2 first. We then take the substring of "01" and add str1 after it, updating str1. The 0 in the string is selected to add if there is no remainder from D/2, and the 1 is selected if there is. After that, the integer part of D/2 is stored into D. Once everything is all done, we take the expr() of str1, excluding the last character which is the space character, putting the binary number into Ans. And of course, to clean up, we delete variable Str1.

Error Conditions

  • ERR:OVERFLOW is thrown in Bin▶Dec if the resulting decimal will be greater than 9e99.

Related Pages

There should be more of the list on the screen at once.

http://tibasicdev.wikidot.com/catalog

Glossary

Needs some examples of ways to use linking commands

http://tibasicdev.wikidot.com/linking

reference

Could use some shortening.

http://tibasicdev.wikidot.com/binandhex

Reference

The pros and cons could use expanding.

http://tibasicdev.wikidot.com/basicbuilder

Reference;Assembly

The ListPages module does not work recursively.

Probability functions are helpful for generating random numbers, and provide an element of variability in many calculator games. Examples include an asteroid game where you avoid a random map of asteroids with your ship while crossing the screen, and RPGs where opponents need to have slightly unpredictable power in their attacks.

Key Commands

The main commands to use in random number generation are rand and randInt(. By itself, rand generates a decimal number between 0 and 1. This number can be manipulated like any other number, making it very easy to set up a random event. Lets say you want to randomize the description of a character's death in an RPG. You want to say that the dragon ate him half the time, and that the dragon burnt him to a crisp the other half. This is how you could do that with rand.

:"The dragon ate him
:If int(2rand
:"The dragon burned him
:Output(1,1,Ans

This works because doubling the rand command gives you a number between 0 and 2. If rand is less than .5, it will be doubled to between 0 and 1 and converted to 0 as the integer side is empty. If the number is greater than .5, it will be converted to 1 by int(. Notice that because there is only one possible outcome where the random number is a positive integer, you don't need to check if it is exactly one. We'll show you in a minute how to generate lists with rand as well.

randInt( is useful for doing the same thing as above but in a more visually simple manner. Instead of needing to convert a random decimal to integers, the calculator does the work for you. It takes either 2 or 3 arguments. The first two are the minimum and maximum, and optionally you can add a third to create a list of integers. To create a list of 20 dice rolls, the code would be like this:

:randInt(1,6,20

The same can be accomplished with rand, albeit in a more complex manner. The rand command can create lists when you add parenthesis and an argument for the size of the list.
:1+int(6rand(20
<< Powers and Exponentials Table of Contents Trigonometry >>

There are several ways to manipulate complex numbers in the context of calculator programming. This lesson will look at how complex numbers work, the commands associated with them, and a simple application for the commands.

What are they?

A complex number is essentially what happens when you attempt to take an even root of a negative number. As a way of interpreting complex numbers, they are displayed as their rational part added with a multiple of the square root of -1. This second number is known as an imaginary number, because you cannot represent them on a normal coordinate graph. The square root of -1 is denoted as a lowercase i. This is what it usually looks like:

:5+6i

real( and imag(

The real( command is used to extract the first part of a complex number. Simply use the command like this:

:real(5+6i

This code will return the number 5 extracted from the complex number 5+6i. That's all there is to it.

The imag( command is used to extract the second part of a complex number, the imaginary part. It is used in the same way real( is.

:imag(5+6i

This will return the coefficient of i, which is 6.

Application

The main use of real( and imag( in programming is to compress 2 real variables into one complex variable. For instance, if you want the variable A to contain both the values of B and C, you can use the following code.

:B+Ci→A

To extract the independent values, use the real( and imag( commands you just learned about.
However, there is one small problem. Two real variables take up 36 bytes, but complex variables take up 27 bytes. This is only a compression of 9 bytes, and using the similar integer-decimal method saves you 18 bytes. But you can use both the integer-decimal method combined with the real-imaginary method to store 4 different variables in one, saving you a whopping 45 bytes of storage!
<< Trigonometry Table of Contents Summary >>

ncr.png

Command Summary

Performs the operation "n choose r" using n and r.

Command Syntax

nCr(expr1,expr2)

Menu Location

[Math][Probability][3]

Calculator Compatibility

This command works on all calculators.

This performs the operation "n choose r" where expr1 is n and expr2 is r.

:nCr(3,0)

Formulas

The formula used to obtain the result is:

(1)
\begin{align} \frac{n!}{r!(n-r)!} \end{align}

This is often referenced with Pascal's Triangle and binomial expansion as well as many areas of mathematics.

Related Commands

clrio.png

Command Summary

Clears the program IO screen

Command Syntax

Use on the homescreen or in a program. Invalid in a function.

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

Token Size

2 bytes

This is used to clear the IO buffer (not the home screen). The IO buffer is where any Output(), Disp, Pause, and any other commands that use the I/O buffer display results.

:ClrIO
:Disp "Hello"

Related Commands

randIntNoRep.gif

Command Summary

Used to create random lists

Command Syntax

randIntNoRep(start,end)

Menu Location

[Math][left][8]

Calculator Compatibility

OS 2.53MP and TI-84+/SE

Token Size

2 bytes (EF35h)

randIntNoRep( is used when you need to create a list of numbers in random order in which no integer is repeated. This command is useful for things such as simulating decks of cards. Commonly, before this command was introduced, the following code would shuffle a deck:

rand(52→L₂
seq(X,X,0,51→L₁
SortA(L₂,L₁

This result can now be achieved with the following code:
randIntNoRep(0,51→L₁

Advanced Uses

seed→rand affects the output of randIntNoRep(

What this does is quite simple. When you seed rand, then the next time you use randIntNoRep(, you will get a result that will be fairly random, but the same on all calculators. This allows several things to be possible, including password protection and encryption. For example, if you were to use the following code, you could encrypt and decrypt messages only if you use the same encryption value. In this example, Str1 contains the message:

Decode:

"ABCDEFGHIJKLMNOPQRSTUVWXYZ .!,0123456789→Str2
Input "CODE:",A
A→rand
randIntNoRep(1,length(Str2→L1
length(Str1→B
".
For(A,1,B
Ans+sub(Str2,sum(cumSum(L1=inString(Str2,sub(Str1,A,1)))),1
End
sub(Ans,2,B

Encode:
"ABCDEFGHIJKLMNOPQRSTUVWXYZ .!,0123456789→Str2
Input "CODE:",A
A→rand
length(Str2→C
randIntNoRep(1,Ans→L1
length(Str1→B
".
For(A,1,B
Ans+sub(Str2,L1(C+1-inString(Str2,sub(Str1,A,1))),1
End
sub(Ans,2,B

The output strings are in Ans

Related Commands

setfold.png

Command Summary

A short description of what the command does.

Command Syntax

setFold(foldername)

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

Token Size

X byte(s)

This command is used to set the current folder. The folder must exist, otherwise the function produces an error. This is a way around this error:

:example()
:Prgm
:Try
:setFold(fold1)
:Else
:ClrErr
:NewFold(fold1)
:EndTry

Advanced Uses

If you are changing the current folder, but want to set it back later, the getFold() command is not required to store the old folder name.
For example:

:foldset()
:Prgm
:Local a
:getFold()→a
:setFold(fold1)
    ...
:setFold(#a)
:EndPrgm

does the same thing as
:foldset2()
:Prgm
:Local a
:setFold(fold1)→a
    ...
:setFold(#a)
:EndPrgm

Error Conditions

420 - Invalid Folder Name happens when the folder does not exist.

Related Commands

Routine Summary

This routine uses the PxlHorz function to invert the graph screen.

Inputs

None

Outputs

The graph screen is inverted as a result of this program.

Variables Used

i - a counter variable
size - the size of the graph screen window in pixels
All of these are locally declared.

Calculator Compatibility

TI-89/92/+/V200

:invert()
:Prgm
:Local i,size
:when(getConfg()[10]=160,76,102)→size
:For i,0,size
: PxlHorz i,-1
:EndFor
:EndPrgm

The -1 at the end of PxlHorz is a flag that tells the system to invert all pixels along the line. I chose PxlHorz because this requires less lines to be drawn than PxlVert does.

Error Conditions

None

Another important class of math functions deals with powers, logarithms, and exponents.

^ operator

This operator, found on the keyboard, is the exponent operator. It will raise a number to a power.

-1, 2, 3

These are shortcuts for the reciprocal, square, and cube of a number, respectively. -1 and 2 can be found on the keyboard, while 3 can be pasted by pressing MATH, 3.

Logarithms: log(, ln(

The log( and ln( functions, both available from the keyboard, will calculate the logarithms to base 10 and base e, respectively.
To get logarithms to other bases, use the following formula:

:log(x)/log(b)

where b is the desired base.

A useful use of log( is to determine how many digits an integer has. An integer n will have

:int(log(abs(n)))+1

digits in base 10.

10^(, e^(, E

These functions can be found on the keyboard, by pressing 2nd plus the respective logarithm key. Of course you could always type these out one character at a time, but using shortcuts takes less bytes. The E (EE on the keypad) denotes and integer power of 10, and is commonly used for scientific notation. E cannot be used with variables or fractional exponents, but it is about twice as fast as 10^(.

Roots: √(, ³√(, ˣ√(

These functions take the square root, cube root, and nth root of a number, respectively.

:5ˣ√(2)

will give the same result as
:2^(1/5)

namely, the 5th root of 2.
<< Numbers Menu Table of Contents Probability >>

Inputs

string - A string

Outputs

The reversal of the input string, or an empty string if the input is not a string.

Variables Used

s, temp, i
All are created locally in the program.

Calculator Compatibility

TI-89/92/+/V200

:reverse(s)
:Func
:Local i,temp
:""→temp
:If getType(s)=getType(temp) Then
: For i,1,dim(s)
:  mid(s,i,1)&temp→temp
: EndFor
:EndIf
:EndFunc

This function requires the user to enter a string as an argument. Many would object that a "return" is needed at the end. This is not true, because, if there is no "return" statement, the calculator automatically returns the last value that it calculated.

Error Conditions

None

setdate.png

Command Syntax

setDate(year, month, day)

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command requires a calculator with AMS version 2.07 or higher (it will also work on any TI-89 Titanium or Voyage 200 calculator)

This command sets the calculator's date to whatever is specified in the command. The year must fall in the range 1997 to 2132 for this command to work.

:setDate(2001, 10, 31)
:      {2001, 11, 1}

The above example has set the calculator's date to October 31st, 2001, and the date it was set at originally was November 1st, 2001.

Error Conditions

40 - Domain error happens when the year is outside of the range of 1997 to 2132, or the month is above or below 0 to 12, or the date is above or below 0 to 31.

Related Commands

timecnv.png

Command Summary

Converts seconds into a list containing days, hours, minutes, and seconds.

Command Syntax

dayOfWk(seconds)

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command requires a calculator with AMS version 2.07 or higher (it will also work on any TI-89 Titanium or Voyage 200 calculator)

This command converts a number of seconds into a list containing {days, hours, minutes, seconds}.

:timeCnv(152442117)
:      {1764 9 1 57}

The above example has converted 152,442,117 seconds into 1764 days, 9 hours, 1 minute, and 57 seconds.

Advanced Uses

This command can be used to easily convert the output of the startTmr() or the checkTmr() commands to a more readable and understandable format.

Related Commands

dayofwk.png

Command Summary

Returns an integer from 1-7 that shows what day of week it is for a specific date.

Command Syntax

dayOfWk(year, month, day)

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command requires a calculator with AMS version 2.07 or higher (it will also work on any TI-89 Titanium or Voyage 200 calculator)

The dayOfWk command returns an integer from 1 through 7 which shows what day of the week it was on a certain date. The Ti-89 Titanium manual says that this function may not give accurate results for years prior to 1583 (pre-Gregorian calendar).

Integer value: Day of the week:
1 Sunday
2 Monday
3 Tuesday
4 Wednesday
5 Thursday
6 Friday
7 Saturday
:dayOfWk(1948,9,6)
:      2
:dayOfWk(1600,1,15)
:      7

The above examples find that September 6th,1948 was a Monday and that January 15th, 1600 was a Saturday. It also works with future dates, in case you want to use that in a program.

Related Commands

Mar 23 By today, 167 out of 366 command pages have been written in the command index! There's only 16 more to halfway!

newpic.png

Command Summary

Forms a new picture out of a n x 2 matrix.

Command Syntax

NewPic matrix, picVar[, maxRow][, maxColumn]

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

This command forms a new picture from a matrix. The matrix must have only 2 columns, and should contain as many rows as there are "on" pixels (darkened pixels) in the image. If the picture variable specified already exists, this command will overwrite it. This command takes each row of the matrix, and forms pixel coordinates from the two numbers there. The optional arguments maxRow and maxColumn specify the boundaries of the picture, so this is a good way to form a small sprite from a matrix.

:newPic [1,1;2,2;3,3;4,4;5,5], picline

The above code would form a picture named "picline" which would have pixels at (1,1),(2,2),(3,3),(4,4), and (5,5), which would basically be a straight line.

Error Conditions

260 - Domain error happens when an element of the matrix is outside the screen range..

230 - Dimension error happens when The matrix has more or less then 2 columns..

Related Commands

See Also

stopic.png

Command Summary

Stores a picture variable at [PxlRow, PxlColumn] with [width, height]

Command Syntax

StoPic picVar,[PxlRow, PxlColumn][,width, height]

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

This command is used to store a picture that is on your calculator's graphscreen. This is useful for sprites in programs, where you can draw a sprite and save it to a picture that you can later redraw on a background. It is also useful for saving a copy of whatever you are drawing, so that it is not accidentally deleted if you graph something… The row and column arguments specify where on the graphscreen should be stored. Also the width and height arguments specify how tall or wide the stored area should be. The default for the row and column is (0,0), which is the top left corner of the graphscreen. The default width and height is the whole screen.

:StoPic 2a, 2,7,10,10

The above code would take a 10 x 10 square of the graphscreen with the top corner being at (2,7), ans it would store whatever is there to the picture variable "2a".

Error Conditions

260 - Domain error happens when the [row][,column] argument is outside the screen range..

Related Commands

See Also

cyclepic.png

Command Summary

Displays picture variables in a cycle for a given amount of time per picture.

Command Syntax

CyclePic picNameString, number of pictures [[,wait][,cycles][,direction]]

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

This command displays several picture variables in a cycle, with each picture getting an optional wait time, number of cycles, and the direction to display the pictures in. For instance, if you have saved 5 pictures: pic1, pic2, pic3, pic4, pic5, then you could do this to display them all: CyclePic "pic", 5, 3, 2, -1. This would display all 5 pictures for 3 seconds each, for 2 cycles, and backward, meaning it would display picture 5 first…

:CyclePic "ham", 3, 1.5, 6, 1

The above code would display pictures "ham1", "ham2", and "ham3" in that order for 1.5 seconds each, and for 6 cycles.

Advanced Uses

This command can be used to create a handy slideshow style program, or it can be used to display a sprite so it looks like it is moving.

Error Conditions

960 - Undefined variable happens when the picture variables specified do not exist..

Related Commands

rplcpic.png

Command Summary

Replaces whatever is on the graphscreen with a picture variable at [row][, column]

Command Syntax

RplcPic picVar,[row][, column]

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

This command replaces whatever is on the screen at a specific spot ([row][,column]). If no row or column is specified, the default is the upper left corner (0,0). If the picture is less than the full screen, only the spot at which the picture is placed will be removed. If you do not want anything replaced, use RclPic instead…

Error Conditions

260 - Domain error happens when the [row,column] argument is outside the screen range..

960 - Undefined variable happens when the picture variable specified does not exist..

Related Commands

See Also

xorpic.png

Command Summary

Logically "xors" a picture variable and the graph screen at [row][, column]

Command Syntax

AndPic picVar,[row][, column]

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

This command logically takes the picture variable specified, and takes the current graph, and it finds the points at which only the graph or only the picture have pixels, but turns off the points at which both have pixels, and it displays them only. If specified, [row,column] tells where the top left corner of the picture is to be placed. If not specified, the default is (0,0), which is the top left corner of the screen.

Error Conditions

260 - Domain error happens when the [row][,column] argument is outside the screen range..

960 - Undefined variable happens when the picture variable specified does not exist..

Related Commands

See Also

andpic.png

Command Summary

Logically "ands" a picture variable and the graph screen at [row, column]

Command Syntax

AndPic picVar,[row, column]

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

The AndPic command logically takes the picture variable specified, and takes the current graph, and it finds the points at which both the graph and the picture have pixels, and it displays them only. If specified, [row,column] tells where the top left corner of the picture is to be placed. If not specified, the default is (0,0), which is the top left corner of the screen.

Error Conditions

260 - Domain error happens when the [row,column] argument is outside the screen range..

960 - Undefined variable happens when the picture variable specified does not exist..

Related Commands

See Also

getfold.png

Command Summary

Returns the name of the current folder.

Command Syntax

getFold()

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

This command returns the name of the current folder as a string. This will usually return "main", as main is the default folder for your calculator. It is used to check which folder you calculator is in while you are inside a program.

:getFold()
:           "main"

Related Commands

fnon.png

Command Summary

This command turns on all or a group of functions.

Command Syntax

FnOn [optional function numbers]

Menu Location

  • Press F4 from the Homescreen to enter the OTHER menu.
  • Press 7 to select the FnOn command.

Calculator Compatibility

This command works on all calculators.

The FnOn command turns on one or a group of functions. The optional argument specifies which functions are to be turned on, and if there is no argument, then all the functions are turned on, not just the specified functions. This is used mostly to turn back on functions after they are turned off by the similar FnOff command, or it is used to turn back on functions after a program that has used the graphscreen.

:FnOff
:FnOn 4,7,9,20

The above code will turn off all functions, and then it will turn on only functions 4, 7, 9, and 20. This is useful if you want to graph only a few functions, but still have the rest of the functions stored in the calculator.

Error Conditions

260 - Domain error happens when the optional function argument is not in the range 1-99.

Related Commands

Round.png

Command Summary

Truncates a number to a specified number of decimal places.

Command Syntax

round(value[,number of decimal places to round to])

Menu Location

  • Press 2nd MATH to enter the MATH popup menu.
  • Press 1 to enter the Number submenu.
  • Press 3 to select round(.

Calculator Compatibility

This command works on all calculators.

Token Size

1 byte

The round command takes whatever value you give it, and it rounds the value to a given number of decimal places. For instance round(9.7,0) will return 10, since rounding to 0 decimal places will return the closest whole number. Another example would be if you entered round(5.46338,3) which would return 5.463, since it rounded 5.46338 to 3 decimal places. The round function can round 0 to 12 decimal places, and if you enter a value outside that range, you will get a domain error. Strangely enough, if you enter an imaginary number into the round() command, nothing happens and the calculator returns the same function in a simplified form.

:round(99.35847475,5)
:         99.35847
:round(4.392i,2)
:         round(4.392*i,2.)
:round(2.348972,2i)
:         round(2.348972,2*i)

Unexpected results

Your calculator may also round, say for instance if you do this:

:round(2.4573485645,11)

If your calculator is set to float or to fix at 10 or less, the calculator will round the number that comes out of the function. The function above should return 2.4573485645, since that is less than 11 digits, but if your calculator is set to "Float 6" it will return 2.457349 instead of what you expected.

Error Conditions

260 - Domain error happens when the number of decimal points to round to is not in the range 0-12.

Related Commands

getDate.png

Command Summary

Returns the current date set on the calculator and returns it in list format.

Command Syntax

getDate()

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command requires a calculator with AMS version 2.07 or higher (it will also work on any TI-89 Titanium or Voyage 200 calculator)

Token Size

3 bytes

The getDate() command checks the date that the calculator is set to, and then returns it in a list format. The list will always be in the format {year, month, day}. To change this list to another format, you can use the closely related getDtStr() option, which just returns the date in a string format, not as a list. The setDtFmt() command does not work on this command, but it will change the format that the calculator returns the getDtStr() command as.

For example, if the calculator's date was set to March 14th, 2011, the getDate() command would return the following:

:getDate()
:     {2011 3 14}

Related Commands

Mar 16 New technique added (text wrapper)
A simple text wrapper has been added and can be viewed here.

Routine Summary

Wraps text on the screen whenever you want. (Preserves space functionality.)

Inputs

Str1/Ans — String to wrap

Outputs

Text on screen

Variables Used

R, C, I, Str1, Ans

Calculator Compatibility

TI-83/84+/SE

Author

BlakPilar

Code (Graph Screen)

:"YAY, I MADE A LINEºWRAPPER FOR (ALMOST)ºANY LENGTH OF TEXT!º =D→Str1
:ClrDraw
:DispGraph
:DelVar RDelVar CFor(I,1,length(Str1
:If C<91 and "º"≠sub(Str1,I,1
:Then
:If " "≠sub(Str1,I,1
:Text(R,C,sub(Str1,I,1
:C+4→C
:If I<length(Str1)-1:Ans-2(" "≠sub(Str1,I,1→C
:Else
:DelVar CR+6→R
:End
:C+4(C>89→C
:I-(C>89→I
:End

Explanation (Graph Screen)

NOTE: The string declaration can easily be changed to "Ans→Str1" as long as you are 100% certain that Ans will be a string.

The first two lines after the string are self-explanatory (I hope). We first need to store zero to R and C (this is done by using DelVar), which will be used as our row and column variables. We then start a loop which will only execute while in the string.

The first If statement that we encounter checks for our new line character, which in this case is used as the degree sign (2ND+APPS>1). If the current character is not our new line character, and it is not a space, we display it and add 4 to our column variable.

With our third If statement, we check to see if we are still in the string. If we are, and the next character is a space, we subtract two from the column variable. The number 2 can be changed to whatever you want the word spacing to be (TI-OS default is 1).

Finally, we reach our Else, which is what will happen if the current character is the new line character. All we do is reset the column, and add six to the row (again, the number 6 can be easily changed for line spacing). Simple as that!

Note, this will also wrap text in case you forget the new line character.

Code (Home Screen)

:"WOOT, NOW IT'S A LINEºWRAPPER FOR THE HOMEºSCREEN! =]→Str1
:ClrHome
:1→R:1→C
:For(I,1,length(Str1
:If C≠17 and "º"≠sub(Str1,I,1
:Then
:Output(R,C,sub(Str1,I,1
:C+1→C
:Else
:I-(C=17→I
:1→C:R+1→R
:End
:If R=9:Stop
:End

Explanation (Home Screen)

NOTE: As with the graph screen version, the string declaration can easily be changed to "Ans→Str1" as long as you are 100% certain that Ans will be a string.

This isn't that different from the graph screen version. We just have to keep in mind that the home screen only has an 8x16 dimension and is monospaced (each character is the same width and height), so we need to adjust our variables accordingly. The row can have a max of 8, and the column can have a max of 16. Each's minimum is 1.

As we display text, we check to see if the current character is our new line character. If it isn't, then we go through our displaying. If it is, then we change our variables.

author: 'Zeda E.'
description: 'This is my version of Tic-Tac-Toe that includes options to go against the calculator… be ware, the calc can be pretty good. For a challenge, try playing as O.'
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '1'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '0'
image: '/archives:tic-tac-toe-with-ai/TTT.GIF'
download: TTT.zip
size: '819'
unit: '1'

author: 'Zeda Elnara'
description: 'Math Attack! is a "game" I made two years ago but I never released it. All it is meant to do is stretch your brain by quizzing you on basic math.'
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '1'
image: '/archives:math-attack/MathAttack.gif'
download: MathAttack.zip
size: '1103'
unit: '1'

Command Summary

Scales window settings relative to pixel length and height

Command Syntax

ZFracX

Menu Location

[Zoom][Alpha][Apps]

Calculator Compatibility

OS 2.53MP+

Token Size

2 bytes

ZFracX refers to a collection of Zoom commands in for the OS 2.53MP and up. The calculator boasts six such commands, each replacing X with a fraction of some sort. The commands all essentially operate in the same manner, so they are all covered here on this page.

This command centers the origin of the graph and makes each pixel X units tall and wide where "X" refers to the suffix of the command. For example, ZFrac1/3 makes each pixel a length of and height of 1/3, which means that each square unit would be a 3x3 square of pixels. It also sets Xscale and Yscale to 1.

It is useful when the users wants each pixel to be a uniform length and height, though other commands such as ZSquare, ZDecimal, and ZInteger also create a friendly window, and being more compatible, they would be more useful in programming across calculators.

The following is a list of the available ZFracX commands:

  • ZFrac1/2
  • ZFrac1/3
  • ZFrac1/4
  • ZFrac1/5
  • ZFrac1/8
  • ZFrac1/10

Related Commands

toolbar-separator.png This article is a stub. You can help TI-Basic Developer by expanding it.

Command Summary

Puts Quadrant 1 in the viewing window.

Command Syntax

none

Menu Location

[Zoom][Alpha][Math]

Calculator Compatibility

OS 2.53MP and above

Token Size

2 bytes

ZQuadrant1 was introduced in OS 2.53MP. As it's name might imply, it puts Quadrant I in the viewing window (the upper-left quadrant). Here are the window settings it affects:

  • Xmin is set to 0 and Xmax is set to 9.4 making each pixel .1 units.
  • Ymin is set to 0 and Ymax is set to 9.4 (each pixel is 47/310 units)
  • Xscl and Yscl are set to 1
  • ΔX is set to .1
  • ΔY is set to 47/310
  • Xres is set to 1

This command does not seem to work in programs.

Related Commands

Table of Contents

Review

  1. Where can you find most drawing commands?
  2. What does a GDB store?
  3. What does a Pic store?
  4. Which command allows you to select a mark type?
  5. Are the coordinates the same for Point and Pixel Commands?
  6. What do you do you enable the fast circle flag?
  7. How do you erase a line?
  8. How do you get large text on the graphscreen?

Exercises

  1. Create a program that inverts random blocks of the graph screen.
  2. Create a program that uses text sprites to make a drawing, then store that to a Pic.
<< Summary Table of Contents Sample Program: Pong >>

author: 'Mohammad Adib'
description: "Beta 4. A DoodleJump Clone made with Axe Parser. Latest Talk:\nhttp://www.omnimaga.org/index.php?board=158.0"
arcade: '1'
graphics: '1'
platform: '1'
puzzle: '0'
rpg: '0'
strategy: '1'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '1'
image: '/archives:doodlejump/beta%204.gif'
download: DoodleJumpBeta4.8xk
size: '20560'
unit: '1'

Member

author: BlakPilar
description: 'Have you ever wanted to get some of those pretty nifty ASCII characters, such as the arrows, or subscript numbers? Well with this program, you can! I recommend just sending this to your archive and running it with a shell (such as MirageOS) so that it does not get deleted, as the program stores its awesome characters into Str7!'
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '1'
misc: '0'
image: /home/no_image_2.png
download: CHARS.8xp
size: '169'
unit: '1'

author: 'Mohammad Adib'
description: 'A basketball shooting game. has 1 player vs. AI, 2 player, and practice modes. fun to play, includes AI, stats at the end, and a practice mode. It is related to foul shot by N*E*V*U*M_X although, the original idea came to me at PE class in school. '
arcade: '1'
graphics: '1'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '1'
sports: '1'
casino: '0'
board: '0'
utility: '0'
misc: '1'
image: '/archives:ownage-hoops/shot.gif'
download: OwnageHoops.zip
size: '9000'
unit: '1'

Nov 05 Added new page about recently developed routine.
samplescreenshot.gif

Routine Summary

Retrieves a word from an indexed string of words with an index number.

Inputs

A - The word's index number
Str0 - The index of words

Outputs

Str1 - The word

Variables Used

A, Str0, Str1

Calculator Compatibility

TI-83/84/+/SE

Author

ADeadBody

Authors

ADeadBody

:"000Word......001another..."→Str0    
:sub(Str0,3+inString(Str0,sub("0123456789",iPart(A/100)+1,1)+sub("0123456789",10fPart(iPart(A/10)/10)+1,1)+sub("0123456789",10fPart(A/10)+1,1)),10)→Str1

The routine converts the number into a string then searches for that in the string of words and stores the characters that follow it. Input in some 3 digit number ex: 001 would correspond to word 001. 102 would correspond to word 102. The routine itself can store up to 1000 10 letter words. I developed this for the purpose of storing and retrieving Pokemon names in the game I am developing but I am sure that there are other uses.

  • Acceptable inputs: zero, positive integers up to 999
  • Error inducing inputs: decimals, negative numbers, numbers over 1000

This example of the routine would display "helloworld",

:1→A
:"000worldhello001helloworld"→Str0
:sub(Str0,3+inString(Str0,sub("0123456789",iPart(A/100)+1,1)+sub("0123456789",10fPart(iPart(A/10)/10),1))+1,1)+sub("0123456789",10fPart(A/10)+1,1)),10)→Str1
:Disp Str1

If A were 0 instead of 1, then the output would be "worldhello".
In this modified version of the code it would output "helloworlditsme" a 15 letter code while still only displaying 10 letter words for any other input. You can see how by looking at the end of the 3rd line of programming it adds a value of 5 to the length of the outputted string under the condition of A being equal to 1

:1→A
:"000worldhello001helloworlditsme002helloworld"→Str0
:sub(Str0,3+inString(Str0,sub("0123456789",iPart(A/010)+1,1)+sub("0123456789",10fPart(iPart(A/10)/10),1))+1,1)+sub("0123456789",10fPart(A/10)+1,1)),10+5(A=1))→Str1
:Disp Str1

Error Conditions

  • ERR:INVALID DIM is thrown when the input number is either over 999 or under 0

Related Routines

author: 'Mark Radocy'
description: "Pick a direction, and the player will move in that direction until it hits another block, when it will stop.\n\nIt can then be moved again the same way. Continue until the block reaches the finish.\n\nJust don't go off the screen, or it's game over!\n- Contains 18 levels with autosaving\n- Works with mirage OS"
arcade: '1'
graphics: '0'
platform: '0'
puzzle: '1'
rpg: '0'
strategy: '1'
sports: '0'
casino: '0'
board: '1'
utility: '0'
misc: '1'
image: 'archives:anbox/TITLE.PNG'
download: anbox.zip
size: '9873'
unit: '1'

This command will open up a template that allows you to evaluate an expression in sigma notation.
This command is accessible by pressing ALPHA then WINDOW then 2.
This command is especially useful for statistics and algebra.
It is also available in the programming mode. You can access it either through the catalog or the same way specified above.
The syntax for this command is

Σ(Expression,Variable,Starting number,Ending number)

An example would be to determine the sum of 2*X for X going from 1 to 10.
It would look like this:
Σ(2X,X,1,10

The result would be
110

n/d_Un/d is the command for switching between an improper fraction and a mixed number.
It is accessible by pressing ALPHA then Y= then 3.

n/d is the template for entering a simple fraction.
n/d is accessible by pressing ALPHA then Y= then enter.

Command Summary

Mode command that sets Answers to AUTO.

Command Syntax

AUTO Answer

Menu Location

Press:

  1. MODE
  2. DOWN until you see Answers
  3. ENTER on AUTO

Alternatively, access the catalog.

Calculator Compatibility

TI-84 2.53MP only

Token Size

2 bytes

The AUTO Answer command is a mode command that changes the Answers mode to AUTO. The AUTO mode is in essence the same mode that lower OS models use. The calculator will evaluate a numerical expression and return a decimal or number in scientific notation, unless ►Frac is used.

In the Mathprint mode, no noticeable difference is seen unless the answer is converted to a fraction.

Related Commands

Command Summary

Mode command that puts the calculator into Classic mode.

Command Syntax

CLASSIC

Menu Location

Press:

  1. MODE
  2. DOWN until you reach MathPrint or Classic
  3. ENTER on Classic

Alternatively, use the catalog.

Calculator Compatibility

TI-84 2.53MP only

Token Size

2 bytes

CLASSIC will put the calculator into Classic mode as opposed to MathPrint mode. The Classic mode will make the calculator display everything as pre-MathPrint OS would, including input. For instance, rather than superscripting exponents as MathPrint mode would, Classic mode uses the simple caret syntax (^).

MathPrint mode:
24
     16

Classic mode:
2^4
     16

Advanced Uses

When in Classic mode, text and numbers are displayed much faster on the home screen and the function menus load faster. This can be useful in games that use the home screen, or just with calculations in general.

Related Commands

DECPIC.gif

Command Summary

Mode command that sets Answers to DEC.

Command Syntax

DEC Answer

Menu Location

Press:

  1. MODE
  2. DOWN until you see Answers
  3. ENTER on DEC

Alternatively, access the catalog.

Calculator Compatibility

TI-84 2.53MP only

Token Size

2 bytes

The DEC Answer command is a mode command that changes the Answers mode to DEC. DEC mode is very similar to the AUTO mode in which the calculator will display all answers in decimal form unless the returned number is an integer. Fractions will only be displayed with use of the ►Frac command.

Related Commands

FD2.gif

Command Summary

Converts a number between fraction form and decimal form.

Command Syntax

number►F◄►D

Menu Location

Press:

  1. MATH
  2. RIGHT to NUM
  3. ALPHA B

Alternatively, access the catalog.

Calculator Compatibility

TI-84 2.53MP only

Token Size

2 bytes

The ►F◄►D command is used to convert a number from fraction form to decimal form, or vice versa. Regardless of what form the given number is, this command is meant to automatically determine the form so that it returns the other. It is in essence a combination of the ►Frac and ►Dec commands, applying ►Frac if the input is in decimal form and ►Dec if it is a fraction.

7.5►F◄ ►D
        15/2
Ans►F◄ ►D
        7.5

Related Commands

Un/d is a template that allows you to input a fraction with a whole number in front of it.
Un/d is accessible from most screens by pressing ALPHA and Y= then 2.
What this command does is that it adds the whole number to the fraction. It does not calculate a product but instead it calculates an addition.

Frac Answer changes the mode to display a fraction whenever possible. That is to say it will display 1/2 as a fraction but irrational numbers will not be displayed as fraction. Numbers such as Pi will still be displayed as decimals.

N is a variable, much like A or B or C, etc. Anything you can do with A you can do with N.

MATHPRINT is a command that simply changes the display mode on the home screen. This command is useful if you want to display a number as a fraction, otherwise it does nothing. Be aware that if you use this and then use an output( command to display a numerical variable , the output command may not display.

min.png

Command Summary

Finds the lowest numerical value from arguements

Command Syntax

min(arg1,[arg2])

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

Token Size

X

The min() Command can be executed in two different ways.

It can find the lowest of two numbers:

min(0,1)
//returns 0

It can find the lowest number in a list:

min({0,1,2})
//returns 0

Advanced Uses

For advanced users, the min command can also have its two arguments replaced with lists, as long as the two lists have the same dimensions and only include numbers. min(list,list) returns a list, with min having been done on each pair of items, as is the custom for lists in functions.

min({123},{321})
//returns {1,2,1}

It also works in much the same way for matrices.

min([[1,2,3][1,2,3]],[[3,2,1][3,2,1]])
//returns [[1,2,1][1,2,1]]

Optimization

If comparing two numbers, it is slightly faster to compare the two as two arguments than to have them in a list.

:min({1,2})
can be
:min(1,2)

The first example takes 13 seconds for 1000 repetitions, while the second takes only 9. When using the min command repetitively, this will add up.

Related Commands

author: Sleight
description: "A highly graphical side-scrolling, game in which you play a UFO shooting up buildings. Unique in that it redraws the WHOLE SCREEN for every frame, thanks to statplots and pics.\n—\nInstructions:\n\nControls: up/down moves, 2nd/del fires beam, alpha/stat fires super beam, graph boosts to top of screen.\n\nScoring: taller buildings= less points, shorter buildings= more points, extra life every 250 points.\n\nEnergy: super beam takes 2 energy, boost takes 3 energy, extra energy every 50 points\n—\nTi-83+ not recommended for speed."
arcade: '1'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '0'
image: 'archives:mission:raze/Screenshot.jpg'
download: MSSNRAZE.8xp
size: '2357'
unit: '1'

Avneesh wrote:
comment Fantastic
logBASE.gif

Command Summary

Allows you to find the log of a number using any base you want

Command Syntax

logBASE(value,base)

Menu Location

Press:

  1. ALPHA, then F2 (which is located over the WINDOW button)
  2. 5 or arrow keys to move down to logBASE(

or

  1. MATH
  2. A or arrow keys to move down to logBASE(

Calculator Compatibility

TI-84+SE with TI-OS 2.53 MP

Token Size

2 byte

The logBASE( command is an upgrade from the log( command allowing you to input any base you want rather than being restricted to base 10. The command searches for the exponent that base b must be raised to get the given value.

This command can be used on both the home screen and while programming. If you are using CLASSIC mode, the command looks like below:

logBASE(8,2)
            3

But in MATHPRINT mode, looks like the below:

log2(8)
            3

Formulas

The log in base b can also be found using the ln( or log( commands. This is shown below:

(1)
\begin{align} \log_bx = {\ln x \over \ln b} = {\log x \over \log b} \end{align}

Where in the case of the calculator, base c is 10. In other words, the two entries below are equivalent:

ln(x)/ln(b

can be

logBASE(x,b

The logBASE( command in this case saves one byte, so it is a minor optimization. However, for compatibility across calculators it would be better to use the traditional method in programs as it is only a byte more yet can be used by calculators that do not have the 2.53 MP OS.

Error Conditions

  • ERR:DOMAIN occurs if you try to input 0 as value.

Related Commands

remainder.gif

Command Summary

Same as modulus - divides a number, but returns the remainder.

Command Syntax

remainder(dividend,divisor)

Menu Location

Press:

  1. MATH to enter the Math menu
  2. Use arrows to go to the NUM menu
  3. 0 to choose remainder(, or use arrows

Calculator Compatibility

TI-84+SE with TI-OS 2.53 MP

Token Size

2 byte

The remainder( function divides the first number given by the second number, and returns the remainder similar to the modulus. This command is only available if you have the TI-84+ Silver Edition and the new 2.53 MP operating system on your calculator. This command can be used both on the Home screen and when programming.

See the code segment below for an example:

remainder(30,7)

This returns a value of 2 because 30 divided by 7 has a remainder of 2.

Compatability

As said earlier this command only works on a TI-84+ Silver Edition with the 2.53 MP OS, so this will not work on earlier OSes. To avoid non-portability, use the following code.

BfPart(A/B

instead of

remainder(A,B

fPart is a command that works in more OSes and more models.
They also are the same size (5 bytes), as long as B is one byte

Error Conditions

  • ERR:DIVIDE BY 0 occurs if you try to input 0 as the divisor.
  • ERR:DOMAIN occurs if the divisor or dividend is either negative or less than 0
  • ERR:SYNTAX occurs if the divisor or dividend is a symbol, or character or non-real number
  • ERR:DATA TYPE occurs if the divisor or dividend is not a number, (i.e. text)

Related Commands

author: Zaetsi
description: 'After turning off Ned''s hose each night, escape his yard without stepping on any Lawn Gnomes. Each night you disrupt Ned''s activities, he''ll add more Lawn Gnomes for you to dodge. If you stay in on place for too long you''ll trip his alarm system, so you can''t stop moving.'
arcade: '1'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '0'
image: '/archives:the-valley-of-the-gnomes/VALLEY%20OF%20THE%20GNOMES.JPG'
download: VALGNOME.8xp
size: '2133'
unit: '1'

author: Zaetsi
description: 'Take on your next door neighbor Ned in the water balloon war of the century. Change the angle and power of your throws to hit Ned and collect points. More Power = More Points. The one with more points after 11 volleys shall be hailed Master of the Universe.'
arcade: '1'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '1'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '0'
image: '/archives:yard-wars/yard_wars.jpg'
download: YARDWARS.8xp
size: '4161'
unit: '1'

May 27 Due to the release of a new OS by TI (2.53MP), new commands have been added to the Command Index.

author: patriotsfan
description: 'Use this program to strike it rich and become the next millionaire! Although, I can''t guarantee it will happen!'
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '1'
image: '/archives:lottery/results.gif'
download: Lottery.zip
size: '342'
unit: '1'

isprime.png

Command Summary

Returns true for prime arguments and false for composite arguments.

Command Syntax

isPrime(expression)

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

The isPrime() command returns a Boolean value based on whether or not the passed argument is prime or not. True is returned for prime numbers and false is returned for composite numbers. A number is prime if its divisors are only 1 and itself. For instance, the number 23 is considered prime because no two positive integers but 1 and 23 can multiply to get 23. For the calculator, 1 isn't considered prime.

isPrime(23)
       true
isPrime(24)
       false

Algorithm

According to TI, the algorithm run by the calculators is as follows:

"The algorithms used by the TI-89 family, TI-92 family, and Voyage 200 calculators divides by successive primes through the largest one less than 216. It does not actually keep a table or use a sieve to create these divisors, but cyclically adds the sequence of increments 2, 2, 4, 2, 4, 2, 4, 6, 2, 6 to generate these primes plus a few extra harmless composites.

TI-92 Plus and TI-89 family start the same way, except that they stop this trial division after trial divisor 1021, then switch to a relatively fast Monte-Carlo test that determines whether the number is certainly composite or is almost certainly prime. The isPrime() function stops at this point returning either false or (almost certainly) true."

author: BlakPilar
description: 'This is a text-based version of Assassin''s creed. If you have any questions, comments, or find any bugs, let me know at blakpilar AT gmail DOT com'
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '1'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '0'
image: /home/no_image_2.png
download: AC2WM.zip
size: '27'
unit: '2'

How Ti Basic Programs Are Executed

Ti Basic Programs are executed by calling built-in functions already written for you on the calculator. Ti Basic Programs are really not executed, they are interpreted by the calculator's operating system. That means that the calculator 'reads' the programs, and then executes the appropriate function. For each command that is read in the calculator, several native commands may be executed. This means that the calculator's Central Processing Unit will have to do more processing to execute the program. This is usually not a problem for small, simple programs; but if you are considering making a game, or other complex application, it is probably a good idea to use Assembly as your programing language.

How Assembly Programs are Executed

Assembly programs are executed natively. That means that the Central Processing Unit is able to directly interpret your code, instead of having to rely on commands from the operating system. This also gives you more control over the calculator.

Too much control?

Before sending ANY assembly program to your calculator, make sure it is from a verified source. This is because when you execute an Assembly Program, you give the program complete control of the calculator. An assembly program can directly edit both RAM, and ROM, enabling it to erase the Operating System, install a virus, log your keystrokes. This is an Assembly Program is a Native Application, meaning it is directly executed by the Central Processing Unit.

Should I use Assembly?

If you are creating a rather simple program, or function , then you should probably stick with Ti-Basic. But, if you are creating a more complex program, like a game, then you might want to consider Assembly. Because Assembly runs faster, your game will have better performance.

Where can I start?

The two main types of assembly programs are either written directly in Assembly, or in a Compiled language, like C. A compiled language is translated into Assembly, making it easier to learn. However, programming directly in assembly gives you more control.

I am a beginner at assembly

If you are a complete beginner, and have never written in C, or C++, then you should start out with C. C is easier to write, and runs just about as fast.

Start with the list of tutorials below:

I have Programmed in C, or C++ before

I am completely familiar with the concepts of programming, and have had experience in a least one medium-low level language. This does NOT include C#, VB.NET, or JAVA, as these are considered high level languages.

Start with the list of tutorials below:

<< Saving Data Overview Dialogs >>

This will host all of the google analytics data.

Date uploaded Link
Jan 21, 2011 — Apr 19, 2011 Google Analytics PDF
Oct 25, 2010 — Jan 21, 2011 Google Analytics PDF
Jul 29, 2010 — Oct 25, 2010 Google Analytics PDF
May 2, 2010 — Jul 29, 2010 Google Analytics PDF
Mar 31, 2010 — Apr 30, 2010 Google Analytics PDF
Jan — March 30, 2009 Google Analytics PDF
Nov — March 30, 2009 Google Analytics PDF
Nov — Jan 30, 2009 Google Analytics PDF
Nov — Dec 21, 2008 Google Analytics PDF
Oct — Nov 9, 2008 Google Analytics PDF

fnoff.png

Command Summary

This command turns off all or a group of functions.

Command Syntax

FnOff [optional function numbers]

Menu Location

  • Press F4 from the Homescreen to enter the OTHER menu.
  • Press 8 to select the FnOff command.

Calculator Compatibility

This command works on all calculators.

The FnOff Command turns Graph functions off. The FnOff Command command can be used to clear the graph of any functions that the user has created before running any programs that might require the graph screen. The FnOff command can also be used to turn just one or a few functions off by stating the function number after the command FnOff:

:FnOn
:FnOff 2,3,4

The above code will turn on all functions, and then it will turn off only functions 2, 3, and 4. You can use this if you only want one or two functions to display, but you want all the functions entered so that they can be quickly graphed.

Error Conditions

260 - Domain error happens when the optional function argument is not in the range 1-99.

Related Commands

Apr 23 James Kanjo redesigned the Become a Member page so that it is easier for people to become members of the TI-Basic Developer community

Okay, so the program works on mac. Well, almost. I still have to finish a few things, but since I can send byes on the mac side, I should be able to start with the main java wrapper. I still don't know about windows, though.

The Ans token

What is Ans?

Ans is a special variable that holds the value returned by the last expression or command. To understand the concept of the Ans we'll go to the main calculator screen and type a number:

:8
        8
:Ans
        8

Whenever an object (a variable or a list or a string …) appears in the right side of the Main screen it is assigned to Ans. Take a look at the next example:

:8
        8
:Ans
        8
:10
        10
:Ans
        10
:"HELLO"
    HELLO
:Ans
    HELLO
:{1,2,3}
        {1,2,3}
:Ans
        {1,2,3}
And so on...

As you can see the Ans can be everything. Now look at the next example:

:4→A
        4
:Ans
        4

So when you set a variable its value becomes the Ans, and in a program it works the same way.

Why should I use Ans?

Basically the Ans command works like some kind of calculator cache. It is the last value assigned and because of how it is built it is faster to use the Ans (just like a computer gets data from the cache faster than from the main memory). So if I use an Ans command (when possible) instead, the program will process that information faster and the user will be happier.

Some uses of the Ans:

Lets see the next example:

:Repeat Ans=21
:getkey
:If Ans
:Disp "A KEY WAS PRESSED
:If not(Ans
:Disp "NO KEY PRESSED
:End

In this example, the calculator tells the user whether a key is pressed or not. Let's have a closer look: The Repeat D=21 will execute the instructions underneath it until the Ans is equal to 21. The getKey command (we'll expand on that later) will check the key you are pressing and return the number equivalent to the key (if you are not pressing any it returns 0). Because the getKey value is stored in Ans, we do not need to use any other variables. So if Ans is different from 0, we display "A KEY WAS PRESSED." If it isn't different, we display "NO KEY PRESSED." Easy, huh?

Please note that Disp, along with some other functions, won't affect the value of the Ans command.

More on the Subject

An in depth look at the Ans variable can be found here.

<< Loops Table of Contents Chapter Summary >>

Conditionals

Conditionals in TI-Basic are slightly different than other programming language's conditionals. The first thing you need to understand is that an If condition tests a number. So:

:If 0
This won't show up
:If 1
This will show up
:If 2
This will show up

When the If condition tests the 0 number it returns false, so the code underneath it won't be displayed. Now if the If comes across a 1, it returns true and executes the code that follows. Now you might be asking yourself "And what about the If 2?" well in every single programming language the 0 number is equivalent to false and all numbers but 0 are equivalent to true. So when you use an If condition you are testing if a number is 0 or not 0, if it is false or not false (true) and execute (or not) the instructions that follow.

But what about this:

:1->A
:If A=0
This won't show up
:If A=1
This will show up
:If A=2
This won't show up

Well, in this case, you may think the If statement isn't testing a number but a condition. Well, you are wrong. Look at the following piece of code:

:1=1
        1
:1=4
        0

If you type the 1=1 in the main calculator screen you get a 1, meaning that it is true. If you type 1=4 you get a 0, it is false. So, what we can conclude is very simple: conditions return a number whether they are true or false. When comparing two numbers (or variables) the calculator will see if it is true or false and send a number: 0 if it is false; 1 if it is true; So as you can see, the calculator works an If condition by calculating the Something = Something condition, returns a number and if it is 1, executes the following code, if it is 0, it doesn't.

Now it makes sense, doesn't it? That's why we talked about If 0 and If 1 in the beginning.
So this:

:1->A
:If A=1
Do something

Is the same as this:

:If 1
Do something

Of course the first one can be false if you change the variable's value, but in this case, it is all the same thing.

Cool examples that use conditions

1. The best example of the use of conditions is the collision code located here: Collision. It uses conditions to know if the place the character is supposed to go is "walkable" or not.

2. Another rather cool example is the area calculator. You know that an area can't be negative so the program can't return a negative area. Take a look at the next example:

:Prompt A,B
:A*B->C
:If A>0 and B>0
:Then
:Disp C
:Else
:Disp 0

Looks good doesn't it? Well but it isn't. It is true that it correctly displays only positive areas but there's a simpler way of doing it:

:Prompt A,B
:AB(A>0 and B>0)->C
:Disp C

In this case, with only 3 lines of code, we do the same thing as above and we save memory. Of course, this may seem stupid because it only saves a few bits, but in a bigger game production the bits turn into bytes and then KiloBytes and the game becomes very big and unusable.
Let's just go through the code: The Prompt asks the user to give some input. Then it calculates A*B and multiplies it by the result of the condition (A>0 and B>0). So if both are greater then 0, then the condition returns 1 and C becomes A*B. If they aren't the condition returns 0 and C becomes 0. So there are no negative values!!

3. What if you want to know if a certain pixel of the screen is on? Let's see:

:45->X
:55->Y
:If pxl-Test(Y,X)
Do something

Using the pxl-Test( command and an If statement we get the job done!! The pxl-Test( returns a number (1 or 0) whether the pixel indicated between brackets is on or off.

Some tips:

Conditions are very handy to test variables and stuff, but have to be used wisely. A very common mistake when using If conditions is forgetting the Then after the If and writing more than one line. See the next example:

:0->A
:1->B
:If A≠B
:Disp A
:Disp B
:End

WRONG… Here the Then command is missing so the calculator would return an error like: ERR: SYNTAX, because there was an extra End. Here's the correct way:

:0->A
:1->B
:If A≠B:Then
:Disp A
:Disp B
:End

And there you have it…

<< Logic Operations Table of Contents Loops Optimization >>

Loops have various uses (we'll see them later), but basically loops are blocks of code that execute themselves a defined number of times. As you know there are 3 types of loops: the For( loop, the While( loop, and the Repeat( loop. These are very handy since your program ends when it reaches the end of the code, so if you are developing a game or so you need the code to flow correctly and execute over and over (for example for checking if you pressed a key and making your character walk).

101 Uses for Loops

While loops may not have exactly 101 uses, they are some of the most spectacular pieces of code that enable iterations to be made so that a game can constantly update itself or so a math program can perform a specific algorithm. The uses below represent only a few of the ways loops can be utilized.

Time Delay

A loop can be seen by many perspectives but if you think that each instruction takes time to be processed you can think (correctly) that each loop takes time to execute its code even if it is an empty loop. Watch the following example:

:For(A,1,10)
:End

As you can see, there's nothing inside that For( loop but it still takes time to be executed. So you can use a For( loop as a method of making your program sleep. Think of this as a timed Pause that delays certain parts of the program. Later you'll see an application of this use.

Note: The use of rand can also achieve a time delay, and is considerably smaller. The only difference is that rand will update Ans, while this loop method will not.

Game Iterations

Take a look at this example:

:Repeat K=21
...
Game instructions...
...
:End

In this case, the program will wait until the user presses the 2nd key, represented by K, otherwise it will keep the game running. You can include key press checkers, character movement, etc. See the next example:

:Repeat Ans=45
:A+sum(ΔList(Ans={25,34→A
:B+sum(ΔList(K={24,26→B
:getKey→K
:End

This loop is used to iterate a particular game function, in this case updating the coordinates of an object (A,B). Under certain conditions, it is actually beneficial to use the getKey as the last line of the code so that in the loop condition, Ans can be used, which may help speed the loop up.

Drawing

Because loops execute instructions over and over with different numbers, they can be used to draw. Just watch:

:For(A,5,50
:Pxl-on(25,A
:End

This will draw a horizontal line between pixel 5 and pixel 50 and because of the way loops work, it will look like it is actually being drawn by somebody. This is different from using the Line( command, which makes the line appear instantaneously. Rather, this block writes each pixel one at a time, starting with (25,5), then (25,6), and so on. The next code block uses two loops together:

:For(A,5,50
:For(B,5,50
:Pxl-on(A,B
:End
:End

This code will draw a square. This time, when one line is drawn, the next line begins to be drawn, until each row is complete.

Write Text

Writing text is relatively simple on the calculator. However, the calculator does it without any animation. Try the following code:

:ClrDraw
:"HELLO WORLD
:For(A,1,length(Ans
:Text(5,4A+5,sub(Ans,A,1
:End

This will write out each letter one at a time, as if it were being typed. The For( loop runs though each character in the string (which is Ans), and for each one, it types the letter in the next slot. However, this code is too fast. What other tool do we have…

:ClrDraw
:"HELLO WORLD
:For(A,1,length(Ans
:For(B,1,30
:End
:Text(5,4A+5,sub(Ans,A,1
:End

We can use the time delay from before! Using a For( loop, we can delay the program every iteration and thus overall slow down the process. Since we require Ans not to be updated, the For( loop delay works perfectly.

Challenge: Can you make a code that does the same as the above, but smaller?

Tips

Try to not nest loops in a game. "What is a nested loop?" you may be asking: a nested loop is a loop inside a loop, for example:

:WHILE A=2
:REAPEAT B=2
:FOR (C,1,10)
:END
:END
:END

Sometimes they are the only way of doing things, like checking all the screen for on pixels or whatever, but if you want to execute the same instruction 5 times in a game, do it like this:

:1->A
:WHILE A=2
Game instructions...
:IF A>6:THEN
Your instructions
:A+1->A
:END
:END

And not:

:WHILE A=2
Game instructions...
:FOR (A,1,5)
Your instructions
:END
:END

Why? Because if you did so, you wouldn't be executing any instructions (like character walking or so) besides what's in the For( loop and your game flow would be ruined…

Have fun with loops!!

<< Conditionals Table of Contents Optimization: The Graph Screen >>
Name: No name given
Author: No author given
Download: Download Unavailable
Compatibility: Parent page not set
File Size: No size given
No description given
Name: {$name}
Author: {$author}
Download: [{$downloadUrl} {$downloadName}]
Compatibility: {$compatibility}
File Size: {$size}
{$description}
Name: No name given
Author: No author given
Download: Download Unavailable
Compatibility: Parent page not set
File Size: No size given
No description given
Name: {$name}
Author: {$author}
Download: [{$downloadUrl} {$downloadName}]
Compatibility: {$compatibility}
File Size: {$size}
{$description}

Included page "inc:tablet2-backend" does not exist (create it now)

Name: {$name}
Author: {$author}
Download: [{$downloadUrl} {$downloadName}]
Compatibility: {$compatibility}
File Size: {$size}
{$description}

Routine Summary

Determines whether an input is a number or list.

Inputs

Ans - the number or list to examine

Outputs

Ans - 1 if the input is a number, 0 if it is a list

Variables Used

A [,∟A if input is a string]

Calculator Compatibility

TI-83/84/+/SE

Author

Deep Thought

:For(A,465230.61649186,465230.61649186
:Ans->A
:A=Ans(1

You can replace 465230.61649186 with any obscure and nearly impossible number.

If Ans is a list, it is stored to ∟A. A remains whatever that number is, and A=Ans(1 (assuming that Ans as a list has at least one value) returns false. If Ans is a number, it is stored into A, thus A=Ans(1 (Ans times 1) returns true.

The For( command is used to avoid updating Ans. End should be added to the end if this routine is used inside a larger program.

Here are a few tips on what to do next:

1- Get an idea for a game or an application. Try this website if you do not feel inspired: http://www.ticalc.org/programming/ideas/;
2- Try making it by following some of the articles writen in this website;
3- Optimize the code and add some cool menus and stuff;
4- Send it into your computer (you will require a usb link cable [usually comes with the calculator…] and this software: TI Connect);
5- Try protecting the code of your game/app, use this software: TI Graph link 83 - plus, open your file, check the protected box and save it;
6- Now create a zip file with your game/app files, a read me (with some instructions) and a screenshot (use the TI connect to accomplish it, it has a app included [the icon of a camera - when you open the program - in the main menu]);
7- Send it to the web to get some feedback, this website is good: http://www.ticalc.org/cgi-bin/file_upload.pl?a=1, or try including a link to a page in this website, where you include your game/app download;

Well, now off you go to the TI-BASIC Programming world, happy programming!

P.S. If you get really addicted to calculator programming, try learning "Assembly" to the calculator (the programming language of your application), just google it…

<< Review Table of Contents Project Ideas >>

Simple homescreen menu without using the menu( command.

ClrHome
Disp ">OPTION 1"," OPTION 2"," OPTION 3     // note the spaces before OPTION 2 and OPTION 3
1->A
Repeat Ans=105
If Ans
Output(A,1,"                               // one space
min(3,max(1,A+sum(List(Ans={25,34->A       // the List has an implied delta sign (triangle) before it.
Output(A,1,">
getKey
End
If A=1
Disp "OPTION 1 ACTION
If A=2
Disp "OPTION 2 ACTION
If A=3
"OPTION 3 ACTION

Simple graphscreen menu.

ClrDraw
Horizontal Ymin
Horizontal Ymax
Vertical Xmax
Vertical Xmin
Text(-1,3,35,"MENU
Text(20,25,">OPTION 1
Text(26,29,"OPTION 2
Text(32,29,"OPTION 3
20->A
Repeat Ans=105
If Ans
Text(A,25,"                                                              // Four spaces
min(32,max(20,Ans+6sum(List(Ans={25,34->A               // The "List" has an implied delta (little triangle) before it.
Text(A,25,">
getKey
End
If A=20
Disp "OPTION 1 ACTION
If A=26
Disp "OPTION 2 ACTION
If A=32
"OPTION 3 ACTION

You can adjust the Text( values to determine what spacing you would like.

Mar 11 The archives have been upgraded to make uploading process much easier.

facingtomorrow

6x9 connect four game skeleton
just like the real thing
includes graphics, animation, save/load game, resets settings on exit and 2 player gameplay
does not include AI or win checking

PLEASE REMOVE the following words that do NOT describe your program:
Arcade Graphics Puzzle Strategy Board Misc

http://tibasicdev.wikidot.com/local--files/challenges:25/scn.png

CONECTFR.zip

952 bytes

author: 'skwerlman (David Birnhak)'
description: 'This program looks at two waves of the form ASin(BX+C) and graphs their interference pattern.'
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '1'
misc: '0'
image: '/archives:wave-interference-grapher/waveinterferencedemo(1).gif'
download: WAVES.zip
size: '235'
unit: '1'

Name: {$name}
Author: {$author}
Download: {$download}
Compatibility: {$compatibility}
File Size: {$size}
{$description}

gcd.png

Command Summary

Finds the Greatest Common Denominator

Command Syntax

gcd(int1,int2)

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

The gcd( command is used, as its name implies, to find the greatest common divisor of two numbers.

:gcd(351,65)
              returns 13

Error Conditions

260 - Domain error happens when an argument is not real.

Related Commands

Well, animation in any Ti basic program can be a problem, though 68k calculators have better capability for animations. There are a virtually unlimited number of picture names, and folders allow for even more possibilities. Due to the limitations of a calculator's basic graphics, the best way to animate is to use a series of pre-drawn pictures, displayed one after another. Even this has limitations, as the relatively slow refresh rate can make animations seem choppy. Also, each frame must be created individually, so animation design is very time-consuming. If anyone could please elaborate on this, it would be greatly appreciated.

<< Sprites Overview Compression >>

author: EragonFreakMaster
description: 'Tools to help in your Geometry or Trigonometry class, solving anything to do with triangles.'
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '1'
misc: '0'
image: /home/no_image_2.png
download: TrigTools.zip
size: '6223'
unit: '1'

bin.png

Command Summary

The ▶Bin command converts numbers into binary.

Command Syntax

int▶Bin

Menu Location

  1. [2nd]
  2. [Math]
  3. [up or E]
  4. [right]
  5. [4]

Calculator Compatibility

This command works on all calculators.

Token Size

4 bytes

▶Bin converts an integer from decimal (base 10) or hexadecimal (base 16) into binary (base 2).

:15▶Bin 
         0b1111
:0h15▶Bin
         0b10101

Related Commands

Routine Summary

Determines whether an input is a number or string.

Inputs

Ans - the number or string to examine

Outputs

Ans - 1 if the input is a number, 0 if it is a string

Variables Used

A, B [,∟A, ∟B if input is a string]

Calculator Compatibility

TI-83/84/+/SE

Author

bfr

URL: [http://www.unitedti.org/forum/index.php?showtopic=9191]

Download

routine.zip

:DelVar AFor(B,1,1
:Ans->A
:Ans->B
:A=B

If Ans is a string, it is stored to ∟A and ∟B. A remains 0, B remains 1, and A=B returns false. If Ans is a number, it is stored into both A and B, thus A=B returns true.

The For( command is used to avoid updating Ans. If this routine is used in a larger program and the input can be stored into a more permanent variable, For(B,1,1 can become 1->B. If this is not possible, the For( statement should have an End added.

Dec 17 Congrats to AJLitzau13 for winning Challenge 9!

author: 'Kieran Berard'
description: 'This program guesses any whole number from 1-63. It will guess it on the first try…'
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '1'
image: '/archives:magic-mindz/Magic%20Mindz.gif'
download: Magic_Minds.zip
size: '4292'
unit: '1'

line.png

Command Summary

Draws a line between a set of two coordinates.

Command Syntax

Line xStart, yStart, xEnd, yEnd, drawmode

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

Token Size

X byte(s)

The line command draws a line between two points. By default, the drawing mode is set to 1, which draws the line normally, so it doesn't have to be included if drawing a regular line.

Line 0, 3, 0, 9

Advanced Uses

The drawmode can be set to 0 to draw a "white" line, which will remove the pixels on the path of the line.

Line 0, 3, 0, 9, 0 //removes the line

You can also invert pixels on the line using -1 as the number argument.
Line 0, 3, 0, 9, -1

Related Commands

  1. Creating graphics is done on the graph screen, not the home screen.
  2. On the graph screen, locations are given either as point or pixel coordinates.
  3. Pixel coordinates start with (0,0) at the top left corner, like on the homescreen, but increment in individual pixels.
  4. Point coordinates depend on the window dimensions.
  5. You can adjust the window dimensions by manipulating the window variables and/or by using the zoom commands.
  6. You can also use the format commands to turn the axes off and other related things.
  7. You can save the window dimensions, format options, and other related things in a GBD. (Graph Database)
  8. Once you have the graph screen set up, you can draw on it using the draw commands.
  9. You can erase the graph screen with the ClrDraw command, and you can save what is on the graph screen in a Pic.(Picture)
  10. Unfortunately Pics can only store the entire screen. They also don't force pixels that are already black to become white; sometimes this can be a good thing.
  11. One particularly creative and effective way to create sprites is known as the text sprite method.This involves overlapping text to create sprites quickly.

Commands Introduced

<< Using Pictures Table of Contents Chapter Exercises >>

…that if you have a rather bulky matrix or list, you can store it as a string to one of the sequence variables, u,v,w and halve the size? Then, you can evaluate the expression using said variable and Ans(X) where X equals the list or matrix element you want?

IsLocked checks if a variable is locked.

o->var1
lock var1
islocked var1
      true
unlock var1
islocked var1
      false

isarchiv.png

Command Summary

Checks to see if a variable is archived

Command Syntax

isArchiv(variable)

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

Token Size

X byte(s)

The isArchiv() command checks if a variable is archived.

0->var1
Archive var1
IsArchiv var1
        true
UnArchiv var1
IsArchiv var1
        false

Related Commands

hex.png

Command Summary

Converts a number to a base-16 number.

Command Syntax

integer▶Hex

Menu Location

MATH/base

Calculator Compatibility

This command works on all calculators.

Token Size

2 bytex

The ▶Hex command takes an integer and converts it to hexadecimal, including the prefix "0h". Here is an example program.

15›Hex
//returns F
16›Hex
//returns 10
0b10000›Hex
//returns 20

Related Commands

The Disp command displays output in the Home App I/O screen.

prgmexmp()
Prgm
Request "Enter something",var1 © Get a value for var1
Disp "var1="&string(var1)
Pause
DelVar var1
ClrIO
DispHome
EndPrgm

unarchiv.png

Command Summary

Unarchives a given variable

Command Syntax

Unarchiv variable

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

The Unarchiv command removes a variable from the flash ROM.

Prgm
©                                //assuming var1 and var2 are actual variables
Archive var1,var2
isArchiv(var1)→check
Disp check
Pause
Unarchive var1,var2
Disphome
EndPrgm

Related Commands

unlock.png

Command Summary

Locks a given variable

Command Syntax

Unlock variable1

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

Token Size

2 byte(s)

The Unlock command unlocks locked variables. It is paired with the Lock command.

lock var1,var2
unlock var1,var2

Related Commands

lock.png

Command Summary

Locks the specified variables

Command Syntax

Lock var1, var2, etc

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

Token Size

X byte(s)

The lock command prevents a variable's value from changing. In programs and functions, lock is usually used to stop a variable from undesirably changing. If a variable is universally defined (like files in folders), the lock command has a popular purpose of making the variable constant (unchanging) throughout use in sets of programs.

input "Input var1 here: ",var1
lock var1
text "You can no longer change var1."
© var1 can now be used as a constant variable.
©... <program statements that require the value of var1>
prgm2() ©var1 may not change in any other programs.
unlock var1

Note: the © command will turn any code written until the next ':' into comments. (neat-freaks love this.)
Comments are very helpful for people who forget, especially when dealing with tricky commands and code. Using comments for the lock command will help you remember to unlock the variable when the time comes to delete it.

Related Commands

ztrumpet

Oasis is a basic shell that runs basic programs.
Oasis uses Celtic III (included).

PLEASE REMOVE the following words that do NOT describe your program:
Utility Misc

http://tibasicdev.wikidot.com/local--files/archives:oasis/Oasis.gif

Oasis.zip

2751

This program identifies whether a number is prime.

NOTE: This program does not display a correct result for 0, 1, or 2, which are special cases.

PROGRAM: PRIME
:ClrHome
:Prompt X
:­1→Y
:For(P,2,√(X)+1)
:If fPart(X/P)*P=0
:Then
:P→Y
:Goto E
:End
:End
:Lbl E
:If Y≠­1
:Then
:Disp X
:Disp "Composite"
:Disp "Divisible by"
:Disp Y
:End
:If Y=­1
:Then
:Disp X
:Disp "Is prime"
:End

(If you plan to copy and paste this string of code into a program editor remember to remove the colons.)

author: ztrumpet
description: "Oasis is a basic shell for your calculator that will run basic programs.\nYou must have Celtic III (included) to run Oasis."
arcade: '0'
graphics: '0'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '1'
misc: '1'
image: '/archives:oasis/Oasis.gif'
download: Oasis.zip
size: '2751'
unit: '1'

As proven there is very much intrested in this project. One on the main things to get clear is: Who joins? so far:

Matthias1992 (Me)
Sleight

author: Sleight
description: 'A 3D engine that draws rectangular prisms (any size, solid or transparent) on the graph screen using pseudo-one-point perspective. Also includes Cubes, a simple program that shows what it is capable of.'
arcade: '0'
graphics: '1'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '0'
sports: '0'
casino: '0'
board: '0'
utility: '1'
misc: '0'
image: '/archives:prisms/Prism.png'
download: PRISMS.8xp
size: '473'
unit: '1'

author: 'Roy S.'
description: 'A calculator version of the famous card game: BlackJack. Graphical, fully operational.'
arcade: '0'
graphics: '1'
platform: '0'
puzzle: '0'
rpg: '0'
strategy: '1'
sports: '0'
casino: '1'
board: '0'
utility: '0'
misc: '0'
image: '/archives:blackjack/SCREEN01.gif'
download: BJACK.8xp
size: '5488'
unit: '1'

Member

Member

Member

Joined Oct 26 Is Stranger does not match any existing user name

Time Zone: Not given

samplescreenshot.gif

Routine Summary

Outputs the number corresponding to a keypress.

Inputs

None

Outputs

Ans - The number pressed.

Calculator Compatibility

TI-83/84/+/SE

Authors

Unknown, Toothless the Night Fury

:Repeat Ans≤9
:Repeat Ans
:getKey
:End
:Ans(102≠Ans)-13int(Ans/13(2>abs(5-abs(5-abs(Ans-83
:End

The routine waits for a key that corresponds to a number 0-9. All magic is on the lengthy line.

An alternate method to this is an adaptation of the Key Code to Letter routine, written below. Both methods share very extremely fast speeds, but the alternate method uses slightly more bytes. However, it does have the advantage of converting keycodes to strings instead of numbers, has the added period, and can be easily converted to numbers (through expr) if needed (unlike the other way around).

:Repeat Ans>71 and min(Ans≠{75,81,85,91,95
:getKey
:End
:sub("789  456  123  0.",Ans-36-5int(.1Ans),1

Modifications

  • You can delete the :Repeat Ans<=9 :End loop to not wait
  • Delete the (102≠Ans) if you don't need the 0 number
  • Fixed from "Outputs the letter corresponding to a keypress." to "Outputs the number."
  • Added alternate method and general cleanup.

Error Conditions

None known.

Related Routines

samplescreenshot.gif

Routine Summary

Outputs a letter corresponding to a keypress.

Inputs

None

Outputs

Ans - the letter as a string

Calculator Compatibility

TI-83/84/+/SE

Authors

Weregoose

URL: Weregoosepage

Download

Routines.8xg

:Repeat Ans>34 and min(Ans≠{44,45,105
:getKey
:End
:sub("ABC**DEFGHIJKLMNOPQRSTUVWXYZθ'* :?",Ans-5int(.1Ans+4),1

The Repeat loop makes sure good input is passed.
The last line takes from the string the letter according to the keycode.

Error Conditions

None.

Related Routines

author: ztrumpet
description: "Drifter is a game in which you slide until you hit an object.\nThere are many pieces that you will come in contact with that change the direction you're going.\nCollect all the +s and/or numbers 1-9 then reach the flag to win.\nDrifter includes 16 levels and a custom level editor for endless hours of fun."
arcade: '1'
graphics: '0'
platform: '0'
puzzle: '1'
rpg: '0'
strategy: '1'
sports: '0'
casino: '0'
board: '0'
utility: '0'
misc: '0'
image: '/archives:drifter/drifter-video.gif'
download: drifter.zip
size: '11056'
unit: '1'

Alex Litzau

An efficient OS that lets you run and manage TI-Basic programs and get calculator information. It also has the option to use a USB mouse to control the cursor onscreen.

PLEASE REMOVE the following words that do NOT describe your program:
Utility

http://tibasicdev.wikidot.com/local--files/challenges:23/IlliniOS.gif

IlliniOS.zip

2,642 or 2,836 bytes

rclpic.png

Command Summary

Recalls a picture variable and the graph screen at [row][, column]

Command Syntax

RclPic picVar,[row][, column]

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command works on all calculators.

This command is used to recall (open) a picture you have saved on your calculator. This is normally used in programs, because you can open pictures from the graph when you are not running a program. It is very useful for sprites as well, as it can recall a picture variable on top of a background, without deleting any of the background. In a program, however, you can recall a different picture for a different input, as shown below:

:If a=16
:RclPic 2
:Else
:RclPic 3

Error Conditions

260 - Domain error happens when the [row][,column] argument is outside the screen range..

960 - Undefined variable happens when the picture variable specified does not exist..

Related Commands

See Also

dropdown.png

Command Summary

Creates a custom menu

Menu Location

Describe how to get the command from a menu.

Calculator Compatibility

This command works on all calculators.

Token Size

2 bytes

Similar to the Menu( command, the DropDown is used in a dialog box to make body text that includes a dropdown menu, with multiple options. This is good for use in text RPGs or game menus where a dialog box already exists and there isn't a need for another box. Look at this code for example:

:Dialog
:DropDown "Do you like food?", {"Yes", "No"}, t
:EndDlog

This will create a window with the title as "Do you like food" and the options as "Yes" and "No". "T" corresponds to the choice you selected For example, if you chose "Yes", the "T" would be equal to 1. However, if you pressed "No", then "T" would be equal to 2. Basically, the value of your chosen variable will correspond to the choice you made in the window.

Error Conditions

730 - Missing start or end of block syntax happens when the command isn't put between a Dialogue/EndDlog block.

Related Commands

Credits

Credits to an unknown user (who's account got deleted). He/she created the code and the first paragraph of the explanation.

Sep 28 Archives have been redesigned.

Changed the name of the game to [Technica: Clash of the Forces]. It's a completely different game from what I originally had. Get ready for this one; work starts after documentation is finished.

abs.png

Command Summary

Returns the absolute value of an argument.

Command Syntax

abs(expression)

Menu Location

  • Press 2nd MATH to enter the MATH popup menu.
  • Press 1 to enter the Number submenu.
  • Press 2 to select abs(.

Calculator Compatibility

This command works on all calculators.

The abs() command returns the absolute value of an expression. The absolute value of a real number is the number of units from 0 the number is. The absolute value of 7 for example is 7 becasue it is that many units away from zero. The absolute value of -7 however is 7. So it in a way gets rid of the negative.

The absolute value of a complex or imaginary number can also be taken, but it is done a little differently. If a complex number is written a+bi, then the absolute value of the number is √(a2+b2).

abs(5)
       5
abs(-5)
       5
abs(3+4i)
       5

Related Commands

Timothy

Do not process this dummy program!

This is a test for the new system. I want to see what errors out and what doesn't.

New line.

PLEASE REMOVE the following words that do NOT describe your program:
Platform Misc

http://tibasicdev.wikidot.com/local--files/home/no_image_2.png

Unavailable

1024 bytes

Oh my goodness. No wonder TI-Connect is so horrible. It's the calculators fault. Turns out, that to get one variable, you have to get a directory listing of every single one!!!! (That is to say, that I am working on it…)

Member

So I finally found a free USB logger, and could see the data sent/received. Yay!!! This project continues!!!

I have been busy with things, but this projects is not dead. I am trying to see the variable data from a transfer. If you have a program that can do that, would you just do the variable A as 267193, recieve it from your calc, then send it back, and send me what bytes were sent to/received from the calc. This is for USB btw.

settime.png

Command Summary

Sets the current time on the calculator's clock, returning the previous time setting.

Command Syntax

setTime(hours,minutes,seconds)

Menu Location

This command can't be found in any menu besides the command catalog.

Calculator Compatibility

This command requires a calculator with AMS version 2.07 or higher (it will also work on any TI-89 Titanium or Voyage 200 calculator)

Token Size

3 bytes

The setTime() command changes the time of day on the calculator's clock (give it the new time in hours, minutes, and seconds, in that order). The value it returns is the previous time setting, as a list of {hours,minutes,seconds}.

setTime() respects the current time zone: if you set the time to 8 AM, it will change the time to 8 AM in the time zone you're using, not necessarily to 8 AM GMT. Make sure to change the time zone before you set the time, if you plan to do both, or you'll get the wrong result.

The calculator measures time starting from 00:00 GMT on January 1, 1997. Although setDate() will reject any date earlier than that, with a combination of setTime() and setTmZn() you might actually end up with an earlier time than that. If this happens, the calculator keep counting the time correctly, but return a time of 00:00 GMT until it reaches a normally valid time.

A final quirk of setTime() is that it affects the output of startTmr() and checkTmr(). So if you're timing a section of your program, and use setTime() in the middle of that section, the time lapse will get thrown off.

Error Conditions

40 - Argument error happens when an invalid time is given.

Related Commands

(1)
\begin{equation} {$eqn} \end{equation}

Member

Member

@import url(http://static.wikidot.com/common--theme/co/css/style.css?0);
 
.code {
font-size: 105%;
}
 
.hidden-collapsible .collapsible-block-link {
    text-decoration:none;
}
 
.hover {color: #3B4;}
 
.hover span {display: none;}
 
.hover:hover span {
    position: absolute;
    display: inline;
    margin: 15px -20px;
    height: auto;
    max-width: 200px;
    background: #FFF;
    border: 2px solid #34B;
    color: #000;
    padding: 1em;
}
 
.menu .show {
    display: none;
    z-index: 9;
}
 
.default .show {
    display: block;
    z-index: 8;
}
 
.menu:hover .show {
    display: block;
}
 
.infobox{
    color: #FFFFFF;
}
 
.infobox a{
    color: #FFFFFF;
}
 
.blink, .blink a {
    text-decoration: blink;
}
 
#header {
    background: #202817;
    min-width: 800px;
    width:expression(document.body.clientWidth < 800? "800px" : "auto");
}
#header h1 {
  padding: 0;
  margin: 0;
  width: 800px; //735px; //789px;
  height: 69px;
  background: #141B0C;
  background-image: url(http://tibasicdev.wikidot.com/local--files/logo/Logo10C.PNG);
}
#header h1 a {
  padding: 0;
  margin: 0 320px 0 8px;
  width: 472px; //721px; //735px; //789px;
  height: 69px;
  display: block;
}
#header h1 span {
  display: none;
}
#top-bar {
  top: 69px;
  height: 21px;
  min-width: 976px;
  padding: 0;
  background-color: #5C634D;
  border-bottom: 2px solid #5C634D;
}
#top-bar  a, #top-bar li ul li a {
    background-color:#5C634D;
}
#top-bar a:hover, #top-bar li ul li a:hover {
    background-color:#5C634D;
}
#side-bar {
  min-width: 185px;
}
.special-collapsible .collapsible-block-unfolded .collapsible-block-link {
    font-weight: bold;
    padding-left: 0em;
}
.special-collapsible a {
    margin: 0;
    padding-top: 2px;
    padding-bottom: 2px;
    display: block;
    padding-left: 1em;
    border-bottom: 1px solid #BBBEAB;
    border-top: 1px solid #D2D3C6;
    color: #1E2B31;
    text-decoration: none;
}
#header h2 {
  display: none;
}
 
#license-areas {
  color: #E9DCE7;
  background: #5C634D;
}
#license-areas a {
  color: #E9DCE7;
  background: #5C634D;
}
 
table.charmap {
  background: white;
  border: #999 solid 1px;
  border-spacing: 2px;
  padding: .3em;
  table-collapse: collapse;
}
table.charmap tr td {
  text-align: center;
}
 
.wd-editor-toolbar-panel li.hseparator {
  background: url('http://tibasicdev.wikidot.com/local--files/home/toolbar-separator.png');
  width: 22px;
  height: 22px;
  margin: 1px;
}
 
@media print {
 
#print-head,#page-info,
#license-area,#print-footer {
  display: none !important;
}
 
div#page-content:after {
  text-align: center;
  width: auto !important;
  display: block !important;
  margin: 2em 0 0;
  clear: both !important;
  padding-top: .5em;
  border-top: 1px solid #000;
  content: "TI-Basic Developer © 2006-2009 — \"A wiki for the TI-Basic beginner and advanced alike!\"";
}
}
 
.taby .yui-navset .yui-nav a,
.taby .yui-navset .yui-navset-top .yui-nav a{
    background:#FFF;
    border:1px solid #AAA;
}
 
.taby .yui-navset .yui-nav .selected a,
.taby .yui-navset .yui-nav .selected a:focus,
.taby .yui-navset .yui-nav .selected a:hover {
    background:#F4F4F4;
    color:#222;
    border:1px solid #AAA;
}
 
.taby .yui-navset .yui-nav a:hover,
.taby .yui-navset .yui-nav a:focus {
    background:#EEEEEE;
}
 
.taby .yui-content{
    background:transparent;
    border:none;
}
 
.taby .yui-navset .yui-nav {
    border: 0;
}
 
#footer{
    background:#5C634D;
    border-color: #141B0C;
}
 
body{
    background:#E5E9D2;
}
#side-bar{
    background:#C6C9AD;
}
#side-bar li a{
    border-bottom: 1px solid #BBBEA7;
    border-top: 1px solid #D2D3C2;
}
Aug 27 James Kanjo made the site's CSS theme dynamic. You can manipulate the Site Theme or the Forum Theme without Administrator privileges and with instantaneous results.
@import url(http://static.wikidot.com/common--theme/co/css/style.css?0);
 
.code {
font-size: 105%;
}
 
.hidden-collapsible .collapsible-block-link {
    text-decoration:none;
}
 
#search-top-box, #login-status {
  margin-right: 4em !important;
}
 
.chars{
    position: absolute;
    top: 0;
    right: 0;
    z-index: 999;
}
 
.chars2{
    position: fixed;
    top: 0;
    right: 0;
    z-index: 1000;
}
 
.chars, .chars2 {
    text-align: center;
    border: 1px solid #999;
    padding: 0;
    margin: 0 0 0 0;
    background: #f7f7f7;
    font-family: Trebuchet MS, Trebuchet, Verdana, Arial, Helvetica;
}
 
.infos:after {
  float: right;
  content: "→∟‾×√Σ≠≥≤πΔχ▶ֿ¹²³L₁L₂L₃L₄L₅L₆≅ℕºθ÷±∠∞♦⇧∫∏©";
}
.pages-list {
  margin: 0.5em 0;
  padding: 0;
  display: block;
}
.pages-list div.pages-list-item {
  margin: 0;
  padding: 0;
  display: block;
}
.pages-list-item div.title {
  margin: 0;
  padding: 0;
}
.pages-list div.pages-list-item a {
  margin: 0;
  padding-top: 2px;
  padding-bottom: 2px;
  padding-left: 1em;
  color: #1E2B31;
  display: block;
  border-bottom: 1px solid #BBBEAB;
  border-top: 1px solid #D2D3C6;
  text-decoration: none;
}
.pages-list div.pages-list-item a:hover {
  background: #D1D3C3;
}
 
.infobox{
    color: #FFFFFF;
}
 
.infobox a{
    color: #FFFFFF;
}
 
#header {
    background: #OC141B;
    min-width: 800px;
    width:expression(document.body.clientWidth < 800? "800px" : "auto");
}
#header h1 {
  padding: 0;
  margin: 0;
  width: 800px; //735px; //789px;
  height: 69px;
  background: #OC141B;
  background-image: url(http://tibasicdev.wikidot.com/local--files/logo/Logo10B.PNG);
}
#header h1 a {
  padding: 0;
  margin: 0 320px 0 8px;
  width: 472px; //721px; //735px; //789px;
  height: 69px;
  display: block;
}
#header h1 span {
  display: none;
}
#top-bar {
  top: 69px;
  height: 21px;
  min-width: 976px;
  padding: 0;
  background-color: #4D5C63;
  border-bottom: 2px solid #4D5C63;
}
#top-bar  a, #top-bar li ul li a {
    background-color:#4D5C63;
}
#top-bar a:hover, #top-bar li ul li a:hover {
    background-color:#4D5C63;
}
#side-bar {
  min-width: 185px;
}
#header h2 {
  display: none;
}
 
#license-area {
  display: none !important;
}
 
table.charmap {
  background: white;
  border: #999 solid 1px;
  border-spacing: 2px;
  padding: .3em;
  table-collapse: collapse;
}
table.charmap tr td {
  text-align: center;
}
 
.wd-editor-toolbar-panel li.hseparator {
  background: url('http://tibasicdev.wikidot.com/local--files/home/toolbar-separator.png');
  width: 22px;
  height: 22px;
  margin: 1px;
}
 
@media print {
 
#print-head,#page-info,
#license-area,#print-footer {
  display: none !important;
}
 
div#page-content:after {
  text-align: center;
  width: auto !important;
  display: block !important;
  margin: 2em 0 0;
  clear: both !important;
  padding-top: .5em;
  border-top: 1px solid #000;
  content: "TI-Basic Developer © 2006-2009 — \"A wiki for the TI-Basic beginner and advanced alike!\"";
}
}
 
.werecode{
    font-family: 'Andale Mono', 'Courier New', Courier, monospace;
    font-size: 9pt;
    color: #11119C;
}
 
.ti83{
    font-family: Ti83pc,'Andale Mono','Courier New',Courier,monospace;
    border-left:3px dotted #000;
    background:#EEE;
    padding-left:3px;
    color:#367A4B;
    margin:3px 2em 5px 1em;
}
.nspire{
    background: #FFF;
    border: 1px dashed #DDD;
    padding-left:1em;
    margin: 1em 0 1em 0;
    font-family:'Arial Unicode MS',verdana,arial,helvetica,sans-serif;
    color: #222;
    letter-spacing:1.2pt;
}
@import url(/common--theme/co/css/style.css);
@import url(/local--code/css:archive);
@import url('http://css.wikidot.com/cssnippet:inline-hovertips/code_');
@import url('http://css.wikidot.com/cssnippet:external-link-indicators/code_');
 
.code {
    font-size: 105%;
}
 
.comments-box .code {
    max-height: 300px;
    overflow: auto;
}
 
.hidden-collapsible .collapsible-block-link {
    text-decoration:none;
}
 
.hover {color: #3B4;}
 
.hover span {display: none;}
 
.hover:hover span {
    position: absolute;
    display: inline;
    margin: 15px -20px;
    height: auto;
    max-width: 200px;
    background: #FFF;
    border: 2px solid #34B;
    color: #000;
    padding: 1em;
}
 
.menu .show {
    display: none;
    z-index: 9;
}
 
.default .show {
    display: block;
    z-index: 8;
}
 
.menu:hover .show {
    display: block;
}
 
.infobox{
    color: #FFFFFF;
}
 
.infobox a{
    color: #FFFFFF;
}
 
.blink, .blink a {
    text-decoration: blink;
}
 
#header {
    background: #172028;
    min-width: 800px;
    width:expression(document.body.clientWidth < 800? "800px" : "auto");
}
#header h1 {
  padding: 0;
  margin: 0;
  width: 800px; //735px; //789px;
  height: 69px;
  background: #OC141B;
  background-image: url(http://tibasicdev.wikidot.com/local--files/logo/Logo10B.PNG);
}
#header h1 a {
  padding: 0;
  margin: 0 320px 0 8px;
  width: 472px; //721px; //735px; //789px;
  height: 69px;
  display: block;
}
#header h1 span {
  display: none;
}
#top-bar {
  top: 69px;
  height: 21px;
  min-width: 976px;
  padding: 0;
  background-color: #4D5C63;
  border-bottom: 2px solid #4D5C63;
}
#top-bar  a, #top-bar li ul li a {
    background-color:#4D5C63;
}
#top-bar a:hover, #top-bar li ul li a:hover {
    background-color:#4D5C63;
}
#side-bar {
  min-width: 185px;
}
.special-collapsible .collapsible-block-unfolded .collapsible-block-link {
    font-weight: bold;
    padding-left: 0em;
}
.special-collapsible a {
    margin: 0;
    padding-top: 2px;
    padding-bottom: 2px;
    display: block;
    padding-left: 1em;
    border-bottom: 1px solid #BBBEAB;
    border-top: 1px solid #D2D3C6;
    color: #1E2B31;
    text-decoration: none;
}
#header h2 {
  display: none;
}
 
#license-areas {
  color: #E7E9DC;
  background: #4D5C63;
}
#license-areas a {
  color: #E7E9DC;
  background: #4D5C63;
}
 
table.charmap {
  background: white;
  border: #999 solid 1px;
  border-spacing: 2px;
  padding: .3em;
  table-collapse: collapse;
}
table.charmap tr td {
  text-align: center;
}
 
.wd-editor-toolbar-panel li.hseparator {
  background: url('http://tibasicdev.wikidot.com/local--files/home/toolbar-separator.png');
  width: 22px;
  height: 22px;
  margin: 1px;
}
 
@media print {
 
#print-head,#page-info,
#license-area,#print-footer {
  display: none !important;
}
 
div#page-content:after {
  text-align: center;
  width: auto !important;
  display: block !important;
  margin: 2em 0 0;
  clear: both !important;
  padding-top: .5em;
  border-top: 1px solid #000;
  content: "TI-Basic Developer © 2006-2009 — \"A wiki for the TI-Basic beginner and advanced alike!\"";
}
}
 
.taby .yui-navset .yui-nav a,
.taby .yui-navset .yui-navset-top .yui-nav a{
    background:#FFF;
    border:1px solid #AAA;
}
 
.taby .yui-navset .yui-nav .selected a,
.taby .yui-navset .yui-nav .selected a:focus,
.taby .yui-navset .yui-nav .selected a:hover {
    background:#F4F4F4;
    color:#222;
    border:1px solid #AAA;
}
 
.taby .yui-navset .yui-nav a:hover,
.taby .yui-navset .yui-nav a:focus {
    background:#EEEEEE;
}
 
.taby .yui-content{
    background:transparent;
    border:none;
}
 
.taby .yui-navset .yui-nav {
    border: 0;
}
 
.werecode{
    font-family: 'Andale Mono', 'Courier New', Courier, monospace;
    font-size: 9pt;
    color: #11119C;
}
 
.ti83{
    font-family: Ti83pc,'Andale Mono','Courier New',Courier,monospace;
    border-left:3px dotted #000;
    background:#EEE;
    padding-left:3px;
    color:#367A4B;
    margin:3px 2em 5px 1em;
}
.nspire{
    background: #FFF;
    border: 1px dashed #DDD;
    padding-left:1em;
    margin: 1em 0 1em 0;
    font-family:'Arial Unicode MS',verdana,arial,helvetica,sans-serif;
    color: #222;
    letter-spacing:1.2pt;
}
 
.Infobox{
    background: #FDFCF6;
    border: 1px solid #8D9CA3;
    font-size: 120%;
    width: auto;
    padding: 10px;
}
 
.image-box-heading{
    background: #4D5C63;
    color: #E7E9DC;
}
/* Teletype */
.tt {
    font-weight: 900;
}
/* Data Forms */
.form-table .form-value {display: inline-block;}
Name: Mix 'n Match
Author: Maarten Janssen
Download: Mix 'n Match
Compatibility: Parent page not set
File Size: 3020 bytes
Mix 'n Match is a Bejeweled type of game where you need to match at least three adjacent tiles of the same type and try to make cascading matches to score points.
The ListPages module does not work recursively.

csch.png

Command Summary

Takes the hyperbolic cosecant of a number.

Command Syntax

csch(value)

Menu Location

  • Press 2nd MATH to enter the MATH menu.
  • Press C to enter the Hyperbolic submenu.
  • Press 4 to select csch(.

Calculator Compatibility

This command requires a calculator with AMS version 2.07 or higher (it will also work on any TI-89 Titanium or Voyage 200 calculator)

Token Size

1 byte

The csch() command returns the hyperbolic cosecant of a number. Along with 11 other trig and hyperbolic functions, it was added in AMS version 2.07; on earlier versions, csch(x) can be replaced by 1/sinh(x).

As long as the calculator is in radian mode, csch() can be used with complex numbers according to the rule that csch(ix)=-csc(x)*i and csc(ix)=-csch(x)*i. This rule only works in radian mode, and csch() of a complex number will return a domain error when working in degrees or gradians.

Occasionally, csch() can compute an exact result; most of the time, the calculator will leave an expression with csch() alone unless it's in approximate mode (or you force an approximation). When csch() is used with symbolic expressions, the calculator can go back and forth between the csch() expression and its exponential equivalent.

:csch(0)
           undef
:expand(csch(x))
          1/(e^x+1)+1/(e^x-1)
:comDenom(1/(e^x+1)+1/(e^x-1))
          1/sinh(x)

If csch() is applied to a list, it will take the hyperbolic cosecant of every element in the list. However, it can't be applied to matrices the way sinh() can (this is probably an oversight; all the trig and hyperbolic functions that were present in all AMS versions work with matrices, but the ones added in version 2.07 do not).

Formulas

The definition of hyperbolic cosecant is, by analogy with csc(), the reciprocal of sinh():

(1)
\begin{align} \operatorname{csch}{x}=\frac{1}{\sinh{x}} = \frac{2}{e^x-e^{-x}} \end{align}

Error Conditions

260 - Domain error happens when taking csch() of a complex number in degree or gradian mode.

Related Commands

sech.png

Command Summary

Takes the hyperbolic secant of a number.

Command Syntax

sech(value)

Menu Location

  • Press 2nd MATH to enter the MATH menu.
  • Press C to enter the Hyperbolic submenu.
  • Press 5 to select sech(.

Calculator Compatibility

This command requires a calculator with AMS version 2.07 or higher (it will also work on any TI-89 Titanium or Voyage 200 calculator)

Token Size

1 byte

The sech() command returns the hyperbolic secant of a number. Along with 11 other trig and hyperbolic functions, it was added in AMS version 2.07; on earlier versions, sech(x) can be replaced by 1/cosh(x).

As long as the calculator is in radian mode, sech() can be used with complex numbers according to the rule that sech(ix)=sec(x) and sec(ix)=sech(x). This rule only works in radian mode, and sech() of a complex number will return a domain error when working in degrees or gradians.

Occasionally, sech() can compute an exact result; most of the time, the calculator will leave an expression with sech() alone unless it's in approximate mode (or you force an approximation). When sech() is used with symbolic expressions, the calculator can go back and forth between the sech() expression and its exponential equivalent.

:sech(0)
           1
:expand(sech(x))
          2*e^x/((e^x)^2+1)
:comDenom(2*e^x/((e^x)^2+1))
          1/cosh(x)

If sech() is applied to a list, it will take the hyperbolic secant of every element in the list. However, it can't be applied to matrices the way cosh() can (this is probably an oversight; all the trig and hyperbolic functions that were present in all AMS versions work with matrices, but the ones added in version 2.07 do not).

Formulas

The definition of hyperbolic secant is, by analogy with sec(), the reciprocal of cosh():

(1)
\begin{align} \operatorname{sech}{x}=\frac{1}{\cosh{x}} = \frac{2}{e^x+e^{-x}} \end{align}

Error Conditions

260 - Domain error happens when taking sech() of a complex number in degree or gradian mode.

Related Commands

coth.png

Command Summary

Takes the hyperbolic cotangent of a number.

Command Syntax

coth(value)

Menu Location

  • Press 2nd MATH to enter the MATH menu.
  • Press C to enter the Hyperbolic submenu.
  • Press 6 to select coth(.

Calculator Compatibility

This command requires a calculator with AMS version 2.07 or higher (it will also work on any TI-89 Titanium or Voyage 200 calculator)

Token Size

1 byte

The coth() command returns the hyperbolic cotangent of a number. Along with 11 other trig and hyperbolic functions, it was added in AMS version 2.07; on earlier versions, coth(x) can be replaced by 1/tanh(x).

As long as the calculator is in radian mode, coth() can be used with complex numbers according to the rule that coth(ix)=-cot(x)*i and cot(ix)=-coth(x)*i. This rule only works in radian mode, and coth() of a complex number will return a domain error when working in degrees or gradians.

Occasionally, coth() can compute an exact result; most of the time, the calculator will leave an expression with coth() alone unless it's in approximate mode (or you force an approximation). When coth() is used with symbolic expressions, the calculator can go back and forth between the coth() expression and its exponential equivalent.

:coth(0)
           undef
:expand(coth(x))
          -1/(e^x+1)+1/(e^x-1)+1
:comDenom(1-2/((e^x)^2+1))
          1/tanh(x)

If coth() is applied to a list, it will take the hyperbolic cotangent of every element in the list. However, it can't be applied to matrices the way tanh() can (this is probably an oversight; all the trig and hyperbolic functions that were present in all AMS versions work with matrices, but the ones added in version 2.07 do not).

Formulas

The definition of hyperbolic cotangent is, by analogy with cot(), the ratio of cosh() and sinh():

(1)
\begin{align} \coth{x}=\frac{\cosh{x}}{\sinh{x}} = \frac{e^x+e^{-x}}{e^x-e^{-x}} \end{align}

Error Conditions

260 - Domain error happens when taking coth() of a complex number in degree or gradian mode.

Related Commands

tanh.png

Command Summary

Takes the hyperbolic tangent of a number.

Command Syntax

tanh(value)

Menu Location

  • Press 2nd MATH to enter the MATH menu.
  • Press C to enter the Hyperbolic submenu.
  • Press 3 to select tanh(.

Calculator Compatibility

This command works on all calculators.

Token Size

1 byte

The tanh() command returns the hyperbolic tangent of a number.

As long as the calculator is in radian mode, tanh() can be used with complex numbers according to the rule that tanh(ix)=tan(x)*i and tan(ix)=tanh(x)*i. This rule only works in radian mode, and tanh() of a complex number will return a domain error when working in degrees or gradians.

Occasionally, tanh() can compute an exact result; most of the time, the calculator will leave an expression with tanh() alone unless it's in approximate mode (or you force an approximation). When tanh() is used with symbolic expressions, the calculator can go back and forth between the tanh() expression and its exponential equivalent.

:tanh(0)
           0
:expand(tanh(x))
          1-2/((e^x)^2+1)
:comDenom(1-2/((e^x)^2+1))
          tanh(x)

If tanh() is applied to a list, it will take the hyperbolic tangent of every element in the list.

Advanced Uses

The tanh() of a matrix is not (in general) the same as taking the hyperbolic tangent of every element of the matrix. A different definition is used to compute the result; see Matrices and Their Commands. It requires the matrix to be square and diagonalizable in order to apply.

Formulas

The definition of hyperbolic cotangent is, by analogy with tan(), the ratio of sinh() and cosh():

(1)
\begin{align} \tanh{x}=\frac{\sinh{x}}{\cosh{x}} = \frac{e^x-e^{-x}}{e^x+e^{-x}} = \frac{e^{2x}-1}{e^{2x}+1} \end{align}

Error Conditions

230 - Dimension happens when taking tanh() of a matrix that isn't square.

260 - Domain error happens when taking tanh() of a complex number in degree or gradian mode.

665 - Matrix not diagonalizable happens when taking tanh() of a matrix that isn't diagonalizable.

Related Commands

sinh.png

Command Summary

Takes the hyperbolic sine of a number.

Command Syntax

sinh(value)

Menu Location

  • Press 2nd MATH to enter the MATH menu.
  • Press C to enter the Hyperbolic submenu.
  • Press 1 to select sinh(.

Calculator Compatibility

This command works on all calculators.

Token Size

1 byte

The sinh() command returns the hyperbolic sine of a number.

As long as the calculator is in radian mode, sinh() can be used with complex numbers according to the rule that sinh(ix)=sin(x)*i and sin(ix)=sinh(x)*i. This rule only works in radian mode, and sinh() of a complex number will return a domain error when working in degrees or gradians.

Occasionally, sinh() can compute an exact result; most of the time, the calculator will leave an expression with sinh() alone unless it's in approximate mode (or you force an approximation). When sinh() is used with symbolic expressions, the calculator can go back and forth between the sinh() expression and its exponential equivalent.

:sinh(0)
           0
:expand(sinh(x))
          e^x/2-1/(2*e^x)
:comDenom(e^x/2-1/(2*e^x))
          sinh(x)

If sinh() is applied to a list, it will take the hyperbolic sine of every element in the list.

Advanced Uses

The sinh() of a matrix is not (in general) the same as taking the hyperbolic sine of every element of the matrix. A different definition is used to compute the result; see Matrices and Their Commands. It requires the matrix to be square and diagonalizable in order to apply.

Formulas

The definition of hyperbolic sine is given in terms of exponents:

(1)
\begin{align} \sinh{x} = \frac{e^x-e^{-x}}{2} \end{align}

Error Conditions

230 - Dimension happens when taking sinh() of a matrix that isn't square.

260 - Domain error happens when taking sinh() of a complex number in degree or gradian mode.

665 - Matrix not diagonalizable happens when taking sinh() of a matrix that isn't diagonalizable.

Related Commands

cosh.png

Command Summary

Takes the hyperbolic cosine of a number.

Command Syntax

cosh(value)

Menu Location

  • Press 2nd MATH to enter the MATH menu.
  • Press C to enter the Hyperbolic submenu.
  • Press 2 to select cosh(.

Calculator Compatibility

This command works on all calculators.

Token Size

1 byte

The cosh() command returns the hyperbolic cosine of a number.

As long as the calculator is in radian mode, cosh() can be used with complex numbers according to the rule that cosh(ix)=cos(x) and cos(ix)=cosh(x). This rule only works in radian mode, and cosh() of a complex number will return a domain error when working in degrees or gradians.

Occasionally, cosh() can compute an exact result; most of the time, the calculator will leave an expression with cosh() alone unless it's in approximate mode (or you force an approximation). When cosh() is used with symbolic expressions, the calculator can go back and forth between the cosh() expression and its exponential equivalent.

:cosh(0)
           1
:expand(cosh(x))
          e^x/2+1/(2*e^x)
:comDenom(e^x/2+1/(2*e^x))
          cosh(x)

If cosh() is applied to a list, it will take the hyperbolic cosine of every element in the list.

Advanced Uses

The cosh() of a matrix is not (in general) the same as taking the hyperbolic cosine of every element of the matrix. A different definition is used to compute the result; see Matrices and Their Commands. It requires the matrix to be square and diagonalizable in order to apply.

Formulas

The definition of hyperbolic cosine is given in terms of exponents:

(1)
\begin{align} \cosh{x} = \frac{e^x+e^{-x}}{2} \end{align}

Error Conditions

230 - Dimension happens when taking cosh() of a matrix that isn't square.

260 - Domain error happens when taking cosh() of a complex number in degree or gradian mode.

665 - Matrix not diagonalizable happens when taking cosh() of a matrix that isn't diagonalizable.

Related Commands

Member

.

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-Noncommercial-No Derivative Works 2.5 License.