Subject: problem calling MAXIMA function at lisp level
From: wang yin
Date: Mon, 13 Jan 2003 18:37:23 +0800
On Mon, Jan 13, 2003 at 11:01:35AM +0100, Ole Rohne wrote:
> Your example works as expected under cmucl/x86:
> /----
> (C1) FOO(X, Y) := X + Y + 3;
> (D1) FOO(X, Y) := X + Y + 3
> (C2) to_lisp();
> Type (run) to restart
> * (mfuncall '$foo 4 5)
> 12
> \----
>
> Note however what happens when the function name is typed in lower case:
> /----
> * (run)
> Maxima restarted.
> (C3) bar(x, y) := x + y + 3;
>
> (D3) bar(x, y) := x + y + 3
> (C4) to_lisp();
> Type (run) to restart
> * (mfuncall '$bar 4 5)
> (($BAR SIMP) 4 5)
This is where the problem is.
$bar is silently taken as $BAR and there isn't a function named $BAR here.
Only a $bar defined from the MAXIMA level.
Thank you very much :)
> * (apropos "$bar")
> |$bar| ;; From MAXIMA
> $BAR ;; From the lisp reader
> \----
>
> MAXIMA symbol case apparently works differently on different
> platforms.
>
> Ole
>
--
Wang Yin
DA Lab, Tsinghua University,
100084
Beijing China