Loeky Haryanto

20 Reputation

2 Badges

6 years, 14 days

MaplePrimes Activity


These are questions asked by Loeky Haryanto

 

For example, the column dimension is 6 and I ran the following command,

A := Mod(2,Matrix(3,6,(i,j)->if i<2 and j < 3 then 1  elif i = 2 and j > 2 and j <5 then 1 else 0 end if),float[8])

the result is the following matrix with the last row containing all 0s. 

A := Matrix(3, 6, [[1., 1., 0., 0., 0., 0.], [0., 0., 1., 1., 0., 0.], [0., 0., 0., 0., 0., 0.]])
Actually, I want the last row containing all 1s but I do not know how.
Any help?

 

Hi, I am trying to run the following command in a Maple worksheet

P:= 1979 #(this is the1000-th prime);
S:=5000; k:=5:
a:=[0$i=1..k];
f:=[0$i=1..k];
a[1]:=S;
f:=x->a[1];
with(RandomTools):
for i from 2 to k do
a[i]:=Generate(integer(range=1..P-1));
f:=x->f(x)+a[i]*x^(k-1);
print(f(x));
od;

(This is a beginning step to create the Shamir's secret sharing).
However, I get the following output (with explanations)

                              5000          (This is correct. the value a[1])
x -> a[1]                                   (This should be the initial function f = 5000)
                              7005          (This is correct, the value a[2])
x -> f(x) + a[i] x^(k-1)               (one of the main problems, see below)

The main problems are in the last output above:
1. The f(x) is not as it should be: f(x) = a[1] = 5000;
2. The index i isn't changed when it should be i = 2;
3.  An error message: too many levels of recursion  

The output (I expect) should be: 5000 + 7005x, ...., etc.

Thanks in advanced for any help.

Hi, 
I love programming in Maple and I am interested in using MapleNet to display Maplets I have created. However, I am a novice in software and web technology. My questions, do I only need creating Maple worksheets, establishing interfaces and uploading the worksheets at an appropriate server in order to be able using MapleNet without any additional software? Can MapleNet display both GUI-based and command-driven-based Maplets on the web? Btw, I already read and downloaded "5 Developing Worksheets for MapleNet" but I do not fully understand its contents due to technical terms used in it.
I noticed that the following website: http://www.maplenet.net/ offers web services commercially. Does this website
have any relationship with MapleNet from Maplesoft or one of the most appropriate servers to upload and play our worksheets with MapleNet?

Thanks in advance for any helpful reply.

Loeky

email: L.Haryanto@unhas.ac.id


Dear readers,

I want to assign a name, say Lett with D (not the string "D", just the symbol D). I cant do that thoug I already use the command 'unprotect(D)':

> unprotect(D);
   Lett:=D

How can I be succeeded to do it?

Page 1 of 1