*****************************************************************
Chemical Equation Balancer (ChemBal) v2.0
Author: Anthony Loven
Date: 1-15-05
Email: greenorange5656@gmail.com
*****************************************************************
     This program can be modified at will.  However, my name
(Anthony Loven) must be referenced in documentation, and I must
be listed as a co-author.
---------------

Introduction:

     I did indeed say I would never write a new version of ChemBal again.
I lied.  This version (2.0) is completly different.  It's extremely fast
(takes about 3 seconds to balance an equation), alot more easy to use,
so much more less space (638 bytes!!!), and the best TI-86 chemical
balancer publicly released by this date.  It can take on any solvable
equation (this version does not include charges, redox, equilibrium, etc.)
and is a MUST for College chemistry, General Chemistry, AP Chemistry, or
anything related.  With only 638 bytes, who wouldn't want it?

---------------

Purpose:

     The purpose of this program is to balance any user-entered chemical
equation in a quick, efficient manner.

---------------

Contents and installation:

     The contents of this ZIP are:

chembal2.86p - The main program for the calculator.
chembal2.gif - screenshot
chembal2.txt - This file :)

To install, simply send chembal.86p to your calculator using some type of
linking software.  The file was extracted from my calc using TiLP, which
is recommended.

---------------

Usage:

     This program was designed to operate perfectly on a shell.  Basically,
you can use IShell, Rascall, ASE, Seklorean Warrior, or any other shell
with it, and still see the results, and return safely to the shell.  It
even has a shell description :)  If you do not use the shell, you can edit
the program, and remove the first line, which is useless.  It will not
change the program one way or another, but it will save space.

     Now, to using the program.  Let's start with an example.  Numbers are
actually subscripts, so H2O is water, and CO2 is carbon dioxide, etc:

	 C2H5OH + O2 -----> CO2 + H20

Split up into simpler parts:
	 C2 H6 O + O2 -----> C O2 + H2 O

To balance the above equation, start the program.  When prompted for elements,
enter 3, because we have C, H, and O.  For reactants, enter 2, because we
have C2H5OH and O2.  For products, enter 2 for CO2 and H2O.

Now, you must enter how much of each element is in each reactant/priduct.
For this problem, you will be prompted for 3 elements, and each element, you
will need to give 4 values.  The first element is C (however, it makes no
difference which element you start entering first; it can be any order.)
We have 2 Carbons in reactant 1, 0 carbons in reactant 2, 1 in product 1,
and 0 in product 2.  Enter 2, [HIT ENTER], 0, [ENTER], 1, [ENTER], 0, [ENTER].
The next element will be hydrogen.  Enter the series 6,0,0,2.  For element
3, enter 1,2,2,1.  Now, you will wait 3 seconds, and the answer will be given.
It is:

	{ 1, 3, 2, 3}

This represents the cooefficients to place before each reactant/product in
the order you entered them.  Basically, the equation balanced is:

	C2H5OH + 3 O2 -----> 2 CO2 + 3 H2O

Hit enter to return to the shell, or the home screen.

---------------

Fine points:

There are some things to be aware of.  If you have the equation:

	AgNO3 + H2SO4 -----> Ag2SO4 + HNO3

You MUST treat NO3 as one element, and SO4 as one element.  So instead
of having 4 elements for Ag, N, O, S, you have these 4: Ag, NO3, H, SO4.
IT WILL NOT SOLVE OTHERWISE!

This same procedure should be applied to any other similiar equation.  It will
require examination before solving.  Also, in the example stated in the Usage
section, the first compound, C2H5OH, is rearranged to be C2H6O.  DO NOT ENTER
AN ELEMENT TWICE FOR ONE COMPOUND!

---------------

History:

1-15-05  Version 2.0

 - Second public release
 - 600 bytes
 - 3 second solve
 - 99% effective :)
 - Rewrote whole program from scratch
 - new input system
 - matrix solve system

12-21-04  Version 1.0

 - First public release.
 - 4.7 Kb
 - VERY SLOW
 - VERY BUGGY

---------------

Credits:

Anthony Loven - design and programming
www.shodor.org - taught me how to use matrices to solve chemical equations

---------------

This file should always accompany the program it came with.  This program can
be distributed freely, but this file should always be with it.
