Maxima lists and the delete function



Dear Prof. Dr. Ziegenbalg,

This is a bug.  In the version of Maxima which I am running, 5.15.0
(GCL/Windows), delete(0,E1) yields [1,2,3,4] as expected.  What
version of Maxima are you running?

Beware, also, that Maxima is using an exact equality test in delete,
so that delete(0,[ 0, 0.0 ]) yields [0.0], not [].

           -s

Dr. Unprof. Stavros Macrakis


On Sat, Mar 21, 2009 at 7:32 AM, Prof. Dr. Jochen Ziegenbalg
<ziegenbalg at ph-karlsruhe.de> wrote:
> Dear Maxima users,
>
> in experimenting with lists (in wxMaxima) the following dialogue occured:
>
> input: ? ? ? ? ? ? ? ?E1 : [1,0,2,0,0,3,0,0,0,4];
> input: ? ? ? ? ? ? ? ?delete(0, E1);
> output: ? ? ? ? ? ? ?[1, 2, 0, 3, 0, 4]
>
> The Maxima manual suggests that all zeroes should be deleted. ?Why is
> this not the case? ?Is there an elegant way to delete all the zeroes?
>
> Thank you for your answer.
>
> Best regards,
> Jochen Ziegenbalg,
> Karlsruhe
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu
> http://www.math.utexas.edu/mailman/listinfo/maxima
>