Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Is the explicit use of the multiplication operator unnecessary?

20 views
Skip to first unread message

Peter Luschny

unread,
Mar 25, 2013, 4:49:14 AM3/25/13
to
On http://oeis.org/A223526 Udita Katugampola gives the following
script.

a[0]:= f(x):
for i from 1 to 20 do
a[i] := simplify(3^((i+1)mod 2)*x^(((i+1)mod 2+1)/3)*(diff(a[i-1], x
$1 )));
end do:
for j from 1 to 10 do
b[j]:=a[2j];
end do;

Executing it with Maple 16 I get the error message: "Error, missing
operator or `;`". This is what I expect. But when I alluded
Katugampola
to this he replied:

"This is Maple 16. If you have an old version this code may not work.
I checked the program again. It works very well. Just copy, past and
run."

What am I missing? Is there an option in Maple 16 which makes
the explicit use of the multiplication operator unnecessary?

Peter

Nasser M. Abbasi

unread,
Mar 25, 2013, 5:19:59 AM3/25/13
to
On 3/25/2013 3:49 AM, Peter Luschny wrote:
> On http://oeis.org/A223526 Udita Katugampola gives the following
> script.
>
> a[0]:= f(x):
> for i from 1 to 20 do
> a[i] := simplify(3^((i+1)mod 2)*x^(((i+1)mod 2+1)/3)*(diff(a[i-1], x
> $1 )));
> end do:
> for j from 1 to 10 do
> b[j]:=a[2j];
> end do;
>
> Executing it with Maple 16 I get the error message: "Error, missing
> operator or `;`". This is what I expect. But when I alluded
> Katugampola
> to this he replied:
>

change 2j with 2*j in the above.

In Document mode, it works as is. But in worksheet mode you need *


--Nasser

peter....@gmail.com

unread,
Mar 25, 2013, 6:47:38 AM3/25/13
to n...@12000.org
> In Document mode, it works as is. But in worksheet mode you need *

Thank you, Nasser. I never use 'document mode' when writing simple
scripts. Thus using this makes the code not downward compatible.
How unfortunate to use this mode in OEIS.

Are there other basic syntactical differences between the two modes
(ignoring images, plots, tables, sketches, spreadsheets and such alike)?

Peter

Nasser M. Abbasi

unread,
Mar 25, 2013, 6:57:14 AM3/25/13
to
Peter,

I am not an expert on this. I do not use Document mode at all,
as I do not like the interface. When I use Maple, I only use
worksheet mode, and I changed the input mode to be 'maple input'.

This page has lots of discussion on this:

http://www.mapleprimes.com/questions/41642-Document-Mode-Vs-Worksheet-Mode-In-Maple-11

--Nasser





peter....@gmail.com

unread,
Mar 25, 2013, 8:29:46 AM3/25/13
to n...@12000.org
> I am not an expert on this. I do not use Document mode at all,
> as I do not like the interface. When I use Maple, I only use
> worksheet mode, and I changed the input mode to be 'maple input'.
> This page has lots of discussion on this:
> http://www.mapleprimes.com/questions/41642-Document-Mode-Vs-Worksheet-Mode-In-Maple-11

Thanks for this link. There are many good arguments
there to support my prejudices against 'modern Maple'
(or 'document mode' as it seems to be called).

For example a certain JacquesC writes there:

"If you know what you are doing (ie know Maple syntax),
then worksheet mode is much more efficient (for both
the user and the system). It also has the additional
advantage that the GUI does not try to 'guess' what
you mean by what you have entered [..]."

So I will stay happily with my old Maple V and mourn the
fact that Maple-incompatibilities now also will
plague such a valuable database as OEIS.

Peter
0 new messages