[go: up one dir, main page]

Unanswered Questions

This page lists MaplePrimes questions that have not yet received an answer

Dear all,

is there a versioning concept similiar to Eclipse ?

Hi everyone, I am looking for help, regarding the solution of nonlinear ordinary differential equations numerically. I have explained my problem in my Maple worksheet. Could anyone please help me in this regard?

Help.mw

The procedure is to plot text points and lines. so it has three procedures in it. the 1st and 2nd work to plot text and pooints. But the 2nd is blocking access to the 3rd to plot lines. If I swap the 2nd and 3rd the problem reverse. I use typ and tyl to try to focre points or lines. What other check could if use  here?


 

restart

#with(LinearAlgebra)


RTPlot:=overload([

#1 plots text Matrix(1,3) are projective points. Matrix(3,1) are projective lines

proc(p1::{list,Vector[row],Matrix(1,3)},p2::{list,Vector[row],Vector[column],Matrix(1,3)},{Txt::{list,string}:="Zebra"})
option overload;
  description "plots text";
uses plots, plottools, LinearAlgebra;
local ang,pc1, pc2, td:=2,txt, f, plt;
if p1::{list,Vector[row]} and p2::{list,Vector[row]} then
   pc1:=p1;
    if numelems(p2)=2 then
      ang:=evalf(VectorAngle(p2-~p1,[1,0]));
     elif numelems(p2)=3 then
      td:=3;
      ang:=evalf(VectorAngle(p2-~p1,[1,0,0]));
     end if;
elif p1::list and p2::{Vector[column] }then
  pc1:=p1;
   if numelems(p2)=2 then
      ang:=evalf(VectorAngle(p2,<1,0>));
   elif numelems(p2)=3 then
      td:=3;
      #ang:=evalf(VectorAngle(p2,<1,0,0>));
  end if;
elif p1::'Matrix'(1,3) and p2::'Matrix'(1,3) then
  if p2[1,3]=0 then
     pc1:=LPproj(p1);
     ang:=evalf(VectorAngle(p2,<1,0,0>));
   else
     pc2,pc1:=LPproj~([p2,p1],false)[];  
     ang:=evalf(VectorAngle(pc2-pc1,[1,0]));
  end if;
end if;
if Txt::string then
 txt:=Txt;
else
 txt:=Txt[];
end if;
if td=2 then
    display(point(pc1),textplot([op(pc1),txt,'rotation'=ang]));
 else
    display(point(pc1),textplot3d([op(pc1),txt]));
end if;
end proc,

#2 plots points. Matrix(1,3) are projective points


proc(p1::{list,vector[row],Matrix(1,3)},{dta:=[]},{typ::string:="y"})
option overload;
description "plots points";
uses plots, plottools, LinearAlgebra;
local pt,pl1,n,i  ;
if typ="pnt" then
    if p1::list and p1[1]::{list,vector[row],Matrix(1,3)} then
      n:=nops(p1);
      pl1:=p1;
     else
      n:=1;
      pl1:=[p1];
    end if;
  pt:=[];#print(pt,n);print(pl1);
    for i to n do
      if pl1[i]::list then
        pt:=[pt[],pl1[i]];
       elif pl1[i]::'Vector'[row] then
        #print(pl1[i]);
        pt:=[pt[],convert(pl1[i],list)];
       elif pl1[i]::'Matrix'(1,3) then
        pt:=[pt[],[pl1[i][1,1]/pl1[i][1,3],pl1[i][1,2]/pl1[i][1,3]] ];
      end if;
    end do;
  plots:-display(plottools:-point(pt,dta[]));
end if;
end proc,

#3 plots lines

proc(l1::{list,Vector[column],Matrix(3,1)},{tyl::string:="x"})
option overload;
description "plots lines";
uses plots, plottools, LinearAlgebra;
local xmin:=-3, xmax:=3, ymin:=-3, ymax:=3 ;
print("yyy");
if tyl="lnn" then
print("xxxxx");
  #if  l1::list and l1[1]::list and l1[2]::list then
    #plt1:=plottools:-line(l1[],color=black, thickness=4);
  #end if;
  plots:-display(plottools:-line(l1[],color=black, thickness=4));
end if;
end proc

]):

 

 

#maplemint(RTPlot)

RTPlot([1,2],<5|-6>,Txt=['typeset'("Local Minima ", [-Pi/2, -1]),colour=blue,'font' = ["times", "roman", 20],align=right]);

 

RTPlot([1,2,1],[5,6,11],Txt=['typeset'("Local Minima ", [-Pi/2, -1]),colour=blue,'font' = ["times", "roman", 20],align=right]);

 

RTPlot([1,2],<-5|-6>,Txt=['typeset'("Local Minima ", [-Pi/2, -1]),colour=blue,'font' = ["times", "roman", 20],align=right]);

 

#RTPlot([1,2,4],<5,6,1>,Txt=['typeset'("Local Minima ", [-Pi/2, -1]),colour=grey,'font' = ["arial",  16],align=right]);

RTPlot(<<-1|-1|2>>,<<1|-1|1>>,Txt=["Big word",colour=blue,'font' = ["times", "roman", 20],align=below])

 

RTPlot([[1,2],<3|-1>,[4,5],<<4|1|7>>],dta=[color=[red,green,blue,black],symbol=solidcircle,symbolsize=12],typ="pnt")

 

RTPlot([[1,2,1],<3|-1|4>,[4,5,6],[4,1,3],<7|0|2>],dta=[color=[red,green,blue,black,orange],symbol=solidcircle,symbolsize=18],typ="pnt")

 

RTPlot([[1,2],[3,-1]],tyl="lnn")

l1:=[[1,2],[3,-1]]

[[1, 2], [3, -1]]

(1)

RTPlot(l1,tyl="lnn")

#plots:-display(plottools:-line(l1[],color=black, thickness=4));

 


 

Download Q_2024-08-29_Plot_in_RT.mw

In the Standard interface, the length of an expression that display in the worksheet can be limited using the Options dialog: Options Dialog - Precision Tab - Maple Help. However, I would like to know if I can change this option programmatically. The closest interface variables are elisiontermsbefore, elisiontermsafter and termelisionthreshold, but as the aforementioned help page states, they control the “term elision” and are not the same as “expression length limit”. So, is this possible? 

Maple help pages keep getting worst with each release.

I want all input to be displayed using Maple 1D notation, so I can copy the example to my worksheet since I only use worksheet and not document (2D) mode.

So even though the first thing I do when I open help it to turn off the 

                     view->Display examples with 2D

So it is no longer checked, I still see many pages using 2D math for input. 

Here is one example ?D  page

If I copy one such input to my worksheet now it looks like this

eveything in 2D becomes ?? when I copy it.

So one can only look but not copy?

Is there any other option to make sure, really make sure, all examples have 1D as input?

The problem is that it is all not consistent. Some examples have a mix of 2D and 1D as the above page. Some are in 2D and some are in 1D.

And this is all on the same help page!

Does no one inside Maplesoft even look at their own help pages?
 

In calculation limit, signum and infinity appear!!!

Is this correct?

 

lim.mw

Dear all
I have an equation, I would like to dermine the exact solution, but maple return an error 

exact_solution.mw

Thank you

Maple solves this first order ode correctly and solution verifies OK. The solution is explicit and has RootOf. I asked it to solve it using dAlembert method to compare with my own solution using dAlembert.

Next I called dsolve on same ode and IC but asked for implicit solution now instead, then called solve on the implicit solution to see if it will give same solution y(x) as before (with RootOf). But instead solve gives this internal error 

               Error, (in evala) reducible RootOf detected.  

Next called PDEtools:-Solve to see if it will give same error. It did not give error. But it also could not solve for y(x) either.

Any one has any idea why this error is generated by solve? Is this expected or not?

I was expecting same result as first call to dsolve which returned explicit solution. And why is PDEtools:-Solve do not generate same error? It must have run through different code path.

May be some one have some insight on this.

interface(version);

`Standard Worksheet Interface, Maple 2024.1, Windows 10, June 25 2024 Build ID 1835466`

Physics:-Version();

`The "Physics Updates" version in the MapleCloud is 1792 and is the same as the version installed in this computer, created 2024, August 22, 12:6 hours Pacific Time.`

libname;

"C:\Users\Owner\maple\toolbox\2024\Physics Updates\lib", "C:\Program Files\Maple 2024\lib"

ode:=(2*x+y(x))+(4*x-2*y(x)+1)*diff(y(x),x)=0;
IC:=y(1/2)=0;

2*x+y(x)+(4*x-2*y(x)+1)*(diff(y(x), x)) = 0

y(1/2) = 0

maple_sol:=dsolve([ode,IC],[dAlembert]);

y(x) = RootOf((8*I)*exp((3/41)*41^(1/2)*arctanh((1/41)*(-28*x+6*_Z-5)*41^(1/2)/(-4*x+2*_Z-1)))*9^(1/2)*x+48*(-(16*_Z^2-40*_Z*x-16*x^2-13*_Z+6*x+2)/(-4*x+2*_Z-1)^2)^(1/2)*_Z*x*exp((3/41)*41^(1/2)*arctanh((19/123)*41^(1/2)))-96*x^2*(-(16*_Z^2-40*_Z*x-16*x^2-13*_Z+6*x+2)/(-4*x+2*_Z-1)^2)^(1/2)*exp((3/41)*41^(1/2)*arctanh((19/123)*41^(1/2)))+I*exp((3/41)*41^(1/2)*arctanh((1/41)*(-28*x+6*_Z-5)*41^(1/2)/(-4*x+2*_Z-1)))*9^(1/2)+6*(-(16*_Z^2-40*_Z*x-16*x^2-13*_Z+6*x+2)/(-4*x+2*_Z-1)^2)^(1/2)*_Z*exp((3/41)*41^(1/2)*arctanh((19/123)*41^(1/2)))-36*x*(-(16*_Z^2-40*_Z*x-16*x^2-13*_Z+6*x+2)/(-4*x+2*_Z-1)^2)^(1/2)*exp((3/41)*41^(1/2)*arctanh((19/123)*41^(1/2)))-3*(-(16*_Z^2-40*_Z*x-16*x^2-13*_Z+6*x+2)/(-4*x+2*_Z-1)^2)^(1/2)*exp((3/41)*41^(1/2)*arctanh((19/123)*41^(1/2))))

odetest(maple_sol,[ode,IC])

[0, 0]

maple_sol:=dsolve([ode,IC],[dAlembert],implicit);

-((1/64)*I)*(64*x+8)*exp((3/41)*41^(1/2)*arctanh((1/41)*(28*x-6*y(x)+5)*41^(1/2)/(4*x-2*y(x)+1)))*exp(-(3/41)*41^(1/2)*arctanh((19/123)*41^(1/2)))/(((16*x^2+40*x*y(x)-16*y(x)^2-6*x+13*y(x)-2)/(4*x-2*y(x)+1)^2)^(1/2)*(4*x-2*y(x)+1))+x+(1/8)*(4*((16*x^2+40*x*y(x)-16*y(x)^2-6*x+13*y(x)-2)/(4*x-2*y(x)+1)^2)^(1/2)*exp(-(3/41)*41^(1/2)*arctanh((1/41)*(28*x-6*y(x)+5)*41^(1/2)/(4*x-2*y(x)+1)))*x-2*((16*x^2+40*x*y(x)-16*y(x)^2-6*x+13*y(x)-2)/(4*x-2*y(x)+1)^2)^(1/2)*exp(-(3/41)*41^(1/2)*arctanh((1/41)*(28*x-6*y(x)+5)*41^(1/2)/(4*x-2*y(x)+1)))*y(x)+((16*x^2+40*x*y(x)-16*y(x)^2-6*x+13*y(x)-2)/(4*x-2*y(x)+1)^2)^(1/2)*exp(-(3/41)*41^(1/2)*arctanh((1/41)*(28*x-6*y(x)+5)*41^(1/2)/(4*x-2*y(x)+1))))*exp((3/41)*41^(1/2)*arctanh((1/41)*(28*x-6*y(x)+5)*41^(1/2)/(4*x-2*y(x)+1)))/(((16*x^2+40*x*y(x)-16*y(x)^2-6*x+13*y(x)-2)/(4*x-2*y(x)+1)^2)^(1/2)*(4*x-2*y(x)+1)) = 0

#solve gives error
sol:=solve(maple_sol,y(x));

Error, (in evala) reducible RootOf detected.  Substitutions are {RootOf(6*RootOf(_Z^2-41,index = 1)*_Z+41*_Z^2+5,label = exptmp) = -5/41*RootOf(_Z^2-41,index = 1), RootOf(6*RootOf(_Z^2-41,index = 1)*_Z+41*_Z^2+5,label = exptmp) = -1/41*RootOf(_Z^2-41,index = 1)}

#PDEtools:-Solve  gives no error but does not solve it
sol:=PDEtools:-Solve(maple_sol,y(x));

 


 

Download reducible_rootof_detected_august_24_2024.mw

I am trying to understand under which conditions submenus disappear.

Now I have seen that the context panel is empty when submenues disappear.

Has anybody noticed the same and are there other instances when the context panel is emtpy?

Both effects could have the same rootcause.

Here is an example:
A -> no submenu

B -> Empty context panel

C -> Menu appears inside workspace (first time I see that)

Hi everyone,

I’m encountering an issue with Maple 2024 on my MacBook Air M1 (2020) running macOS Sonoma 14.6.1. Every time I try to log in to Maple Cloud from within the application, the entire program freezes and becomes unresponsive. I’ve tried restarting the application and my MacBook, but the problem persists.

Is anyone else experiencing similar issues with Maple 2024 on an M1 Mac running macOS Sonoma? If so, have you found any solutions or workarounds? I’ve checked for updates and even reinstalled the software, but the problem still exists.

Any help or advice would be greatly appreciated!

Thanks in advance!

This problem began about 3 nights ago.

When I load the subpackage UHG to RationalTrigonometry no warning.

When I rerun the worksheet warnings appear. If I put in arestart and reload the packages no warning. The problem only occurs with the sub packageUHG. The RationalTrigonometry package also has a few aliases.

Screen shot of one rerun  then added restart.

This is first order ode with IC. Solving it by Maple, then odetest verifies the Maple solution against the ode and the IC.

I solved it myself and got solution, which Maple says is same as its solution but my solution is written little different. Using simplify Maple says both solutions are same.

But I am not able to get zero when using odetest on my solution. No matter what I tried. I tried the tricks I know from before and from earlier questions/answers, but none of them worked on this one. So I have no idea what to try now.

It is clearly has something to do about how it is written. Even though it is  mathematically equivalent  to Maple's.

Would someone be able to find out why that is, and what trick is needed to make odetest verify my solution?

Since Maple says they are same, then odetest should give zero for my solution also.  odetest verifies my solution is correct only against the IC, but not against the ode itself. I did not show the output of odetest below since they are very very large.

Attached worksheet.

restart;

interface(version);

`Standard Worksheet Interface, Maple 2024.1, Windows 10, June 25 2024 Build ID 1835466`

Physics:-Version();

`The "Physics Updates" version in the MapleCloud is 1792 and is the same as the version installed in this computer, created 2024, August 22, 12:6 hours Pacific Time.`

libname;

"C:\Users\Owner\maple\toolbox\2024\Physics Updates\lib", "C:\Program Files\Maple 2024\lib"

restart;

ode:=3*x - y(x) + 1 + (x - 3*y(x) - 5)*diff(y(x), x) = 0;
IC:=y(0) = 0;

3*x-y(x)+1+(x-3*y(x)-5)*(diff(y(x), x)) = 0

y(0) = 0

maple_sol:=dsolve([ode,IC],[dAlembert],implicit):
maple_sol:=simplify(%);
odetest(maple_sol,[ode,IC]);

3*(x+1)*((2/3)*((x+y(x)+3)/(-x+3*y(x)+5))^(2/3)*(x-3*y(x)-5)*((-4*x+4*y(x)+4)/(x-3*y(x)-5))^(1/3)+I*3^(1/6)*2^(2/3)+(1/3)*6^(2/3))/(((x+y(x)+3)/(-x+3*y(x)+5))^(2/3)*((-4*x+4*y(x)+4)/(x-3*y(x)-5))^(1/3)*(2*x-6*y(x)-10)) = 0

[0, 0]

my_sol:=x + 2^(1/3)*(2^(2/3)*((y(x) + x + 3)/(-x + 3*y(x) + 5))^(2/3)*(x - 3*y(x) - 5)*((4*y(x) - 4*x + 4)/(x - 3*y(x) - 5))^(1/3) + 2^(2/3)*3^(2/3)*(-4)^(1/3)*(x + 1))/(((4*y(x) - 4*x + 4)/(x - 3*y(x) - 5))^(1/3)*((y(x) + x + 3)/(-x + 3*y(x) + 5))^(2/3)*(2*x - 6*y(x) - 10)) = 0;

x+2^(1/3)*(2^(2/3)*((x+y(x)+3)/(-x+3*y(x)+5))^(2/3)*(x-3*y(x)-5)*((-4*x+4*y(x)+4)/(x-3*y(x)-5))^(1/3)+2^(2/3)*3^(2/3)*(-4)^(1/3)*(x+1))/(((-4*x+4*y(x)+4)/(x-3*y(x)-5))^(1/3)*((x+y(x)+3)/(-x+3*y(x)+5))^(2/3)*(2*x-6*y(x)-10)) = 0

#this shows my solution and Maple are same mathematically the same
simplify(lhs(maple_sol)-lhs(my_sol));

0

simplify(maple_sol-my_sol);

0 = 0

#but can't get odetest to give zero to my solution. Why?
the_residual:=odetest(my_sol,[ode,IC]):
evalb(the_residual=0);

false

evalb(simplify(the_residual)=0);

false

odetest(normal(my_sol),[ode,IC]): #did not work. Not zero. very long result

odetest(radnormal(my_sol),[ode,IC]): #did not work. Not zero. very long result

odetest(combine(my_sol),[ode,IC]): #did not work. Not zero. very long result

odetest(evala(my_sol),[ode,IC]): #did not work. Not zero. very long result

odetest(my_sol,[ode,IC]) assuming real: #did not work. Not zero. very long result

odetest(my_sol,[ode,IC]) assuming x>0: #did not work. Not zero. very long result

odetest(my_sol,[ode,IC]) assuming x<0: #did not work. Not zero. very long result

odetest(expand(my_sol),[ode,IC]): #did not work. Not zero. very long result

 


 

Download unable_to_get_odetest_to_verify_same_solution_august_23_2024.mw

Can solve give internal Maple error of division by zero to the caller?

Also when I run this using kernelopts('assertlevel'=1): or kernelopts('assertlevel'=2):, then not able to catch the internal error any more, which is division by zero using try/catch.

Only when kernelopts('assertlevel'=0).  can try/catch trap the error.

This means now I have to set kernelopts('assertlevel'=0) before calling solve to be able to trap the error and set it back to kernelopts('assertlevel'=2) after that, else the whole program halts.

But my main question is: can solve throw internal error of division by zero? I mean, is this expected sometimes to happen? I would have thought Maple should internally catch this and simply return no solution if can't solve it.

This equation is auto generated and the program calling solve on it to see if it can solve it.

Here is the worksheet

interface(version);

`Standard Worksheet Interface, Maple 2024.1, Windows 10, June 25 2024 Build ID 1835466`

Physics:-Version()

`The "Physics Updates" version in the MapleCloud is 1792 and is the same as the version installed in this computer, created 2024, August 22, 12:6 hours Pacific Time.`

libname;

"C:\Users\Owner\maple\toolbox\2024\Physics Updates\lib", "C:\Program Files\Maple 2024\lib"

eq:=1 = 1/((exp(X*Y)*exp(X*y0)*exp(x0*Y)*exp(x0*y0)*X + exp(X*Y)*exp(X*y0)*exp(x0*Y)*exp(x0*y0)*x0 + 2*Y + 2*y0)^2*Y*(exp(X*Y)^2*exp(X*y0)^2*exp(x0*Y)^2*exp(x0*y0)^2*X + exp(X*Y)^2*exp(X*y0)^2*exp(x0*Y)^2*exp(x0*y0)^2*x0 + 2*exp(X*Y)*exp(X*y0)*exp(x0*Y)*exp(x0*y0)*X*Y^2 + 4*exp(X*Y)*exp(X*y0)*exp(x0*Y)*exp(x0*y0)*X*Y*y0 + 2*exp(X*Y)*exp(X*y0)*exp(x0*Y)*exp(x0*y0)*X*y0^2 + 2*exp(X*Y)*exp(X*y0)*exp(x0*Y)*exp(x0*y0)*Y^2*x0 + 4*exp(X*Y)*exp(X*y0)*exp(x0*Y)*exp(x0*y0)*Y*x0*y0 + 2*exp(X*Y)*exp(X*y0)*exp(x0*Y)*exp(x0*y0)*x0*y0^2 - X^2*exp(X*Y)*exp(X*y0)*exp(x0*Y)*exp(x0*y0) - 2*exp(X*Y)*exp(X*y0)*x0*exp(x0*Y)*exp(x0*y0)*X - exp(X*Y)*exp(X*y0)*x0^2*exp(x0*Y)*exp(x0*y0) - 2)):

kernelopts('assertlevel'=2):
try
   solve(identity(eq,X),[x0, y0]);
catch:
   print(lastexception);
end try;

Error, (in unknown) assertion failed

kernelopts('assertlevel'=1):

try
   solve(identity(eq,X),[x0, y0]);
catch:
   print(lastexception);;
end try;

Error, (in unknown) assertion failed

kernelopts('assertlevel'=0):

try
   solve(identity(eq,X),[x0, y0]);
catch:
   print(lastexception);
end try;

unknown, "numeric exception: division by zero"

 


 

Download division_by_zero_solve_identity_august_23_2024.mw

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