Maple Questions and Posts

These are Posts and Questions associated with the product, Maple

Maple 2024 had a very well defined "Stop Execution" symbol on the desktop.  

Maple 2025 doesn't have an obvious symbol somewhere.  Also, the two little "dots" that I once had in the lower left bottom in Maple 2025 have disappeared! There is only a bar at the bottom which seems to do nothing.

Someone should please help me compute the left and right eigenvectors of the system below. The purpose is to compute values for 'a' and 'b' in the bifurcation formula.

Thank you

``

with(VectorCalculus)

 

(1)

interface(imaginaryunit = I)

I

(2)

I

I

(3)
 

diff(S(t), t) := `Λ__p`-(`#mrow(mi("ϕ",fontstyle = "normal"),mo("⋅"),msub(mi("θ",fontstyle = "normal"),mi("B")),mo("⋅"),msub(mi("I"),mi("B")))`/N[p]+µ__C)*S+`ω__B`*I__B

Lambda__p-(`#mrow(mi("ϕ",fontstyle = "normal"),mo("⋅"),msub(mi("θ",fontstyle = "normal"),mi("B")),mo("⋅"),msub(mi("I"),mi("B")))`/N[p]+µ__C)*S+omega__B*I__B

(4)

diff(I__B(t), t) := `#mrow(mi("ϕ",fontstyle = "normal"),mo("⋅"),msub(mi("θ",fontstyle = "normal"),mi("B")),mo("⋅"),msub(mi("I"),mi("B")))`*S/N[p]-`ω__B`*I__B-(`σ__B`+µ__C)*I__B

`#mrow(mi("ϕ",fontstyle = "normal"),mo("⋅"),msub(mi("θ",fontstyle = "normal"),mi("B")),mo("⋅"),msub(mi("I"),mi("B")))`*S/N[p]-omega__B*I__B-(sigma__B+µ__C)*I__B

(5)

NULL

``

(6)

diff(S__A(t), t) := `Λ__A`-(µ__A+`#mrow(mi("ϕ",fontstyle = "normal"),mo("⋅"),msub(mi("α",fontstyle = "normal"),mi("B")),mo("⋅"),msub(mi("I"),mi("B")))`/N[p])*S__A+`δ__A`*I__A

Lambda__A-(µ__A+`#mrow(mi("ϕ",fontstyle = "normal"),mo("⋅"),msub(mi("α",fontstyle = "normal"),mi("B")),mo("⋅"),msub(mi("I"),mi("B")))`/N[p])*S__A+delta__A*I__A

(7)

diff(I__A(t), t) := `#mrow(mi("ϕ",fontstyle = "normal"),mo("⋅"),msub(mi("α",fontstyle = "normal"),mi("B")),mo("⋅"),msub(mi("I"),mi("B")))`*S__A/N[p]-(µ__A+`δ__A`)*I__A

`#mrow(mi("ϕ",fontstyle = "normal"),mo("⋅"),msub(mi("α",fontstyle = "normal"),mi("B")),mo("⋅"),msub(mi("I"),mi("B")))`*S__A/N[p]-(µ__A+delta__A)*I__A

(8)

NULL

``

(9)

Download CBD2.mw

It is not difficult to manually check the validity of the identity  sqrt(x+2*sqrt(x-1)) = sqrt(x-1)+1 , which is true at least for all  x>=1 . I don't know of any Maple command that directly makes this simplification:

expr:=sqrt(x+2*sqrt(x-1));
simplify(expr);
simplify(expr) assuming x>=1;

                          


It was possible to simplify it only by making a variable substitution  x=y+1 (and then a reverse substitution  y=x-1 ) :

expr1:=subs(x=y+1,expr);
simplify(expr1);
subs(y=x-1, %);

                               


By the way,  the CAS Mathematica also cannot cope with simplifying the expression  expr .

Wondering what the experts here think of this. Should not simplify have worked on this automatically? By trial and error, found that combine command is what simplified it the best.

But I think simplify should also have done the same.  

Interested to hear what others think, and why simplify (even using trig option) did not do it.   

The issue is that this is done in code, without lookin at the screen and deciding what to do based on what the expression "looks like".

interface(version);

`Standard Worksheet Interface, Maple 2025.0, Linux, March 24 2025 Build ID 1909157`

A:=(((sin(sqrt(3)/2)*sqrt(3) - 3*cos(sqrt(3)/2))*cos(sqrt(3)*x/2) - sin(sqrt(3)*x/2)*(sqrt(3)*cos(sqrt(3)/2) + 3*sin(sqrt(3)/2)))*exp(-1/2 + x/2))/3 ;

(1/3)*((sin((1/2)*3^(1/2))*3^(1/2)-3*cos((1/2)*3^(1/2)))*cos((1/2)*3^(1/2)*x)-sin((1/2)*3^(1/2)*x)*(3^(1/2)*cos((1/2)*3^(1/2))+3*sin((1/2)*3^(1/2))))*exp(-1/2+(1/2)*x)

B:=- exp(-1/2 + x/2)*(sqrt(3)*sin(sqrt(3)*(x - 1)/2) + 3*cos(sqrt(3)*(x - 1)/2))/3;

-(1/3)*exp(-1/2+(1/2)*x)*(3^(1/2)*sin((1/2)*3^(1/2)*(x-1))+3*cos((1/2)*3^(1/2)*(x-1)))

simplify(A-B); #show these are same

0

simplify(A,trig)

-(1/3)*((-sin((1/2)*3^(1/2))*3^(1/2)+3*cos((1/2)*3^(1/2)))*cos((1/2)*3^(1/2)*x)+sin((1/2)*3^(1/2)*x)*(3^(1/2)*cos((1/2)*3^(1/2))+3*sin((1/2)*3^(1/2))))*exp(-1/2+(1/2)*x)

simplify(A)

-(1/3)*((-sin((1/2)*3^(1/2))*3^(1/2)+3*cos((1/2)*3^(1/2)))*cos((1/2)*3^(1/2)*x)+sin((1/2)*3^(1/2)*x)*(3^(1/2)*cos((1/2)*3^(1/2))+3*sin((1/2)*3^(1/2))))*exp(-1/2+(1/2)*x)

simplify(A,size)

-(1/3)*((-sin((1/2)*3^(1/2))*3^(1/2)+3*cos((1/2)*3^(1/2)))*cos((1/2)*3^(1/2)*x)+sin((1/2)*3^(1/2)*x)*(3^(1/2)*cos((1/2)*3^(1/2))+3*sin((1/2)*3^(1/2))))*exp(-1/2+(1/2)*x)

simplify(normal(A))

-(1/3)*((-sin((1/2)*3^(1/2))*3^(1/2)+3*cos((1/2)*3^(1/2)))*cos((1/2)*3^(1/2)*x)+sin((1/2)*3^(1/2)*x)*(3^(1/2)*cos((1/2)*3^(1/2))+3*sin((1/2)*3^(1/2))))*exp(-1/2+(1/2)*x)

combine(A); #finally

(-(1/3)*3^(1/2)*sin((1/2)*3^(1/2)*(x-1))-cos((1/2)*3^(1/2)*(x-1)))*exp(-1/2+(1/2)*x)

 

 

Download simplify_vs_combine_june_4_2025.mw

Hello, 

I'm working on a Maple package that manages external processes via TCP connections. I'm using ModuleUnload for cleanup, but I need to better understand how it behaves during Maple termination.

The issue:
- I have a module that manages external processes (via TCP connections)
- I implemented ModuleUnload to kill these processes when the module is unloaded
- ModuleUnload works perfectly when using 'restart' 
- However, when closing the Maple window, the external processes remain active

Investigation:
Using 'lsof', I observed that:
   - When Maple closes, it properly closes its TCP connection (goes to CLOSE_WAIT state)
   - But the external processes remain active

Questions:
1. Is this the expected behavior of ModuleUnload during session termination?
2. Are there alternative approaches to ensure cleanup when Maple is closed?

Any insights or suggestions would be greatly appreciated!
Thanks!

I used Maple’s odetest to check the validity of 36 exact solutions.

About half of them return zero, meaning they satisfy the ODE correctly. But the other half don’t — odetest gives nonzero expressions.

My question is:

Could there be a mistake in my assumptions, or are some of these solutions only valid under specific conditions?

I’d appreciate any clarification or suggestions.

ode-test-36.mw

Respected sir,

I sincerly apologize to take your valuable time.

kind help with construction of function for the question in the word file attached.

Kind help please it may be simple too.

Kind_help.pdf

I've been debugging this for 20 hrs and finally able to make an example.

I noticed that solve() suddenly no longer works and times out.

First time calling solve() works. Second time it I see message

               Warning, solve may be ignoring assumptions on the input variables.

And it hangs.  Same exact code.   It has to do with calling odetest before and using Physics:-Setup('assumingusesAssume' = false):

i.e. this works
  
     odetest(...) assuming integer
     solve(....) #no hang
     odetest(....) assuming positive

     odetest(...)  assuming integer
     solve(....)  #no hang


But this does not work

     odetest(...) assuming integer
     solve(....) #no hang
     Physics:-Setup('assumingusesAssume' = false):
     odetest(....) assuming positive
     Physics:-Setup('assumingusesAssume' = true):

     odetest(...) assuming integer
     solve(...)   #HANGS
     

Here is worksheet showing the problem. If I remove first call to odetest, solve do not hang.

Also removing Physics:-Setup('assumingusesAssume' = false):, solve also works OK. (ie. does not hang)

So it has to do with some internal caching which causes solve to stop working.

Can others reproduce this and can cause it and how to fix it so solve do not hang second time?

The input used below is not important. It is just what I found to cause this. One would expect solve() to work same way for same input all the time.

Also, same problem happens when using PDEtools:-Solve instead of solve. It hangs second time.

interface(version);

`Standard Worksheet Interface, Maple 2025.0, Linux, March 24 2025 Build ID 1909157`

Physics:-Version();

`The "Physics Updates" version in the MapleCloud is 1873 and is the same as the version installed in this computer, created 2025, May 18, 21:44 hours Pacific Time.`

SupportTools:-Version();

`The Customer Support Updates version in the MapleCloud is 20 and is the same as the version installed in this computer, created May 23, 2025, 23:34 hours Eastern Time.`

restart

DEFINE input

 

ode:=y(x)*sqrt(1 + diff(y(x), x)^2) - a*y(x)*diff(y(x), x) - a*x = 0:
sol:=-_C4^2 + (-y(x)*sqrt(_C4^2/y(x)^2) + a*x)^2/a^2 + y(x)^2 = 0:
ode_to_test:=y(x)*(1+diff(y(x),x)^2)^(1/2)-a*y(x)*diff(y(x),x)-a*x = 0:

FIRST TIME solve works

 

    try
        timelimit(30,(odetest(sol,ode,y(x)) assuming integer));
    catch:
        NULL;
    end try:

    try
        timelimit(30,[solve(ode_to_test,diff(y(x),x))]);
        print("SOLVE worked");              
    catch:
        print("WHY TIMED OUT??");              
    end try:

    Physics:-Setup('assumingusesAssume' = false):
    try
        timelimit(30, (odetest(sol,ode,y(x)) assuming positive) );
    catch:
        NULL;
    end try:
    Physics:-Setup('assumingusesAssume' = true):

"SOLVE worked"

 

 

RUN SAME CODE AS ABOVE again, now it does not work

 

    try
        timelimit(30,(odetest(sol,ode,y(x)) assuming integer));
    catch:
        NULL;
    end try:

    try
        timelimit(30,[solve(ode_to_test,diff(y(x),x))]);
        print("SOLVE worked");              
    catch:
        print("WHY TIMED OUT??");              
    end try:

    Physics:-Setup('assumingusesAssume' = false):
    try
        timelimit(30, (odetest(sol,ode,y(x)) assuming positive) );
    catch:
        NULL;
    end try:
    Physics:-Setup('assumingusesAssume' = true):

Warning, solve may be ignoring assumptions on the input variables.

"WHY TIMED OUT??"

 

 

 

 

Download why_solve_stops_working_maple_2025_may_28_2025.mw

This worksheet below shows that by removing Physics:-Setup('assumingusesAssume' = false): now solve works OK second time. (I turn on/off Physics:-Setup('assumingusesAssume' since I found sometimes it can help with odetest to turn it off in some other cases. But now I am scared of touching this setting as it seems to have side effects internally)

interface(version);

`Standard Worksheet Interface, Maple 2025.0, Linux, March 24 2025 Build ID 1909157`

Physics:-Version();

`The "Physics Updates" version in the MapleCloud is 1873 and is the same as the version installed in this computer, created 2025, May 18, 21:44 hours Pacific Time.`

SupportTools:-Version();

`The Customer Support Updates version in the MapleCloud is 20 and is the same as the version installed in this computer, created May 23, 2025, 23:34 hours Eastern Time.`

restart

DEFINE input

 

ode:=y(x)*sqrt(1 + diff(y(x), x)^2) - a*y(x)*diff(y(x), x) - a*x = 0:
sol:=-_C4^2 + (-y(x)*sqrt(_C4^2/y(x)^2) + a*x)^2/a^2 + y(x)^2 = 0:
ode_to_test:=y(x)*(1+diff(y(x),x)^2)^(1/2)-a*y(x)*diff(y(x),x)-a*x = 0:

FIRST TIME solve works

 

    try
        timelimit(30,(odetest(sol,ode,y(x)) assuming integer));
    catch:
        NULL;
    end try:

    try
        timelimit(30,[solve(ode_to_test,diff(y(x),x))]);
        print("SOLVE worked");              
    catch:
        print("WHY TIMED OUT??");              
    end try:

    try
        timelimit(30, (odetest(sol,ode,y(x)) assuming positive) );
    catch:
        NULL;
    end try:

"SOLVE worked"

 

 

RUN SAME CODE AS ABOVE again, now it does not work

 

    try
        timelimit(30,(odetest(sol,ode,y(x)) assuming integer));
    catch:
        NULL;
    end try:

    try
        timelimit(30,[solve(ode_to_test,diff(y(x),x))]);
        print("SOLVE worked");              
    catch:
        print("WHY TIMED OUT??");              
    end try:

    try
        timelimit(30, (odetest(sol,ode,y(x)) assuming positive) );
    catch:
        NULL;
    end try:

"SOLVE worked"

 

 

 

 

Download why_solve_stops_working_maple_2025_may_28_2025_V2.mw

restart;

with(Physics);
with(Vectors);

Given

Ket(i) = alpha*Ket(u) + beta*Ket(d);
Ket(o) = gamma*Ket(u) + delta*Ket(d);
and using

<o|u><u|o> =1/(2)
<o|d><d|o> =1/(2)

 <i|d><d|i> =1/(2);
 <i|u><i|o> =1/(2);

Prove that
                     "alpha^*alpha = 1/2"

and the same for the rest of the unknowns

If you could help me start using them because later I will have a lot to check.

Thank you in advance for your help.

Mario

I have just started to use Maple workbook (*.maple). In the workbook, there are 4 worksheets: "main.mw","calc1.mw","calc2.mw","calc3.mw". In "main.mw", I plot variables saved from "calc?.mw". This works. However, when I make changes in one of the worksheet "calc?.mw" and get the new expressions for the variables, they are not updated in "main.mw". I deleted the variables being changed but "main.mw" still run and show the old expressions of these variables.

How do I refresh so that "main.mw" will show the updated variables from "calc?.mw"?

Thanks.

Dear all

I get error when solving Riccati equation. I want to get six different solution. 

ricatti_equation.mw

thank you for your help

I'm currently working on applying a specific method to solve a nonlinear equation. However, I've encountered a recurring issue: during the process, I often cannot determine certain parameters, which forces me to abandon the solution or switch to a different method. This has happened multiple times and is disrupting my goal of applying all intended methods consistently to a single equation.

In particular, I’m struggling to identify the correct parameters for U(ξ), which are essential for the solution. This challenge is not limited to one method I’ve faced similar problems in previous attempts, and I’m unsure why these parameters cannot be derived in some cases.

My question is: How can I manage this issue effectively? Is there a reliable way to predict or determine whether the necessary parameters will emerge correctly before fully applying a method?

I would greatly appreciate any insights or strategies you could share to help me handle this problem more systematically.

Thank you in advance for your support.

runing.mw

Some menu fonts have become smaller under Windows 10 for some reason.
There where no changes of the system settings nor system updates. A system restart did not restore to normal font size. This also on Maple 2024 and lower.

Any ideas what could have caused this and how to restore to normal?

That's from annother Windows 10 system.

 

How to solve these pde equations in maple to get the similar type graphs.

Ode equations we can solve directly but these equations are pde .

in the article they have solved the governing equations by series solution? 

can we solve these equations in maple also by series solution or any other method is there to solve these equations

I have used plot3d in Maple to generate a 3D plot, but I’m not sure how to export it in high resolution. I tried right-clicking to export the image directly, but the SVG output appeared garbled, and the JPEG version was too low in quality. I also attempted to export the plot using commands, but the resulting image still lacked sufficient resolution. I would like to ask how I can properly export a high-quality 3D figure from Maple.

Commands I have tried:

plotsetup(jpeg, plotoutput = "C:/Users/gfy/Desktop/data5151.jpg", plotoptions = `dpi=1200`);
print(ddd);
plotsetup(default);

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