Of Mice and Math Programs
|
Posted on 28 August 1998
The following text was written by S.T.L.: Why'd I choose that title? I don't know,
it sounded niftier than, "Of Mice and Math and Science Programs". Anyways, it's
late at night again, and I'm browsing through the ticalc.org archives. One thing I notice is
that there is a serious deficiency of math/science programs in general, and a waaaay serious
deficit of assembly math/science programs. Well, I know they can't be as popular as games,
but they sure are darn useful. So, the basic idea of this article is that: Some changes need
to be made in the way math/science programs are conceived and written. Let me take
the TI-85 TI-Basic Math program Diviz as an example. It tests numbers to see if they're
prime. The author writes: "But this one is the fastest I've seen." Well, it's not that fast
at all. (No offense intended to the programmer, it's great he wrote a math program.) The
process Diviz uses is Baby Trial Divide. Without going into serious mathematical language
here, there exists a better process called Wheel Factorization. Had the author studied
Number Theory (the area of math involved with primes and such) a little, he'd at least know
about that. It's pretty simple, I implemented it on my TI-85. There are of course even
better things, but they can't be done on a TI-85. This example of deficient programming
isn't restricted to one program. There are some triangle solving programs there, and some of
them (all of them?) don't seem to know of the Law of Cosines, which would let them solve
more triangles. It's also pretty simple, I implemented it on my TI-85. Now, let's
talk about Periodic Table programs. I *used* to have one on my TI-85. I also can't program
one, since I'm assembly-illiterate. Yet I deleted it. Why? Because I do some heavy-duty work
with chemistry, and I'm a precision fanatic. I want as much precision in the atomic masses
as I can get. Thus I've gone back to using a paper table. *If* a TI-85 program that had 7+
decimal precision for atomic masses came out, it would be really useful. Now, all
this has led me to the opinion that math/science programmers have to know the subject
they're doing in detail before they write a program, so that it is as detailed, as
efficient, and as useful as possible. For example, I'm not bothering to upload my program
TRI, because anyone can hack up that sort of thing in TI-BASIC, and may even be better than
mine. I'm also probably not going to upload my program PRIME2. Why? Though it's pretty
speedy for a TI-85, for the TI-92, there's something infinitely better that I couldn't ever
make by myself. The TI-92 Number Theory library, the NTH, can be found at
http://home1.gte.net/paulp/nth/ Now, I think ticalc.org should have a link to that. :-D
So, what's this all mean? Well, I've got some opinions on that. Namely:
- There need to be more math and science programs (both TI-BASIC and assembly) for all the
TI calculators. (Granted, some cannot support the heavy-duty math sometimes required, as in
the NTH. No other calculator (except the TI-89) could support that.)
- A programmer
writing math/science should get to know the subject in detail, to make a program that has
many useful features.
- Also, a programmer writing math/science should go to extremes to
provide precision. (This mostly applies to science. I refuse to use a Periodic Table that
gives Oxygen a mass of 16. I'll consider using a Periodic Table that gives Oxygen a mass of
15.9994.)
- A programmer writing math/science should get to know ways to implement the
algorithms needed, in detail, to make an efficient and quick program. (This mostly applies
to math.) If game programmers spend sleepless nights to speed up their games and shave off
11 bytes, then so can math/science programmers.
- Also, programs should be written so that
they can be used as sub-programs, with no or little modification. For the case of the TI-92
(and 89) they should come in Function format, too. (This mostly applies to math programs. I
did this for my program PRIME2, transforming it into PRIME3.)
- Programs should be made
for really complicated things. Now, while programs that do (say) quadratic equations are
useful in their own right for some/most people, there also exists a need for heavy-duty math
and science. (Probably the NTH is the first attempt at this that I've seen. A look at the
ticalc.org archives shows that most TI-BASIC math programs are for a 8th grade Algebra I
audience. And the TI-BASIC science programs are for a medium high school level. And the
assembly programs are few and far between.)
Well, anyone else have other
suggestions?
|
|
Reply to this item
|
Release your programs
|
Sean
|
Well the lack of math/science programs could be because people like you won't release their programs. You stated, "I don't want to release my programs, because I know someone can make it better" Well thats a bunch of crap. If everyone did that we wouldn't have any programs. So in the future think of releasing your programs, so the archives will have at least something even if they are somewhat slow.
I also agree with the person above that said a lot of people aren't in really advanced classes. Well you are, so try programing something or learn asm (its not that hard) and then you will will stop complaining for everyone else to wipe your butt.
|
Reply to this comment
|
29 August 1998, 02:34 GMT
|
|
My programs
|
Matt Tandy
|
I agree about the science, but I don't think the math programs are so bad. Since the science is lacking, I have been working on a couple of programs to help out. They are both in BASIC, but I bet they will get used a lot. One program will work out double displacement reactions for you. You enter the reactants, and it goes through the solubility rules(not just shows them), finds the results, tells whether it is aqueous,gas, or solid, and tells if the reaction will go to completion. It works more than 90% of the time at the moment, and I am adding things when I can to improve it. The other will give you the name and molecular formula of alkanes, alkynes, alkenes, and alcohols from just the number of C & H. It is only 841 bytes, and I plan on adding support for structural formulas as well. I have no other projects as of yet, but if anybody has some suggestions or wants a pre-release version of these, then just email me.
|
Reply to this comment
|
29 August 1998, 04:34 GMT
|
|
Re: Article: "Of Mice and Math Programs"
|
Dr. Sbaitso
|
I dunno...I'd think that for all the really heavy math/science crunching out there, there would be either specific programs (or equipment, for that matter) for higher-powered machines...MathView for the PC/Mac is a nice example. And besides, I've always seen the TI calculator (except for the 89 and 92, that is) as being hyped up just for the kind of audience you mention (middle thru high school, maybe college applications)...I mean, I've never seen anyone really pushing the TI-83 as "the engineer's best friend."
And, even so, most of the programs that will be uploaded to an archive will have been written by someone for some specific instance (i.e. they needed to crunch some #'s for Newton's Method for a test), something that they think might be helpful to someone else somewhere, just maybe. You can't usually expect to find some all-knowing set of programs that can do everything under the sun...most people that write math programs don't have that broad a scope in mind when they write them...they just need the help for what they're working on just then.
P.S. Sorry for taking up so much space.
|
Reply to this comment
|
29 August 1998, 04:43 GMT
|
|
Who cares?
|
James Rubingh
(Web Page)
|
who really cares? I use my calculator for games, and programming experience, if you want math programs, make them yourself, dont complain about other people not doing it for you.
|
Reply to this comment
|
29 August 1998, 05:09 GMT
|
|
|
|
|
Re: Who cares?
|
Chris Weasel Edwards
(Web Page)
|
I agree. I've seen several articles in the last few weeks about what programmers "should" do. I can understand people wanting to help each other with meaningful suggestions, but it really comes down to what the programmer wants to do. We're all doing this as a hobby. When I'm involved in any hobby, including programming, I don't like being told how I should or shouldn't do it. The purpose for hobbies, as I see it, is to avoid such control. I make most of my programs on whims, not because someone else wants me to. Sometimes, I even do it for popularity. And that's what I think the article writers are really striving for, although they claim otherwise. I can't blame, them either. A little stardom is nice every once in a while.
|
Reply to this comment
|
29 August 1998, 08:46 GMT
|
|
Observations
|
Tom
|
About the exact answer thing (by JimmyPop), my advice to you is to go buy a TI-92 or a TI-89. The default on those calculators is to keep things in fractions or in terms of pi or in terms of "i" and so on. But let me tell you, it is not a good a feature as it sounds. I personally would prefer the 12 decimal places to something like "7 (pi) / 2." Makes it easier to comprehend.
About chemistry programs: I took AP Chemistry last year (and scored a "5" on the exam, by the way). I wrote several computer programs along the way. I had a program to solve equations (gives you possible products when presented with the reactants, possible reactants when presented with the products, and balances). I also wrote database programs that could solve for every isomer of a particular compound. And so on. My point is that while programs will help you on homework (I do homework at home so I can use my computer programs), you still have to learn the methods for tests. Otherwise, why take chemistry? Programs to solve everything would take out the challenge.
About math programs. In tenth grade I wrote and used a math program to convert numbers between rectangular and polar form for a test. After I got the test back (with a dismal grade), I realized that my program had a small calculaton flaw. I have never used a math program in math class since then. This year I will use my TI-92+ in my math classes (AP Stat & Differential Equations). The TI-92+ does everything I could possibly need, so there is no real need for any math programs.
About the periodic table. I had the TI-92 periodic table program for AP Chemistry last year (the awesome one written by the French guy). I had no problems with precision. I think that the program had around eight digits precision. I don't really remember, though. In Honors Chemistry in tenth grade, I used a periodic table program for ZShell on my TI-85. That worked out really well too. Honors Chemistry does not require precision beyond two or three digits in my school.
Lastly, I would like to agree with James Rubingh. My calculators already have every function I need. The only thing it is really missing is games (which is why so many people write and post them). If you feel for some reason that there is a program which you need and is not on this site, you should write it yourself (or kindly ask that someone else do it for you). Complaining won't do a thing.
p.s. Clinton rules, Starr sucks
|
Reply to this comment
|
29 August 1998, 05:35 GMT
|
|
Re: Article: "Of Mice and Math Programs"
|
me
|
> 1.There need to be more math and science >programs (both
> TI-BASIC and assembly) for all the TI >calculators. (Granted, some
Then write them.
> cannot support the heavy-duty math >sometimes required, as in the
> NTH. No other calculator (except the >TI-89) could support that.)
They certainly could. Write them in assembly.
> 2.A programmer writing math/science should >get to know the subject
> in detail, to make a program that has >many useful features.
..yet you want them to produce mass volumes of programs, see your number 1 above.
> 3.Also, a programmer writing math/science >should go to extremes to
> provide precision. (This mostly applies >to science. I refuse to use a
> Periodic Table that gives Oxygen a mass >of 16. I'll consider using a
> Periodic Table that gives Oxygen a mass >of 15.9994.)
Holy shih-tzu! What the flock for? You need to spend some time around engineers. If there's one thing I've learned from having 3 engineers in my family, it's that 15.9994 = 16 for *all practical purposes*. Remember, we did send men to the moon using slide rules...
> 6.Programs should be made for really >complicated things. Now, while
Ok, then write them... seems kind of obvious to me...
> programs that do (say) quadratic >equations are useful in their own
> right for some/most people, there also
...that being the reason they were written and distributed...
>exists a need for heavy-duty
> math and science. (Probably the NTH is
And there exist people like you (presumably) to... shocker of all shocks! WRITE THEM!
> TI-BASIC math programs are for a 8th >grade Algebra I audience.
> And the TI-BASIC science programs are for >a medium high school
Suprisingly, because that's who buys TI-8x calculators! Really, what on earth did you expect?
> level. And the assembly programs are few >and far between.)
Because it's so damned inefficient to load number after number into registers and make eight hundred and three ROM calls when you can do it in BASIC in three lines.
Here's the bottom line: Most math and science programs are written by individual students for their local curriculum. They write them as quick shortcuts for checking math and science work and don't intend to make them convenient for others. Let me tell you... I've never written a math/sci program with others in mind... I write them for myself.
Which is what you should do, instead of whining at us. You should be ashamed. Your post is little more than a rant.
|
Reply to this comment
|
29 August 1998, 09:29 GMT
|
|
|
|
|
Re: Re: Article: "Of Mice and Math Programs"
|
S.T.L.
(Web Page)
|
Let it be known, let it be said, that most anything I write is a rant. I've written hundreds of K of essays on my *ahem* (which, by the way, is not at www.fnal.gov - that's just a ploy to get you to a particle physics site!) and I've acknowledge that they're all, in one form or another, rants. Ranting is my way. By the way, I simply don't have the time to write the math programs I was talking about. By the way, a TI-85, in my opinion, is WAY more than what an Algebra I student needs. It's what a Calculus I student needs. (TI-92s are good for that, too.)
|
Reply to this comment
|
29 August 1998, 22:54 GMT
|
|
|
|
|
|
|
|
Re: Re: Re: Article: "Of Mice and Math Programs"
|
snb
|
You need to shut your mouth STD. You have no time to write the programs you need, but you have all day to sit at your damn computer and chat on ticalc.org. I have also noticed that you seem to be extremely familiar and up to date with the archives; is that not time that could be better spent, say, WRITING YOUR OWN DAMN PROGRAMS!
Do you expect us:
1. To write these programs for you
2. To actually sympathize because you have no time, and
3. To take the destructive criticism you have put upon the friendly programming community in ticalc.org without a complaint???
NO
Of course we would not and many have stuck it in your face as to how wrong you are, me being one.
You have uploaded a program for prime numbers. I haven't downloaded it so I would not know how good it is. In total, you have uploaded 2 programs onto this website and one of them could take a novice programmer 2 hrs to program in Eratosthenes' Sieve into a program(a really novice programmer). No offense to the novice programmers, because the best of the best programmers in the world were novices at one time, but the effort required to create that is truly pathetic.
Maybe next time you can try a topic where you actually think on both sides of the argument, because you are surely losing on this one.
8)
|
Reply to this comment
|
21 December 2002, 23:55 GMT
|
|
1 2 3 4 5
You can change the number of comments per page in Account Preferences.
|