>
> [Devel]
> 1. Question: aren't most functions (lisp files in src) really
> packages, only written in lisp?(If I got things right, this doesn't make
> that much a difference to maxima) I'd like the separation in a kernel and
> packages! For example: I simply won't ever (ok, maby once a month) use
> integration, diff,... so, if possible:
>
> separate kernel (to be defined) and packages as much as possible
>
> in the init file I tell maxima what I want to use always!
>
> maybe this would help to maintain things.
There is a concept of package in common lisp. A package is more
like a name space, parts of which can be exported or imported.
A function in lisp is a program which returns a value (or values).
Many functions are separable, and in fact historically much
of macsyma was loaded on demand. Thus integration was broken
up into several files, loaded only when needed. In reality,
much of this system (as well as other elaborate systems developed
over a long period of time) are not strictly functional. That is,
programs set flags, test flags, produce side effects. Entirely
separate modules are plausible only if ALL the environmental variables
are passed in some way between modules. Usually this is not
done and global flags are set, like how much expansion to do, how
many digits to carry in arithmetic, and hundreds of other things.
>
> 2. I like the standard for a position in mathematica, i.e. -1 is the last
> element in the list.
>
> 3. I like the idea of conversion, touched by Mr. Fateman and dan stanger
> earlier this year. But I'd find it good to have it the other way to. So I
> could do something in Maxima, and then look what Mathematica does with it.
>
> (I'm talking of "simple" things like sums and Intgrals and the like, no
> sophisticated macros)
>
> [user]
> 1.
> I don't quite understand dan stangers reply to my integerp question: He
> writes
>
>
>>No. When a symbol is declared INTEGER, automatic simplifications can
>>exploit this fact. For example, SIN(n*%pi) simplifies to 0 if n is
>>declared INTEGER. A symbol can be declared INTEGER if it is known to
>>represent an integer. INTEGER is a member of the FEATURES list. It
>>can be asserted with DECLARE, withdrawn with REMOVE, and detected with
>>FEATUREP.
>>
>
> What's IntegerP for, then, if it doesn't use features. I found it used
> quite often in nusum.mc for example.
Integerp tests to see if something is a specific integer. The integers
are 0, -1, 1, -2, 2, .... etc. I think Mathematica uses IntegerQ for
the same concept.
A symbol n is never an integer. It is a symbol.
You might say "assume n is an integer". That doesn't make n an
integer. It is a symbol.
Now you want another facility that answers "yes, n is an integer because
you said to assume n is an integer." Also n^2 is an integer. One could
also conclude that n^2>=0 and sin(n*%pi) is 0 and n is real, and
imagpart(n)=0, etc.
I think featurep(n,integer) is true
also
featurep(n^2,integer) is also true.
so this facility also exists, to some extent. But it is different from
Integerp.
>
>
> I feel, it should be there to test wheter x is an integer expression. So
> Declare(x,Integer); IntegerP(2^n);
> should give T.
Actually featurep(2^n,integer) gives false, because you have forgotten
that 2^(-1) is 1/2, and that is not an integer!
>
> If I want to test for a actual number, I would say
> IntegerP(x) and NumberP(x);
>
> By the way, what's the difference between assume and declare, in my
> opinion,
>
> declare(x,positive);
>
> and
>
> assume(x>0);
>
> should really be the same thing...
I think that you could certainly change declare to call assume,
but I tend to think of assume as providing geometric information,
and declare as providing category information, like n "is an integer".
There are probably better ways of thinking this through, but a
complete systematic plan should be considered, not just a patch
here and there. declare(x,positive) is currently not accepted.
>
> (By the way, KIND is not known at my maxima, but I didn't get the latest
> version yet!)
> ---------------
> 2.
> I really like to use
> [a,b]:[1,2];
>
> instead of
>
> a:1;b:2;
>
> but it doesn't work in 5.6! does it work in 5.9pre?