Open Source Symbolic Math Program?
RickMuller asks: "I'm a quantum chemist, and every so often I'm forced to sit down and derive equations. On occasion I've used Mathematica or Maple to simplify the process, but only rarely because (i) they're not much better than plain paper and pen, and (ii) they're proprietary software, and if I'm going to learn someone's arcane command syntax, I want to make sure it's open source so I can compile and run it everywhere I need it.
I want to know if there is a reliable symbolic math package that is open source. I'm familiar with the CALC package in Emacs, which is quite good except that one needs to be running Emacs to use it. I would like to know if there is a viable alternative. Anyone? "
You might want to check out SciLab. It's more oriented towards numerics, but it appears there are some symbolic capabilities. http://www-rocq.inria.fr/scilab/
There is a program produced under the GNU GPL called octave that supposedly interprets mathlab commands. Never tried it because it barfed on my libc version.
Slashdot social engineering at it's finest
You might try:
MuPAD
I've had good luck with it.
Jim
Ooo, I just thought, there is a really nifty matrix math program called "umatrix" in the FreeBSD ports tree. It is nice and small, it has very limited functionality, but I have solved more than one homework problem with it. It might make for an excellent starting point. The immediate draw back (for me anyway, since I do not know Italian) is that the comments and variables are in Italian.
There's a symbolic math package called Octave that's opensource & such... I remember running it under Solaris, Linux, and AIX... http://www.che.wisc.edu/octave/
GiNaC 0.5.3
An open framework for symbolic computation within the C++ programming language.
License: GPL
While i haven't checked it out, from the webpage it is what you need.
daniel
Check SAL.Kachinatech.com for all sorts of scientific apps on Linux, including numeric and symbolic math programs...
Nick
-- "It's a sad day for American capitalism when a man can't fly a midget on a kite over Central Park" - Jim Moran
Try YACAS (Yet Another Computer Algebra System). In my opinion it lacks the polish of Mathematica, but it's got a fairly powerful core (which you can always extend).
Octave is a GPL numerical computation tool that is like MATLAB, but better. :-) Most scripts that don't rely on commercial matlab toolkits run fine right out of the box.
Of course, the symbolic toolkit that comes with matlab is probably what you're looking for. Perhaps we should work on creating a symbolic toolkit for Octave? Perhaps someone already has? Stay tuned!
Tetris rules.
There is a gpl'd version of macsyma available here. They call it "Maxima" but it really is a fork of macsyma. I've used both this version (on linux) and the commercial version (on windows). It is an *outstanding* tool. Go get it.
MuPAD: nice general purpose CAS with packages for practically anything. You can view the source for the library functions, so if there's bug, you can fix it. Support is excellent and it's essentially free (as in beer) for *nix systems; MuPAD Light is free for Windows systems. www.sciface.com
PariGP: Has a decent user interface but not especially user-friendly compared to MuPAD's programming language. Has excellent support for formal power series, rings, etc.
Macaulay: User interface is bare bones; just flushes input to the interpreter. Strong in manipulation of polynomials via Grobner basis. It seems specialized for computational algebraic geometry.
I can't stand the Mathematica licensing. As a poor college student who runs Linux, I don't buy much software. But this year I decided it would be worthwhile to have Mathematica (they released a linux version).
So, I bought the student version of Mathematica. I've come to regret that, because their licensing is a pain in the ass. I reinstall OSes on a regular basis, and every time I do, Mathematica requires a new password, so I need to email the company and get a new password from them. This takes days.
Also, I dual boot windows. The CD also had a windows version, so I decided to install it. What's wrong with me using a program I paid $130 for on both operating systems right? It's still on my computer, and they can't run at the same time anyway. Well, I sent another request from them, along with a number generated from my system, and here's the response I got:
It looks as if you have changed from the Linux to the Windows platform. In
order for us to generate a new password for you, I will need for you to
complete a system transfer application. I have attached a copy of this form
in JPG format to this e-mail. Please print the form, complete it, and
return it to Wolfram Research either by fax or mail. Once received a
customer service representative will process your request. Please be sure
to write you new MathID number on the form so the person who receives it can
process your password, I do not believe the form it asks for it.
Our fax number is listed at the top of the form, and our mailing address is:
Wolfram Research Inc
Customer Service
100 Trade Center Dr
Champaign IL 61820
If you are unable to open or read the file please contact me and I will
request a copy of the form either faxed or mailed to you.
Gee, thanks. I haven't gotten around to doing this yet, but perhaps I'll find the time.
Meanwhile, AN OPEN SOURCE MATH PACKAGE WOULD BE A GODSEND!!!!!!!
--
grappler
Vidi, Vici, Veni
Also check out Magnus.
Check out the JACAL web page-- http://www-swiss.ai.mit.edu/~jaffer/JACAL.html for more details. You'll need a Scheme interpreter and the slib (Scheme library). It's GPL, if you're worried about licenses.
I don't know a whole bloody lot about Scheme-- would it be terribly difficult to create a C/C++ implementation of JACAL, or would it be best to start from scratch?
Remember, I've never used JACAL, so I don't know about how appropriate it will be to your needs. But it can supposedly "manipulate and simplify equations, scalars, vectors, and matrices of single and multiple valued algebraic expressions containing numbers, variables, radicals, and algebraic differential, and holonomic functions", according to the web page-- it might be a good starting point.
----
I have come to a conclusion about life... I am more
mentally stable than any of these activists or
Mathcad looks very impressive to your average user, but Maple is the better package once you get used to thinking about it.
The thing is, if you've ever looked at maple it's clear that many of teh modules haven't actually been planned - through the versions it's evolved in the same way that an OSS project would.
So with a good enough core and foundation then a Maple killer shouldn't be too hard. Till then Maple on Linux will have to do.
Unfortunately, like Matlab, it depends on Maple for its symbolic capability. So, what's needed is either a standalone symbolic kit for SciLab, or an open implementation of Maple...
CJW
Octave is an excellent MATLAB-like program. I've been using it for just over a semester now for DSP classes. It does all the matrix and math functions very well but needs some work on the user interface. The only significant difference I have noticed is that Octave plots aren't as versatile as Matlab. Octave ignores commands like "title", "xlabel", etc. If you want to make something cool, a GUI front to Octave would be nice, especially if you could figure out how to make better plots. I may get flamed for this, but Matlab has a linux port at my campus bookstore for about $100.
-- no sig
I am a quantum physicist and did
some quantum chemistry for a couple
of years. Mathematica is excellent
for symbolic computations.
>On occasion I've used Mathematica or Maple to
>simplify the process, but
>only rarely because (i)
>they're not much better than plain paper and pen
I completely disagree about that. Give me a pen
example and I'll do it for you with Mathematica.
I have solved symbolic systems of diff. eqns
which otherwise freak you out just by thinking about.
Best,
Though Octave is a very useful math package (I use it all the time), it doesn't have any symbolic math support. I don't know what made you think otherwise. It's almost Matlab compatible though.
As for symbolic stuff... you should look at SAL.KachinaTech.com which is a site for scientific applications under Linux
Opus: the Swiss army knife of audio codec
-- Will quantum computers run imaginary-time operating systems?
They call it Maxima but really it is a forked up name for...
macsyma, a symbolic math package BTW developed under "project mac". See? That's clever: project mac, math, symbols... clever. Can "Maxima" be improved? Well, here at least is a recursive acronym: MAXima Is MAcsyma. Nah, no good.
How about, "Maxima: where this derivative's name has a value equal to zero"
Call me a heretic of the Open Source movement, but:
I use Mathematica regularly. Its syntax is arcane only to the extent that it is itself a programming language with a complex instruction set; and the source is closed. But it has two features which I believe counter this. First, there are simply no programs of comparable power for complex symbolic manipulation; and yes, I am familiar with the open source packages. But algorithms for solving symbolic differential equations and large integrals are simply too much for small groups of people to do; their design requires substantial teams of very skilled people. And while the open source community has mustered many (most?) of the best programmers in the world, the skills of applied mathematicians simply aren't as prevalent in this world.
And second, Wolfram Research (the company which makes Mathematica) has systematically made itself as open as possible; they routinely solicit user suggestions and input, and sometimes incorporate user-submitted packages and code into their own releases. While the core code itself is compiled, a large fraction of the program comes in the form of modular packages which come in the form of Mathematica source code.
In short, I'll say that Not All Closed Source is Bad. The modularity of Mathematica, the publication of the API's and the source to all of the interpreter-level packages, and the responsiveness of the company to its users have given it most of the same advantages that true Open Source posesses.
(All of this applies as well to Maple; that system is oriented more towards large data set manipulation rather than pure symbolics, however, so the situation is slightly - but not very - different.)
So call me a heretic; but I believe that, when the cost of a large number of specialists needed to develop a package is high, the creation of a closed-source, sold-for-money package is reasonable so long as the company does not behave in a manner detrimental to its users. Therefore I would suggest that the continued use and active support of systems such as Mathematica and Maple is beneficial to the community as a whole and should be continued, even in the presence of open-source alternatives.
--
"Convictions are more dangerous enemies of truth than lies."
" On occasion I've used
Mathematica or Maple to simplify the process, but only rarely
because (i) they're not much better than plain paper and pen, and (ii)
they're proprietary software, and if I'm going to learn someone's arcane command
syntax, I want to make sure it's open source so I can compile and run it
everywhere I need it."
It's the "run it everywhere I need it" part that is confusing me. Don't the major packages have ports for all major platforms? I have seen/used UNIX, Mac, and PC versions of Mathematica, matlab, and maple. I have not had any trouble with transfering session data (mathematica notebooks, matlab log/diary files, etc...) between platforms either.
I remember taking a mathematica course 6 years ago at CMU and using the UI on a PowerPC mac, and running the bigtime number crunching on a Sparc20 server.
I am in no way trying to negate or discourage the need for, or advantages of, an open source solution to the problem, but shouldn't a quantum chemist have enough university or corporate support to provide him with whatever packages he needs to do his job?
"You want to kiss the sky? Better learn how to kneel." - U2
Sig:
Barbeque is a noun. Not a verb.
Moderators, what were you thinking? It may be informative, but it's wrong. If you don't know, don't touch.
See what I've been reading.
Try Genius (which is now part of the Dr Genius package) I was using this as a tool for matrices before I ever tried MatLab. Once I sat down at university lab PC, I found it to amazing how close to MatLab Genius is.
Call me a heretic of the Open Source movement, but:
IMO, it's hardly heretical to wish to use the best tool for the job. Like you, in many facets of my professional life (I'm a physicist) I've found no tool, Open Source or closed, that has the flexibility and functionality of Mathematica, particularly in the area of symbolic algebra. I'm skeptical of whether any Open Source product will be able to legitimately compete in this arena for some time.
In my experience, Wolfram Research has excellent customer service, and they do indeed listen to their users re: adding features to their software. If you'll permit an anecdote, when I was writing my dissertation I wanted, for some technical reasons, to be able to generate graphics in Mathematica but use LaTeX drawing commands to place the numbers and labels on my figures. I wrote a filter in C to process the Mathematica-generated encapsulated postscript to strip out the text drawing commands, and then build a corresponding LaTeX file with the drawing instructions. I had some difficulty getting the text positioning to work right, and I asked in an email to Wolfram Res. some specific questions about how MMa generates its EPS, and to my surprise I received a detailed reply within 24 hours. The reply also noted that the next version of MMa would possess the functionality I was trying to work around. (True to their word, it did). I have had other similar experiences with them in the past, but this one sticks in my mind.
My advice to the original poster who is afraid to learn a language that may not be supported on his machine would be to go ahead and learn a symbolic algebra system such as Mathematica or Maple now, since at the moment the commercial systems seem to be the "state of the art." Though the software is not free as in "free beer," the price isn't terribly high on most machines and OSs (Alphas being a notable exception. Furthermore, while you can't tinker with the internals of the interpreter itself, many of the packages are implemented in the language itself, and so you can indeed modify the software to suit your purposes; this gives it some of the same flexibility as Open Source code.
Incidentally, Mathematica and Maple were both available on the Linux platform quite early on in the Linux movement. I remember purchasing the student version of MMa for Linux for $75 back when my P5/133 was considered a "high-end" platform.
I know this isn't the response you're looking for, but if you want a really powerful symbolic math package that's released under the GPL, take a look at Erable (by Bernard Parisse), for the HP48G line of calculators. It can do lots of things (especially certain types of symbolic integration) that even Maple can't touch, and at a fraction of the speed!
And the fact that it only runs on saturn processors is easily outweighed by the small footprint: only 100k! You couldn't find anything sexier than this if you had Tux in a g-string.
"If one is really a superior person, the fact is likely to leak out without too much assistance" -- John Andrew Holmes
I've been using MATLAB for years, and have the Linux version. I find MATLAB frustrating once you get to a high enough level in their programming language. Their scoping is awful and their iteration is butt slow, among other things. They also can't handle strings and system stuff very well. I've seriously though about getting involved in perldl, the data language using perl. It is in an early developmental stage, but seems to rock over every other language, atleast in concept. I would strongly suggest that anyone interested in free mathematics packages invest their time in perldl. Why do you want to copy all the mistakes of packages like MATLAB! Perldl promises to be something better.
If I had no sense of humor, I would long ago have committed suicide. -Ghandi
>Matlab has a linux port at my campus bookstore for about $100.
The student VERSION of Matlab does have Linux and windows binaries, but the integrated editor and debugger IS NOT available for Linux. Sure, you can write your programs in emacs or whatever text editor you want, but you don't get the context hilighting, and if you write anything of even moderate complexity you will want a debugger. A search of Mathworks' web site reveals that they are "considering" porting the editor and debugger to other OS'es, including Linux. I use Matlab in my classes, and I'm TA'ing an introductory course in Matlab. I was just a little dissapointed when I found out about the debugger (after about an hour of trying to get it to run - NOWEHRE in any manual or help file does it mention the fact that there is no debugger in the Linux version)
Notice also I said the student VERSION - if anyone is contemplating buying (or uhh.. otherwise obtaining) Matlab, make sure you get the student VERSION. The student EDITION is handicapped. The student VERSION is fully featured and includes Simulink for modeling control systems.
I don't know where they are.
I was pretty impressed too. I remember my brother showing it to me. I pulled out the CRC book and entered the most complicated looking integral I saw, and I was amazed that it computed the integeral symbolically . (i.e. not some lame numerical integration by trapezoidal or simpsons rule)
Seemed like magic at the time. This was probably on an 8088. I'll bet it was less than 400K. probably 1/100 the size of some of the others.
I have looked for one of these, having messed about with Maple V years ago at university. I also looked at some of the Mathematica GUI (I xhosted my workstation once to allow someone in Sweden to output some stuff on my display in the UK) These are great apps, but their commercial cost is high - deservedly or not.
I tried looking at MuPad, but the damn thing wanted me to write off to the authors to ask to use the software, also I'm not sure that it was truely Open Source.
I don't want to pay for Mathematica/Maple especially at the prices they are licensed at.
If someone starts a project on this type of software which has the power that Mathematica/Maple has - then I would be very interested. I might even be prepared to pay $40 for such software, but it would be a dream if it were made Open Source (ie Licensed under the GPL)
They're on to better and smaller things.
SoftWarehouse Inc was purchased by Texas Intrusments, and put to work. The TI-89, the best calculator ever made, uses "Derive" derived software to do it's symbolic functions (Derivation, Integration, Factorying, etc.)
The derive software itself is at http://www.derive.com/dfdset.htm
If you like calc, it's probably written in elisp, which is just regular common lisp with a little bit of sugar here and there to tie it into emacs.
:)
Porting calc from elisp to common lisp should be relatively easy, and once it's in lisp, you can run it with CLISP or any number of good high-quality free lisp implementations that come with source.
Porting calc has extra benefits too (if it's written in elisp and is portable) - first you would have done the community a favor by contributing work, and second, you wouldn't have to learn a new program.
-- Truth goes out the door when rumor comes innuendo. -- Groucho Marx
If Mathematica loses its dominant position and stops being developed, then your next computer may be a platform on which mathematica doesn't run. Anyone who's ever owned a microcomputer which isn't PC/Mac compatible probably has a shelf full of software that once was popular but now won't run on their current computer. If it were open-source, this would be less likely since anyone could do the porting.
Since many are scientific academics I imagine lots of them know. However, it would be possible to have a basic OS-dependent engine, and most functions talking to this engine rather than the OS; that way, you could port freematica without understanding Hermite polynomials.
perl -e 'fork||print for split//,"hahahaha"'
There must be a huge number of students to whom a copy of Mathematica would be worth something less than the student price. Since the marginal costs for software are zero, it works out as a huge net waste to the economy that they can't get hold of it. Also, its existence makes it less profitable to develop a lower-powered, lower cost alternative which they might buy, because no "power users" would bother with it.
Of course, if they hadn't charged a license fee, Wolfram might never have created mathematica, and their might only be the "lower power, lower cost" alternative. This would also be a huge net waste to the economy.
My point is that neither system, as it stands, is economically efficient in this case. Just because Mathematica benefits some people, it doesn't mean they create net benefit for the community as a whole. On the other hand, they don't neccessarily create net loss for the community as a whole, in the way that a proprietory application does if its existence is all that stops an equivalent-powered free version from being developed.
This is from a purely economic point of view, disregarding the moral question of whether non-free software is evil, or whether not giving people control over their IP is evil.
perl -e 'fork||print for split//,"hahahaha"'
Check out NetMath which I believe does exactly what you want.
--
-- Abigail
It seems to me that I remember seeing references to papers on computer algebra in some of Maple's help files. They'd say stuff like "This function uses the method for ____ described by ___ in ______."
If people are working on such a beast, that would be a good reference. Not to mention that a lot of schools offer a grad course in Computer Algebra.
Greg
On using packages like Macsyma, many commercial ones seem to promise that they can solve your problems automatically. But for most non-trivial problems, what those packages shine at is bookkeeping during complex manipulations; the guidance and inspiration still needs to come from the user (and this is true of all of the packages I have used).
It's great that Macsyma is now officially free as Maxima (I had been using older versions that you could download but whose copyright status was complex). I hope Maxima will become a standard part of Linux distributions and that more people will start developing packages for it again.
--
--
Just lurking, thanks!