Maple Questions and Posts

These are Posts and Questions associated with the product, Maple

I asked Maple AI what a glyph is. Then I prompted this

A kernel lost message was returned and the AI pannel became irresponsive.

Maple is still running well in exsisting and new tabs. 

Can the AI service be restarted from the user interface?

(Is that crash reproducible?)

For exercises involving Pick's Theorem, I need grid points within a Cartesian coordinate system. How can "all" grid points - at least within the first quadrant - be generated without the tedious manual entry of integer coordinates? Is it possible to draw grid polygons as closed polylines simply by clicking on the grid points? (BTW: At the moment, this works well in the good old "Cabri.")
My search within the "Help" section (using terms such as plot, grid, mesh, lattice, etc.) proved unsuccessful.

The HTML characters in the attached document cause problems here on MaplePrimes. You have to open the worksheet

Download HTML_characters_in_math_mode.mw

05-2-2.mws

Can you help me with this code?

restart: with(VectorCalculus):

assume(g>0,Omega>0,V0>0,theta>0,alpha>0,alpha<=Pi/2):

alias(omega=w,Omega=W,alpha=a):

w:=<-W*cos(a),0,W*sin(a)>;

Vector(3, {(1) = -W*cos(a), (2) = 0, (3) = W*sin(a)})

(1)

r:=<x(t),y(t),z(t)>; v:=diff(r,t);

Vector(3, {(1) = x(t), (2) = y(t), (3) = z(t)})

Vector(3, {(1) = diff(x(t), t), (2) = diff(y(t), t), (3) = diff(z(t), t)})

(2)

F[gravity]:=<0,0,-g>;

Vector(3, {(1) = 0, (2) = 0, (3) = -g})

(3)

F[Coriolis]:=-2*w &x v;

Vector(3, {(1) = 2*W*sin(a)*(diff(y(t), t)), (2) = -2*W*cos(a)*(diff(z(t), t))-2*W*sin(a)*(diff(x(t), t)), (3) = 2*W*cos(a)*(diff(y(t), t))})

(4)

F[centrifugal]:=-w &x (w &x r);

Vector(3, {(1) = W*sin(a)*(W*cos(a)*z(t)+W*sin(a)*x(t)), (2) = W^2*cos(a)^2*y(t)+W^2*sin(a)^2*y(t), (3) = W*cos(a)*(W*cos(a)*z(t)+W*sin(a)*x(t))})

(5)

F[resultant]:=F[gravity]+F[Coriolis]+F[centrifugal];

Vector(3, {(1) = 2*W*sin(a)*(diff(y(t), t))+W*sin(a)*(W*cos(a)*z(t)+W*sin(a)*x(t)), (2) = -2*W*cos(a)*(diff(z(t), t))-2*W*sin(a)*(diff(x(t), t))+W^2*cos(a)^2*y(t)+W^2*sin(a)^2*y(t), (3) = -g+2*W*cos(a)*(diff(y(t), t))+W*cos(a)*(W*cos(a)*z(t)+W*sin(a)*x(t))})

(6)

eq:=(u,i)->simplify(diff(u(t),t,t)=F[resultant][i]):

xeq:=eq(x,1); yeq:=eq(y,2); zeq:=eq(z,3);

xeq := diff(x(t), `$`(t, 2)) = Omega*sin(alpha)*(Omega*sin(alpha)*x(t)+Omega*cos(alpha)*z(t)+2*(diff(y(t), t)))

yeq := diff(y(t), `$`(t, 2)) = Omega*(y(t)*Omega-2*(diff(z(t), t))*cos(alpha)-2*(diff(x(t), t))*sin(alpha))

zeq := diff(z(t), `$`(t, 2)) = sin(alpha)*cos(alpha)*x(t)*Omega^2+cos(alpha)^2*z(t)*Omega^2+2*Omega*cos(alpha)*(diff(y(t), t))-g

(7)

ic:=x(0)=0,y(0)=0,z(0)=0,D(x)(0)=0,D(y)(0)=V0*cos(theta),D(z)(0)=V0*sin(theta);

ic := x(0) = 0, y(0) = 0, z(0) = 0, (D(x))(0) = 0, (D(y))(0) = V0*cos(theta), (D(z))(0) = V0*sin(theta)

(8)

sol:=dsolve({xeq,yeq,zeq,ic},{x(t),y(t),z(t)},method=laplace):

assign(sol):

f:=u->simplify(expand(u(t))): X:=f(x); Y:=f(y); Z:=f(z);

X := -(1/4)*(Omega^4*V0*sin(theta)*cos(alpha)*(sum(exp(_alpha1*t)/((Omega^2+_alpha1^2)*_alpha1), _alpha1 = RootOf(Omega^2+_Z^2)))+cos(alpha)*g*(sum(exp(_alpha1*t)*_alpha1^2/(Omega^2+_alpha1^2), _alpha1 = RootOf(Omega^2+_Z^2)))-sin(theta)*cos(alpha)*V0*(sum(exp(_alpha1*t)*_alpha1/(Omega^2+_alpha1^2), _alpha1 = RootOf(Omega^2+_Z^2)))*Omega^2+(-2*Omega^3*cos(theta)*V0+3*cos(alpha)*Omega^2*g)*(sum(exp(_alpha1*t)/(Omega^2+_alpha1^2), _alpha1 = RootOf(Omega^2+_Z^2)))+4*(Omega^2*t*V0*sin(theta)-(1/2)*Omega^2*t^2*g-g)*cos(alpha))*sin(alpha)/Omega^2

Y := (1/4)*(-V0*cos(theta)*Omega^2+2*cos(alpha)*Omega*g)*(sum(exp(_alpha1*t)/((Omega^2+_alpha1^2)*_alpha1), _alpha1 = RootOf(Omega^2+_Z^2)))-(1/2)*sin(theta)*cos(alpha)*V0*Omega*(sum(exp(_alpha1*t)/(Omega^2+_alpha1^2), _alpha1 = RootOf(Omega^2+_Z^2)))+(1/4)*V0*cos(theta)*(sum(exp(_alpha1*t)*_alpha1/(Omega^2+_alpha1^2), _alpha1 = RootOf(Omega^2+_Z^2)))

Z := (1/4)*(-Omega^4*cos(alpha)^2*V0*sin(theta)*(sum(exp(_alpha1*t)/((Omega^2+_alpha1^2)*_alpha1), _alpha1 = RootOf(Omega^2+_Z^2)))-cos(alpha)^2*g*(sum(exp(_alpha1*t)*_alpha1^2/(Omega^2+_alpha1^2), _alpha1 = RootOf(Omega^2+_Z^2)))+cos(alpha)^2*sin(theta)*V0*(sum(exp(_alpha1*t)*_alpha1/(Omega^2+_alpha1^2), _alpha1 = RootOf(Omega^2+_Z^2)))*Omega^2+(2*Omega^3*cos(alpha)*cos(theta)*V0-3*Omega^2*g*cos(alpha)^2)*(sum(exp(_alpha1*t)/(Omega^2+_alpha1^2), _alpha1 = RootOf(Omega^2+_Z^2)))+(-4*Omega^2*t*V0*sin(theta)+2*Omega^2*t^2*g+4*g)*cos(alpha)^2+4*Omega^2*t*V0*sin(theta)-2*Omega^2*t^2*g)/Omega^2

(9)

P:=(u,n)->convert(taylor(u,W=0,n),polynom):

Xexp:=P(X,4); Yexp:=P(Y,4); Zexp:=P(Z,4);  

Error, (in series/sum) unable to compute series

Error, (in series/sum) unable to compute series

Error, (in series/sum) unable to compute series

 

tt:=solve(Zexp=0,t);

tt :=

(10)

 T1:=P(tt[2],1); d[x]:=eval(Xexp,t=T1);  

Error, invalid subscript selector

d[x] := Xexp

 

T2:=P(tt[2],2); d[y]:=P(eval(Yexp,t=T2),2);

Error, invalid subscript selector

d[y] := Yexp

 

d[y]:=collect(d[y],[cos(a),1/g^2,V0^3,W]);

d[y] := Yexp

(11)

parameters:={a=Pi/4,theta=Pi/3,V0=500,W=7.27*10^(-5),g=9.8}:

d[x]:=eval(d[x],evalf(parameters));

d[x] := Xexp

(12)

d[y]:=eval(d[y],evalf(parameters));

d[y] := Yexp

(13)
 

 

Download 05-2-2.mws

Can anyone share additional information about the Maple conference to be held in 2026? I want to submit a talk and then submit a paper to the Maple Transactions journal based on the same.

Can anyone help me?

restart: with(plots):   

h:=0.01: n:=6000: Digits:=18:

t[0]:=0: x[0]:=0.2: y[0]:=0.1: epsilon:=20:

F:=(x,y)->epsilon*(1-x^2)*y-x:

begin:=time():

for k from 0 to n do

t[k+1]:=t[k]+h;

x[k+1]:=x[k]+h*y[k];

y[k+1]:=y[k]+h*F(x[k],y[k]);

pt[k]:=[t[k],x[k],y[k]]:

end do:

cpu_time:=time()-begin;

pointplot3d([seq(pt[j],j=0..n)],axes=normal,symbol=cross,symbolsize=8,color=red,labels=["t","x","y"],orientation=[-90,0]);

sys:=diff(X(t),t)=Y(t),diff(Y(t),t)=F(X(t),Y(t));

vars:={X(t),Y(t)}: ic:=X(0)=0.2,Y(0)=0.1:

sol:=dsolve({sys,ic},vars,numeric,stepsize=h,method=classical[foreuler],output=listprocedure):

odeplot(sol,[t,X(t)],0..h*n,axes=normal,style=line,numpoints=n,labels=["t","x"]);

XX:=eval(X(t),sol): x1:=XX(1);  pt[100];

 

 

Download 09-1-1.mws

I am trying to plot a function where one of the variables is determind via a procedure that uses fsolve and depends on some parameters. When I go to try and make a plot using Explore to vary the parameters I get the following error:
"in fsolve  S  is in the equation, and is not solved for"
My worksheet is seen below:

restart;

 

T := 2^(2/3)*(16*CC(S,mu,Z,Pr)^2*Pi^2 + 2*Pi^2*Z^2 + 16*Pi*S*CC(S,mu,Z,Pr) + 3*S^2)*Pr^(1/3)/(4*(4*CC(S,mu,Z,Pr)*Pi + S)^(2/3)*(2*Pi^2*Z^2 + 4*Pi*S*CC(S,mu,Z,Pr) + S^2)^(2/3)*CC(S,mu,Z,Pr)^(1/3)*Pi^(2/3))

(1/4)*2^(2/3)*(16*CC(S, mu, Z, Pr)^2*Pi^2+2*Pi^2*Z^2+16*Pi*S*CC(S, mu, Z, Pr)+3*S^2)*Pr^(1/3)/((4*CC(S, mu, Z, Pr)*Pi+S)^(2/3)*(2*Pi^2*Z^2+4*Pi*S*CC(S, mu, Z, Pr)+S^2)^(2/3)*CC(S, mu, Z, Pr)^(1/3)*Pi^(2/3))

(1)

 

mu = 2^(2/3)*S*(16*C^2*Pi^2 - 2*Pi^2*Z^2 - S^2)*Pr^(1/3)/(4*(4*C*Pi + S)^(2/3)*(2*Pi^2*Z^2 + 4*C*Pi*S + S^2)^(2/3)*C^(4/3)*Pi^(2/3))

mu = (1/4)*2^(2/3)*S*(16*C^2*Pi^2-2*Pi^2*Z^2-S^2)*Pr^(1/3)/((4*C*Pi+S)^(2/3)*(2*Pi^2*Z^2+4*C*Pi*S+S^2)^(2/3)*C^(4/3)*Pi^(2/3))

(2)

CC:=proc(S,mu,Z,Pr)
fsolve((2),C,C=0.01..100)
end proc;

proc (S, mu, Z, Pr) fsolve(mu = (1/4)*2^(2/3)*S*(16*C^2*Pi^2-2*Pi^2*Z^2-S^2)*Pr^(1/3)/((4*C*Pi+S)^(2/3)*(2*Pi^2*Z^2+4*C*Pi*S+S^2)^(2/3)*C^(4/3)*Pi^(2/3)), C, C = 0.1e-1 .. 100) end proc

(3)

CC(1,0,0.5,0.2)

.1938622552

(4)

Explore(plot(T,0..15),parameters=[[mu=0 .. 1,minorticks=0.25],[Z=0..0.5,minorticks=0.1],[Pr=0..1,minorticks=0.25]])


When I try to move the sliders on my parameters this is where I get the error. I want to plot over S, but I can only get CC once I have all the other values including S. I assume it has something to do with the fact that my plotting variable is in the procedure?

Any help would be greatly appreciated, thanks. 

Download Explore_Plot_Problem.mw

A note on what I've been working on for the past while. Some of you may have seen the announcement on LinkedIn yesterday; this is for the home audience.

The question I've been chasing is the one that's underneath the Physics package, the dsolve / pdsolve formal methods and heuristics, the advanced Mathematical Functions and FunctionAdvisor, and most of what I've written for Maple over the years. How can mathematicians and physicists speed up significantly their work using Computer Algebra Systems (CAS) and at the same time trust the result a computer hands back? The new chapter is what happens when AI sits between the human and the CAS, and the answer to that, in my view, turns out to be a much harder problem than the AI hype suggests.

Why? Because AI is increasingly the driver of computational mathematics in research, engineering, and education. The Mathematica and Maple code those AIs increasingly depend on is the same code I spent decades building. And the unsolved problem isn't whether AI can do mathematics. It can. The problem is that an incorrect AI result arrives with the same confidence as a correct one.

On 100 challenging problems of undergraduate mathematics we tested, six independent state-of-the-art AIs returned mathematically equivalent answers on only 21% of them, and even within a single AI, repeated runs disagreed with themselves on 3% to 57% of the problems (details). The gap this validation crosses, between probabilistic inference and certified computation, is epistemological, not technological. It won't close with more training data. It needs validation across multiple AIs and multiple CAS, with no single engine having the final word.

ExaktAI addresses that gap. It guides AI through mathematical computation, validates each step against Maple and Mathematica, and delivers an executable document where you can audit, reproduce, and edit the result. The goal: to have AI-mathematics that is validated, where the human in the loop is non-negotiable.

ExaktAI is now well developed (TRL 6: System prototype demonstration in a simulated environment, on the ISED / Innovative Solutions Canada TRL scale). At the end an image. A Beta is scheduled for late summer / fall 2026; details at exaktai.ai.

In summary: ExaktAI is my present, and if you work on AI for mathematics and computer algebra, or the validation problem for AI, I'd love to hear your perspective.



Edgardo S. Cheb-Terrab
ExaktAI
Research Fellow Emeritus at Maplesoft.

Para_1.mw.  please help to correct this error.

It seems that in Maple 2025+ on Windows 11, the SMTLIB package is not working. For example:

SMTLIB:-Satisfiable( {x^2+y^2+z^2<1, x*y*z>1} ) assuming real;

complains about error loading external library mplsmtlib.dll.

Is there an explanation, or a workaround?

I have usually used $include within a module when building packages, where the included file has all the procedures.

What I would like to have is to have the module itself in an external file which would be included.

read "this:///lib/NODEFunctions";
savelib('NODEFunctions', "this://");

$include "NODEXML.mm"
# read "this:///lib/NODEXML";
savelib('NODEXML', "this://");

The first 2 lines show the usual way I do it, where NODEFunctions is a module within the Maple file. In that file there is an $include for the proc() parts only.

The second attempt unfortunatly throws a "Error, unexpected string" error. I have tried both with and with a ; at the end of the $include line.

"NODEXML.mm" is a file with the complete module definition with proc().

I am currently working with inert integrals and summations in Maple, and I encountered a difficulty when manipulating symbolic expressions. I would appreciate any suggestions or recommended approaches.

Specifically, I would like to achieve the following:

  1. Convert an inert expression in the form of a “summation inside an integral” into an equivalent “sum of integrals” form.
    In other words, transform expressions of the type:
    Int(i=1∑n​fi​(x,t),x=a..b)

    into
    ∑​Int(fi​(x,t),x=a..b)

    while preserving the inert (Int) representation rather than evaluating the integral directly.

    I have tried commands such as value, expand, convert, and related manipulation methods, but I have not yet found a suitable solution.
     

  2. The integrand contains two variables, where xxx is the integration variable.
    How can terms that are independent of xxx be automatically extracted outside the inert integral? For example, if the integrand contains coefficients or functions depending only on ttt, I would like Maple to rewrite
    Int(g(t)f(x),x=a..b)

    as g(t)Int(f(x),x=a..b)

    without forcing evaluation of the inert integral.

    Any recommendations, built-in commands, or pattern-based approaches would be greatly appreciated.
    question525.mw

Hi,

I need to run the following procedure a couple of million times. Although it works, Maple sometimes chokes for no apparent reason (if there is a reason, please let me know). I was wondering whether an expert could help me tweak the procedure (or possibly rewrite it) to achieve the best possible performance. I am planning to use Grid:-Map or, if possible, Threads:-Map.

 

generateNonlinearModelsPlus := proc(model::list,fullmodel::list,vars::list:=[x,y,z])
description "This function generates a list of all models with one more monomial from the full model":
local tab::table(),n:=nops(model),i,j,k:=1,ans,terms,aaa,allmoncoefThreads:
# local procedure
allmoncoefThreads := proc(f::list,vars::list)
description "This function finds the monomials multipled by their coefficients for each expression (equation) of a list.":
local n:=numelems(f),i,mon:=[seq](0,i=1..n),M,cc:=[seq](0,i=1..n),ans:
for i from 1 to n do
  cc[i]:=[coeffs](expand(f[i]),vars, 'M'):
  mon[i]:=[M]:
end do:
ans:=[seq](zip((ww,vv)->ww*vv,cc[i],mon[i]),i=1..n):
return(ans)
end proc:
# main part
ans:=zip((w,v)->expand(simplify(v-w)),model,fullmodel): # Find the monomials that are not in model
terms:=allmoncoefThreads(ans,vars): # Separate the monomials
#
for i from 1 to n do
   aaa:=model:
   for j from 1 to nops(terms[i]) do
       aaa[i]:=model[i]+terms[i,j]:
       tab[k]:=aaa:
       k:=k+1:
   end do:
end do:
tab:=convert(tab,list):
return(tab):
end proc:

Here is an example of how I run it: 

model:=[y*alpha[1, 2], z*alpha[2, 3], x^3*alpha[3, 10] + x*alpha[3, 1] + alpha[3, 0]]:

fullmodel:=[x^3*alpha[1, 10] + x^2*y*alpha[1, 11] + x^2*z*alpha[1, 12] + x*y^2*alpha[1, 13] + x*y*z*alpha[1, 14] + x*z^2*alpha[1, 15] + y^3*alpha[1, 16] + y^2*z*alpha[1, 17] + y*z^2*alpha[1, 18] + z^3*alpha[1, 19] + x^2*alpha[1, 4] + x*y*alpha[1, 5] + x*z*alpha[1, 6] + y^2*alpha[1, 7] + y*z*alpha[1, 8] + z^2*alpha[1, 9] + x*alpha[1, 1] + y*alpha[1, 2] + z*alpha[1, 3] + alpha[1, 0], x^3*alpha[2, 10] + x^2*y*alpha[2, 11] + x^2*z*alpha[2, 12] + x*y^2*alpha[2, 13] + x*y*z*alpha[2, 14] + x*z^2*alpha[2, 15] + y^3*alpha[2, 16] + y^2*z*alpha[2, 17] + y*z^2*alpha[2, 18] + z^3*alpha[2, 19] + x^2*alpha[2, 4] + x*y*alpha[2, 5] + x*z*alpha[2, 6] + y^2*alpha[2, 7] + y*z*alpha[2, 8] + z^2*alpha[2, 9] + x*alpha[2, 1] + y*alpha[2, 2] + z*alpha[2, 3] + alpha[2, 0], x^3*alpha[3, 10] + x^2*y*alpha[3, 11] + x^2*z*alpha[3, 12] + x*y^2*alpha[3, 13] + x*y*z*alpha[3, 14] + x*z^2*alpha[3, 15] + y^3*alpha[3, 16] + y^2*z*alpha[3, 17] + y*z^2*alpha[3, 18] + z^3*alpha[3, 19] + x^2*alpha[3, 4] + x*y*alpha[3, 5] + x*z*alpha[3, 6] + y^2*alpha[3, 7] + y*z*alpha[3, 8] + z^2*alpha[3, 9] + x*alpha[3, 1] + y*alpha[3, 2] + z*alpha[3, 3] + alpha[3, 0]]:

vars:=[x,y,z]:

ans:=generateNonlinearModelsPlus(model,fullmodel,vars)

Many thanks.

For quite some time, I have wanted to solve the system attached in "test" using Maple. The smallest solution in natural numbers x, y, and z test.mw

restart

kernelopts(version)

`Maple 2026.0, X86 64 WINDOWS, Apr 28 2026, Build ID 2011354`

(1)

interface(version)

`Standard Worksheet Interface, Maple 2026.1, Windows 11, April 28 2026 Build ID 2011354`

(2)

with(NumberTheory)

isolve({x*y*z = w^2, x+y+z = u^2, x*y+x*z+y*z = v^2})

{u = _Z1, v = 0, w = 0, x = _Z1^2, y = 0, z = 0}

(3)

"(->)"

{u = _Z1, v = 0, w = 0, x = _Z1^2, y = 0, z = 0}

(4)

``

Download test.mw

is known, and all these numbers are less than 4 × 10¹². Is this possible in Maple?

(x=1633780814400; y=252782198228; z=3474741058973)

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