How to do matrix operation programatically in lisp
Subject: How to do matrix operation programatically in lisp
From: Kun Lin
Date: Tue, 27 Nov 2007 19:40:10 -0500
Hi All,
Thanks for you response and tips, it's being really helpful.
So got a couple questions below.
> But basically, I think it would be much neater to use Maxima as your base
> (or modify the parser/front end to Maxima), and add to it. If a Matlab
> language parser is what you need, I think that already exists somewhere.
by using maxima as my base you mean that i use something like imaxima or
emaxima? If that's the case
I would definitely check them out.
I am a little confused as to why i would want a matlab parser.
How does this parser differ from the existing build-in Maxima-to-lisp
parser (i.e #$expression$)?
I guess it would parse matlab syntax, but i like Maxima syntax better.
ps: in my previous reponse I gave examples on how i would use the
#$expression$ syntax.
- Kun
On Tue, 27 Nov 2007 10:15:35 -0500, Richard Fateman
<fateman at cs.berkeley.edu> wrote:
> I'm with Ray on this one in both respects:
> 1. I don't use them, but
> 2. I think that imaxima or emaxima has exactly the goal you need.
> If they work for you, your need for SLIME is met.
>
> However, it may be worth pointing out that, just as in lisp, there
> are subtleties that break this model.
> a. the meaning of an expression may vary depending on compiler
> declarations
> etc in the file in which it is embedded.
> b. the meaning of an expression may vary depending on the execution
> environment.
>
> so "compile expression" may not really work. Simple example (where Ray
> and
> I were working on the same file), we changed the input syntax of lisp so
> that quad-precision numbers could be read as #q3.1415926q0 for example.
> This broke the ability of emacs to grab an s-expression in the file..
>
> But basically, I think it would be much neater to use Maxima as your base
> (or modify the parser/front end to Maxima), and add to it. If a Matlab
> language parser is what you need, I think that already exists somewhere.
> RJF
>
>> -----Original Message-----
>> From: maxima-bounces at math.utexas.edu
>> [mailto:maxima-bounces at math.utexas.edu] On Behalf Of Raymond
>> Toy (RT/EUS)
>> Sent: Tuesday, November 27, 2007 6:39 AM
>> To: klin at umd.edu
>> Cc: maxima at math.utexas.edu
>> Subject: Re: [Maxima] How to do matrix operation
>> programatically in lisp
>>
>> Kun Lin wrote:
>> >> I'm curious why you don't just want to use maxima itself
>> and add the
>> >> necessary stuff you need in Lisp? You certainly can use
>> maxima as a
>> >> library for your Lisp code, but that seems backward.
>> >
>> > humm...
>> >
>> > My reason mostly is to stay in the emacs/slime
>> development environment.
>> > I guess i just really like C-c C-k (compile file) or
>> C-M-x (compile
>> > expression).
>> > In addition, since i am a beginner C-c C-d d and C-c C-d
>> h really helps.
>>
>> Ah, ok. I confess that when working with maxima, I use neither slime
>> nor imaxima or emaxima or whatever they're called. I just basically
>> reload the whole file that I'm editing. That's not so nice
>> compared to
>> slime.
>>
>> And the little bit of code I posted earlier to allow slime to talk to
>> maxima doesn't work so well, at least with the version of
>> slime I have.
>> I should try to update that so that it works. I should
>> also learn how
>> to use emaxima or imaxima, or whatever they're called.
>>
>> If both of those are working, you should get a nice slime environment
>> for hacking on the Lisp parts, and a nice maxima environment
>> for working
>> with maxima code.
>>
>> Ray
>> _______________________________________________
>> Maxima mailing list
>> Maxima at math.utexas.edu
>> http://www.math.utexas.edu/mailman/listinfo/maxima
>>
>