MaplePrimes Questions

I'm trying to construct an iterative procedure al1(f,x0) where f is a function, x0 is an initial estimate.

Now for example by defining f:= x-> 4*x^4-4*x^2 and inputting x0=0.75 and N=10 i should be able to check that my procedure calculates 1 correctly.

f := x -> 4*x^4 - 4*x^2;
f1 := D(f);
f2 := D(f1);
x0 := 0.75;
Digits := 100;
tol := 10.^(-15);

al1:= proc(f,x0)
local y, z, s, i, fs, a, de;
s := x0:
for i from 1 to 10
while abs(fs)>tol and de>tol do
y := evalf(s- f(s)/f1(s)):
end do:
return n, s, fs, de;
end proc;

> n, s, fs, de := al1(f, 0.75);
Error, (in al1) cannot determine if this expression is true or false: 0.1000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000e-14 < abs(fs) and 0.1000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000e-14 < de


The code i've written so far is incorrect but i'm not sure where i'm going wrong. Would you be able to give me some pointers?


Hi !

Sorry but there is a bug in the "combine" command when combining double summations.
 Maple 2017,2018 and 2020 all give me a wrong answer. I have an old version of Maple which gives the correct answer.
I have put an example in the attached file.

Best regards

Hello. looking for the numerical or analytical solution of the attached file and at the needed expression or value of lambda for different values of the involved parameter?


I need the non-dimensional form of PDE with given non-dimensional variables. I have attached a worksheet please check it. 

Thank you

Maple Worksheet - Error

Failed to load the worksheet /maplenet/convert/ .


Maple Worksheet - Error

Failed to load the worksheet /maplenet/convert/ .




hello dear friends

i want to solve an equation about adding three cosine term which are constrained:

cos(2 pi(x+y-2z))+cos(2 pi(y+z-2x))+cos(2 pi(z+x-2y))=0 

with constraint 0<x<1,x<y<1,y<z<1

can some one please guide me?

i wrote this command but it did not work:

solve({cos(2*Pi*(x+y-2*z))+cos(2*Pi*(y+z-2*x))+cos(2*Pi*(z+x-2*y)) = 0, 0 <= x, x <= 1, y <= 1, z <= 1, x < y, y < z}, [x, y, z], explicit)

Hi MaplePrimes team,


Does Maple have a step detection command for a given step function f(x)?

The command has to return a list of jump detections in a given range [xmin... xmax].

For example, can Maple find the following jump detections:


Figure 1 (trivial case): f(x) = floor(x)

where it is easy to guess the list of step detections: [x1 = 1, x2 = 2, x3 = 3, …, xn = n]


Figure 2: g(x) = 2 + floor(x + 5*sin x)

a little more difficult.


Thank you in advance.



Maple 2021.1/Windows 10.

When entering 2d expressions into the bottom line of a worksheet, i.e. at the bottom of the window, I can't see the underscores used to indicate bracketing.

A workaround is to use ^J to get another input prompt at the bottom of the window.

Is there some way to get a bigger margin at the bottom of the window?





In Maple 2020, the following line works fine:






With Maple 2021, I get


Interestingly, the exported PNG is better with Maple 2021 (not blurry as in Maple 2020). However, there is an alignment problem with the axes. And it appears in Maple, before exporting. Bug?

(Maple 2020/2021 on Windows 10)

Hi, Is it possible to convert a code written in Mathematica into maple correctly?

I need to check if an expression is polynomial in but with coefficients that are either symbolic, or do not include the complex numebr I.

The problem is that maple considers integers and reals complex also.   

type(1,complex) gives true. so I can't use


Since this gives false. 

I could instead list all the types to be accepted using Or, like this


But I might overlook something if I have to enumerate every type accepted. It is easier to just exclude complex numbers. 

What is the correct way to tell Maple to check if expression is polynomial in where coefficients do not have the complex I in them? It it ok if the coefficient are any other numeric value, or a known Maple constant, or a parameter (symbol). I just want to exclude complex numbers.

I know I could do this

if not has(the_poly,I) then
   print("not allowed");

But I wanted to learn how to make a type which excludes complex numbers.

Maple 2021.1

Hi, Can one have look at my attached picture of the problem then solve in maple to get the required results mentioned in the picture.

Given an expressions such as 


I want to use indets to find only the mathematical functions in it, and also symbol but only x symbol in this above. I can do the following to find the mathematical functions and symbols, but I do not know how to tell it to find type symbol which happend to be x. Since x is not a type.

lis:=indets(expr,  Or( And(type_1),  type_2 ))

Which gives

But I really wanted this output

I know I can post process the outout using has or remove, to remove symbol y. But is it possible to do that using indets? something similar to specfunc but specsymbol ? I looked at the help page for Definition of a Structured Type in Maple but do not see anything there so far.

I tried

lis:=indets(expr,  Or( And(type_1),  And(type_2) ))

but it gives same output.



I need to calculate dozens of piecewise-defined  (but elementary) definite integrals of the following kind. Maple returns them unevaluated. Is there a trick to force evaluation? 

u := piecewise(0 <= x and 0 <= y and y <= x, x-1, 0 <= x and 0 <= y and x <= y, x, 0);
v := piecewise(0 <= x and 0 <= y and y <= x, x-1, y <= 0 and 0 <= x and -x <= y, x-1, 0);
plot3d(u*v, x=-1..1, y=-1..1);
# integrating over (0,1)x(0,1) works
int(u*v, x=0..1, y=0..1);
# but integrating over (-1,1)x(-1,1) returns unevaluated.
# How to force evaluation on (-1,1)x(-1,1)?
int(u*v, x=-1..1, y=-1..1);


Hi, I have a table-based package P I am working with and I would like to do the following:

Use a submodule (call it A) of the package. A uses another submodule (call it B) within the package to run a calculation. I'd like to replace B with my own subpackage C (independent of P) as another verification step. Is this possible? I would like to avoid making changes to A as much as possible.





given one equation where both sides are polynomials in one variable x, like this


And we want to solve for the coefficients on the LHS, which are c1,c2,c3.  By hand, this is solved by expanding both sides, and then comparing the coefficient of each power of x. This generates 3 equations (in this example) and then these are solved for c1,c2,c3.

Is there a way to automatically do this in Maple without the user having to do the first manual step of generating the equations needed to solve for c1,c2,c3?



              {c1 = -4, c2 = 3, c3 = 0}

But It will be nice if there is a command in Maple which will do it starting from the first equation. Ofcourse one has to tell Maple what to solve for. PDEtools:-Solve(eq,[c1,c2,c3]); or solve(eq,[c1,c2,c3]) does not work, because Maple does not know it needs to expand and compare coefficients as we do by hand.

It is not hard to write code to generate these equations, but I am asking if there is already a command in Maple which somehow does it automatically. I looked at SolveTools, but did not spot something yet there.


Ok, I think this is easy to do. I found a command


{c1 = -4, c2 = 3, c3 = 0}



First 6 7 8 9 10 11 12 Last Page 8 of 2044