Re: Program to add Mixed numbers (TI-92)


[Prev][Next][Index][Thread]

Re: Program to add Mixed numbers (TI-92)



On Wed, 11 Dec 1996, Jeff wrote:

> I realize that this is a mundane topic, but I am curious whether there
> is a built in function to display/manipulate mixed numbers.  I have
> written a program that uses what I would consider the "brute-force"
> approach, but I think there must be a better way.
> Actually, I made a user-defined function that will add/subtract (still
> working on the mult/divide part, which I think will be simpler).  But i
> am looking for a nicer interface, which ideally would allow entry like
> the following:
> 3 9/16+4 5/8<ENTER>        8 3/16

Say the number you wish to display in mixed number form is stored in x.
Do whatever math you want with x, then

disp Ipart x
disp (Fpart x)>Frac

It works on my '85.

If you want, you can replace x with Ans, and just run that when you want
it to give you your last answer in mixed numbers.
(to do your example, it would simply be 3+(9/16)+4+(5/8) and then run the
program.)

Tony Lieuallen = lieuallen@iop.com          Oxymoron: Power Macintosh
http://www.iop.com/~lieuallen/home/
Welcome to the ever changing sig!  It changes every time I log in, so
don't flame me if it's a little long.  Enjoy!

Monday, n.:
        In Christian countries, the day after the baseball game.
                -- Ambrose Bierce, "The Devil's Dictionary"


Follow-Ups: References: