Mike Hansen wrote: > Of all the code I've read in lots of different languages, I think code > written for Mathematica has been the least transparent.
I guess I've always loved functional languages, so the simple core principles appealed to me right away. Some things I love include the consistency in naming (system things always start with a capital letter, leaving anything starting with a lowercase letter to the user; any function asking a boolean question ends in Q, etc), the ability to use postfix, prefix, and infix styles fairly naturally, the compact lambda notation, the functional ideology, etc. However, I don't like the monetary price, for me and for others trying to run my code or experiment with things, and I don't like being tied to a commercial entity. Both of those dislikes are strong enough for me to break with Mathematica when I can and use and publish work using SAGE and contribute where I can. I do admit, though, that you can often express things extremely compactly in Mathematica, which has a tendency to lead to very dense code that isn't very transparent; I see your point. Language issues aside, though, there are some _very_ nice user features in Mathematica, especially the latest version. For example, one small but very useful feature is that any variable that does not have a value attached is a different color in the front end and any variable that is a "dummy" variable in a command is a third color. Okay, back to the topic of what we can do in Sage and how to make Sage better... Thanks, -Jason > > --Mike > > On 9/26/07, Chris Chiasson <[EMAIL PROTECTED]> wrote: >> It might be worth pointing out that adding "new" syntax in Mathematica >> is (usually) done by assignments to the function that transforms >> general two dimensional input into source code. That isn't really the >> same thing as adding a new operator to the language itself. >> >> On Sep 26, 2:07 pm, Jason Grout <[EMAIL PROTECTED]> wrote: >>> cwitty wrote: >>>> On Sep 26, 7:31 am, Jason Grout <[EMAIL PROTECTED]> wrote: >>>>> Can we define custom infix operators? Suppose I'd like "boxproduct" to >>>>> be an infix operator. Could I make that work? >>>>> Thanks, >>>>> Jason >>>> If you're willing to put a lot of effort into the project, you might >>>> be able to do something with Logix (http://www.livelogix.net/logix/). >>>> >From the website: >>>> "Logix compiles to Python byte-code and can be freely mixed with >>>> regular Python modules. >>>> ... >>>> Logix syntax can be extended on the fly - even at the interactive >>>> prompt. Logix is like Lisp with extensible syntax. Or, Logix is Python >>>> with syntax extension, expression based syntax, and a powerful macro >>>> system." >>>> (I've never used Logix myself, only read some of their documentation.) >>> Wow!!! Thanks for sending this link. Logix seems to implement in Python >>> many of the Lisp-like things that make Mathematica such a nice system to >>> use. (like, in this discussion, the ability to define custom infix >>> operators, as well as a syntax for postfix function application, like >>> the Mathematica "x//Foo" for Foo[x] ). >>> >>> I can't spread myself too thin right now by working on Logix, but I'm >>> bookmarking it. For now, I'll go back to writing code/fixing bugs in >>> the Graph class. >>> >>> -Jason >> > > > > --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-devel@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://sage.scipy.org/sage/ and http://modular.math.washington.edu/sage/ -~----------~----~----~----~------~----~------~--~---