Maple Questions and Posts

These are Posts and Questions associated with the product, Maple

I tried to simplify it, but It didn't work that well.



I always feel that this formula can be further simplified, but there is no way to start. Of course, My thoughts maybe incorrect. maybe this is the simplest form.







for last 4 hrs, I've been chasing this problem.

Inside a module, there is a proc with name say foo(). local to the module. When creating an mla file that contains this module read from .mpl file, and running a test against it, Maple does not see this specific proc foo() as a proc, but only sees it as a symbol.

So the call to foo() never happens. I have a print statement inside foo() also which never prints. In the debugger, when I try to step into foo(), it fails also. Maple simply does not see it as a proc.

I also added my_module:-foo() in call, but this made no difference, even though it is not needed to prefix the module name, since foo is a local proc.

Now, instead of making an .mla, I now just read the .mpl file directly which make up the module. And now run the same test, and now maple see foo() as proc.  

No change in code at all. Nothing changed, exacept the test is called one time when package is inside the .mla vs. just using plain .mpl files.

It seems something goes wrong with symbol table or such when inside mla file.

When I do 

libname := currentdir(), libname;

And browse the content inside my mla file, I see no problems, it lists all 24 procs inside the package, and I can see foo() listed there as type PROC.

But in the code, what printing whattype(foo)  it says it is symbol when using mla file, but it says it is a procedure when not using mla, but just by reading the .mpl file which went into the .mla

I will try to make an example to reproduce this if I can. But has any one seen something like this before? What could cause this?  I've restated Maple ofcourse, and this made no difference.

The way I build the mla is


read cat(currentdir(),"/my_module.mpl");

For now, I will stop using .mla and just read the .mpl file each time to use the code, as this seems safer and this always worked and never gave me any problems.

I am using 2020.1 on windows 10.

I am not able to use Maple's map() to do the following. Given 2 lists of things (of equal length), map a function that take 2 arguments, from these 2 lists, in order.  Here is an example to illustrate. In Mathematica

a = {1, 2, 3}; b = {7, 8, 9};
MapThread[f, {a, b}]

           {f[1, 7], f[2, 8], f[3, 9]}

In Maple, I tried map and map2, map[n] etc.. not able to get the result I want. I want to use map, and not ~


          [f(1, [7, 8, 9]), f(2, [7, 8, 9]), f(3, [7, 8, 9])]



           [f([1, 2, 3], 7), f([1, 2, 3], 8), f([1, 2, 3], 9)]

and other things.

How to get same result as MapThread, using map?

In your answer, please include the calculation of the lamina's area and the location of its centre of mass.

Why doesn't this do the symbolic summation? Is there a way to get Maple to do it?

sum((-1)^n / n * x^n, n=1..infinity);

I have an expression  

product(q^(n -2)- q^i, i = 0 .. r )/product(q^(n-2) - q^(i+1), i = 0 .. r)


Obviously, it can be further simplified.

But in maple I can't do that, I use simplify and expand , all failed.


What should I do to get the simplified result I want?


Dear All,
I want to learn to work with Thread[Task] packages in Maple.However, I am confused when I studied the Help of Maple about. I can’t find out the Start and Continue command in the package. I can’t execute any simple program by Threads [Task]. The help of Maple has an example of the following:
cont := proc( a, b )
   return a + b;
end proc;      
task := proc( i, j )
   local k;
   if ( j-i < 1000 ) then
       return add( k, k=i..j );
       k := floor( (j-i)/2 )+i;
       Continue( cont, Task=[ task, i, k ], Task=[ task, k+1, j ] );
   end if;
end proc;
Start(task, 1, 10^7);

I want to remove if-clause in task procedure as the following. In the other words, I want to use multi-threads for any values of i and j. However, the program doesn’t work correctly. What hint is something I don’t correctly understand?

Besides, I may don’t find deeply out the meaning and deference of parent, leaf, child, and continuation tasks. would you explain to me those tasks easily? The help of Maple doesn't convey a unified explanation for them.
Please guide me to overcome the problem.
Best wishes,
cont := proc( a, b )
   return a + b;
end proc;      
task := proc( i, j )
   local k;
        k := floor( (j-i)/2 )+i;
       Continue( cont, Task=[ task, i, k ], Task=[ task, k+1, j ] );
end proc;
Start(task, 1, 10^7);

We tryto  find a solution to the differential equation f'(x)=f^(-1)(x).

I just noticed that Maple 2020.1 (but not plain 2020) has an issue with print to PDF if you have a plot3d on a page.

Anything after the plot3d output on the same page of the PDF file is simply not shown.

The issue seems to be with both Windows and Mac which makes me suspect its a Maple problem.

Any info on this? Any workarounds? We have students with written exams in a week so its a bit annoying.

Hi everyone...

How can anyone help me in the attached file? I want to know how the equation of the system turned into a dimensionless

dynamical system?



I did not know about these before. Was looking at

And wanted to display the actual values of $MAPLE,$TOOLBOX, $VERSION,$HOME gives about. 

But everything I tried does not work. 


Where are these things defined and how to display them from inside Maple to see where they point to?


Maple 2020.1 on windows 10


dAlembert ode has the form

Which also agrees with textbooks and Wikipedia



So the ODE should have   x  in there (the independent variable).  

Then why  in the following, when I give Maple ode of form   y=f(p)+g(p)  it says it is d'Alembert? notice that there is no x in there



I am not saying Maple is wrong, as I am not sure, but I am just trying to understand what is going on. All references I've seen so far say x should be there.  Otherwise, how did Maple determine it is dAlembert if not using the orginal form to check against?

The strange thing is calling dsolve on the ode, with no option gives different answer if calling dsolve telling it is is dAlembert:




Why it did not give the same result? 


I noticed the following. I have 2 worksheets. and  From, it does something as follows

libname := currentdir(), libname

Where foo() is entry inside my say TMP.mla in currentdir(). This works fine with no problems and foo() executes and complete OK.

Now I make changes to the code foo.mpl, and need to update TMP.mla. currently I use LibraryTools. But i'd like to delete TMP.mla each time and create new one so I am sure there is no problem. So from I run this code

libname:= currentdir(),libname;
read "foo.mpl";

This all works well, except it fails at the Remove line, since "TMP.mla" could not be removed, since it was open before when running the A workseet, and it seems to be still open and Maple could not delete the file.

So each time this happens, I close all worksheets, close Maple, open Maple again, and now I can run the above code OK to update the mla.

Is there a better way to do all of this?

I worry if I do not delete the mla each time, I could end up with old code there I do not want, if I rename things in my code. That is why I like to start with fresh mla file each time.  But I always have to restart Maple now to update the mla.


This year, the International Mathematics Competition for University Students  (IMC) took place online (due to Coronavirus),

One of the sponsors was Maplesoft.

Here is a Maple solution for one of the most difficult problems.


Problem 4, Day 1.

A polynomial p with real coeffcients satisfies the equation

p(x+1)-p(x) = x^100, for all real x.

Prove that p(x) <= p(1-x) for   0 <= x and x <= 1/2.


A Maple solution.

Obviously, the degree of the polynomial must be 101.

We shall find effectively p(x).






p:= x -> add(a[k]*x^k, k=0..n+1):

collect(expand( p(x+1) - p(x) - x^n ), x):


f:=unapply(expand(eval(p(1-x)-p(x), S)), x);

proc (x) options operator, arrow; (94598037819122125295227433069493721872702841533066936133385696204311395415197247711/16665)*x-37349543370098022593228114650521983084038207650677468129990678687496120882031450*x^3-1185090416633200*x^87+5974737180020*x^89-(86465082200/3)*x^91+133396340*x^93-597520*x^95+2695*x^97-(50/3)*x^99+x^100-(2/101)*x^101+(16293234618989521508515025064456465992824384487957638029599182473343901462949018943/221)*x^5-69298763242215246970576715450882718421982355083931952097853888722419955069286800*x^7+(113991896447569512043394769396957538374962221763587431560580742819193991151970540/3)*x^9-(450021969146981792096716260960657763583495746057337083106755737535521294639081800/33)*x^11+3451079104335626303615205945922095523722898887765464179344409464422173275181060*x^13-648776866983969889704838151840901241863730925272452260127881376737469460326640*x^15+(1224135636503373678241493336115166408006020118605202014423201964267584789018590/13)*x^17-(32609269812588448517851078111423700053874956628293000710950261666057691492700/3)*x^19+(17369174852688147212979009419766100341356836811271344020859968314555332168046/17)*x^21-79714896335448291043424751268405443765709493999285019374276097663327217200*x^23+(26225149723490747954239730131127580683873943002539194987613420614551124468/5)*x^25-294965074792241210541282428184641838437329968596736990461830398732050600*x^27+(186430797065926226062569133543332579493666384095775768758650822594552980/13)*x^29-608766986011732859031810279841713016991034114339196337222615083429200*x^31+22758671683254934243234770245768111655371809025564559292966948184145*x^33-755022138514287934394628273773230341731572817528392747252537299270*x^35+(380420681562789081339436627697748498619486609696130138245054547645/17)*x^37-596110444235534895977389751553577405150617862905657345084592800*x^39+(186546013247587274869312959605954587283787420112828231587660264/13)*x^41-313678397368440441190125909536848768199325715147747522784400*x^43+6254306446857003025144445909566034709396500424382183891144*x^45-114204496639521606716779723226539643746613722246036949600*x^47+1916927215404111401325904884511116319416726263341690260*x^49-29677354167404548158728688629916697559643435320275800*x^51+(93950257927474972838978328999588595121346462082404180/221)*x^53-5650787690628744633775927032927548604440367748960*x^55+69888520126633344286255800412032531913013033640*x^57-806279422358340503473340514496960223283853200*x^59+8696895011389170857678332370276446830499368*x^61-87900576836101226420991143179656778525600*x^63+(10844299000116828980379757772973769420469/13)*x^65-7447304814595165455238549781183862150*x^67+(1065245686771269279784908613651828005/17)*x^69-497741911503981694520541768814800*x^71+3738596479537236832468307626580*x^73-26593490941061853727808593704*x^75+179403449737703736809514420*x^77-1149393958953185579079600*x^79+(21007540356807993839074/3)*x^81-(121855249152521399900/3)*x^83+(3818021878637120462/17)*x^85 end proc


plot(f, 0..1); # Visual check: f(x)>0 for 0<x<1/2


f(0), f(1/4), f(1/2);

0, 2903528346661097497054603834764435875077553006646158945080492319146997643370625023889353447129967354174648294748510553528692457632980625125/3213876088517980551083924184682325205044405987565585670602752, 0


sturm(f(x), x, 0, 1/2);



So, the polynomial f has a unique zero in the interval (0, 1/2]. Since f(1/2) = 0  and f(1/4) > 0, it results that  f > 0 in the interval  (0, 1/2). Q.E.D.



1 2 3 4 5 6 7 Last Page 1 of 1707