Maple 2021 Questions and Posts

These are Posts and Questions associated with the product, Maple 2021

PlaneDual returns the plane dual of a planar graph G, that is, a graph with faces of G as its vertices in which two vertices are adjacent if and only if they share an edge as faces of G. Of course, this is a little different from the standard definition of plane dual. (Interlude: I estimate that the two definitions are equivalent in the case that the planar graph is 3-connected simple graph)

It's not hard to find a plane dual of a planar graph in Maple. 



Since all labels of the dual graph are used numbers 1..n in maple, I cannot see how its vertices correspond to the face of the original graph.  And further, I want to know one edge of the dual graph corresponds to which edge (should be the boundary on two faces) of the original planar graph.

Maybe input {1,4} of the dual graph and output {2,4} of the original graph.

For example, Input {1} that is a vertex of  dual graph  to get the original face {2,3,4} and if we input {1,4} of the dual graph, we will output edge {2,4} of the original graph.

I don't know if there's a good way to do that.




    here a problem when i solve equations.i guess solve lost a can i do.


I'm having an issue with MacOS Big Sur 11.4 recognizing a package from saved documents. The package works great from new documents! 

I've followed the instructions on
to add  a .mapleinit
file to my user home directory under MacOS Big Sur 11.4

The .mapleinit file has code as follows to run the VLA package: 
VLAlibpath := "/VLA/library/":
libname := `VLAlibpath`, libname:
and I have the VLA package files with the library inside of it in my home directory too. 

When I open a new Maple document and run and use the package, it works just fine! 

The problem though is that if I save the Maple file and reopen it, it will no longer recognizes the package. I get: 
Error, invalid input: with expects its 1st argument, pname, to be of type {`module`, package}, but received VLA

It is very odd since the file still recognizes the libname just fine:
libname;   "VLA/library/", "/Library/Frameworks/Maple.framework/Versions/2021/lib"

The workaround is to copy and paste into a new document and start a fresh but that is obviously not ideal. 

Any ideas? It is a really really old package, but great for visualization.



I am using Maple in Document mode and I want to print my worksheet. Is there a possibility to show the page margins as an overlay so that I can adjust the lines of my worksheet in order to avoid automatic breaks making the print difficult to read?


I have a function of 3 variables (PiM) which I can use in plot3d given the first argument while the other two arguments are functions of the two variables I use in plot3d.

In the code I attached below, I am plotting 2 planes using plot3d, but I cannot implicitplot where these two planes intersect. COuld you please take a look at my code?





Is there a way to change the font type and size when printing a table of data using DocumentTools:-Tabulate? Also can I change the column width?

I can't figure this one out.

I need to pick out the subexpression   anything*sin(3*x) from an expression.

it works, when the expression is   anything*sin(3*x)+something else. But when the expression is exactly  anything*sin(3*x) then select returns and not anything*sin(3*x) as I was expecting.

So I must be doing something silly, but do not see it.

TypeTools:-AddType('type_1', '`*`'({anything,identical(exp(3*x))}));

returns true. good. Now I test it on 

select(type,expr+sin(x),type_1) ;

and this returns what is expected. 25*A[1]*exp(3*x) but when I type

select(type,expr,type_1) ;

it return

reading select help page did not help.  Tried flatten, inplace.

I can do this using patmatch


But why is select not working in the above? What is the correct way to do this so it works for a*expr+anything and also for a*expr only? This is done inside a function and not interactive. So I need it to work for both cases, since the input can be anything, but I only need the term anything*exp(3*x) pulled out.


I want to have a proc, which returns an expression using an indexed symbol. The proc needs to basically generate constansts to use to build an expression, similar to how dsolve uses _Cn.  But I do not want to use _Cn for this so not to confuse the expression with another one that was generated using _Cn already.

So I thought to use a local symbol say A.  (I could have used _Zn also, but I think _Z is also used by Maple).

The symbol A is first declared local to the proc, and then the proc returns the expression using A[n]. For example  A[0]*x+A[1]*x^2 etc... The number of A[n]'s is not known before hand, but should not be more than 10. 

I want to make sure that A[n] returned is really part of the local symbol and not different symbol to avoid clash with any global A[n] 

When I do the following check

 local A;
 return A[99]
end proc;




good. So Maple says that A[99] is not global. But when I do


it also says false!

My question is: When making local A , will A[1] and A[2] also be local, or are they different symbols? Maplemint says nothing about it, so I assume A[n] is local also?

Procedure foo() 
  These local variables were used but never assigned a value:  A

It did not say that A[99] was never declared local. This tells me that A[99] is local, because A is local. But then why did type(expr,`local`)  say false?


I was wondering why each time solve is executed, I get a different of number of solutions and can I specify the number of solutions?


Thanks so much for taking time to answering this question.


Maple Worksheet - Error

Failed to load the worksheet /maplenet/convert/ .

I don't way the above error happened. But here is my worksheet below.


Given an expression, how to best find the constants _C1, _C2, etc.... in this expression?  Currently I do the following, but I think there should be a better way.

select(x->`if`(type(x,symbol) and convert(x,string)[1..2]="_C",true,false),indets(sol))

The above works, at least on the few examples I tried it on, but is there a better way to do it?  All constants will have the form _Cn where n is integer. 



Why is this integral so difficult -- so slow to execute?

     hypergeom([1/k*I],[1],k*v*I)*v^n,v = 0 .. 1/2*R), s=0..s_max)), n=0..1);

Hints to improve the efficiency of execution would be appreciated.

The conversion of a maple formula in latex version 2021 produces some

commands which are not defined , see

Perhaps more informations should be given  in the news about the command latex in Maple 2021


I need to find all the variants (I am not sure if this is the correct term to be used but I hope this will be clear in the example) of a specific indeterminate in a given expression.  Here is an example:

alpha[3, 5]*xi[1]*xi[8] + alpha[3, 5]*xi[4]*xi[5] + alpha[3, 3]

For this particular example, xi[1], xi[8], xi[4], and xi[5] are the variables I am looking for. The indexes of xi change depending on the previous calculation.  Also, in some cases, I need the alpha variables instead, that is, alpha[3,5], and alpha[3,3].  

I could not figure out how to use indets in this case.

Many thanks for your help. 

I may be misunderstanding the documentation of implicitplot.  Can someone set me straight?

This is extracted from the implicitplot's help page:

implicitplot(-x^2 + y, x = 0 .. 2, y = 0 .. x);

The plotting range is limited to y ≤ x, as intended.  Let us verify that it does the right thing:

	implicitplot(-x^2 + y, x = 0 .. 2, y = 0 .. x, color=red),
	plot(x, x=0..2, color=blue)

Yes, indeed it does.

Now let us try limiting the plotting range to y ≤ 1 − x2. Here is what we get:

	implicitplot(-x^2 + y, x = 0 .. 2, y = 0 .. 1-x^2, color=red),
	plot(1-x^2, x=0..2, color=blue)

I expected the red curve to lie entirely below the blue curve but it doesn't. Am I misunderstanding implicitplot?

Download worksheet:

Sorry to bother you with a basic question again.

How do I get both the indexes and the values of a table?


4 5 6 7 8 9 10 Last Page 6 of 15