Maple 2024 Questions and Posts

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

I think I found another clitch in odetest.

dsolve gives correct solution to this first order ode with IC. But odetest does not verify that the solution is satisfied for the IC part, but only for the ode itself. 

Below worksheet confirms the solution is also valid for the IC.   So why odetest does not give 0 for the IC part?

``

restart;

19644

interface(version);

`Standard Worksheet Interface, Maple 2024.0, Windows 10, March 01 2024 Build ID 1794891`

Physics:-Version();

`The "Physics Updates" version in the MapleCloud is 1727. The version installed in this computer is 1725 created 2024, April 15, 17:29 hours Pacific Time, found in the directory C:\Users\Owner\maple\toolbox\2024\Physics Updates\lib\`

libname;

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

ode:=x^2*diff(y(x),x)*cos(y(x))+1=0;
ic:=y(infinity)=Pi/3; #16/3*Pi;
sol:=dsolve([ode,ic]);
odetest(sol,[ode,ic])

x^2*(diff(y(x), x))*cos(y(x))+1 = 0

y(infinity) = (1/3)*Pi

y(x) = arcsin((1/2)*(3^(1/2)*x+2)/x)

[0, (1/3)*Pi]

#we see that odetest think the solution does not verify the IC. But it does

IC_eq:=Pi/3=limit(rhs(sol),x=infinity)

(1/3)*Pi = (1/3)*Pi

Download odetest_does_not_verfiy_correct_solution_maple_2024_april_18_2024.mw

I think what odetest did is not use limit when plugging in the values. That is why.

If we do not use limit, this is what happens:

IC_eq:=Pi/3=eval(rhs(sol),x=infinity)

And this explains the odetest output. It should have used limit.

ps. just in case also reported to Maplesoft support.

Every last query I make in the AI Formula Assistant returns this message...

This happens even when I use a basic canned query shown in use-case examples (e.g., surface area, sphere).

I have accepted the Terms of Use.  Is there some other setting I need to enable? Thanks.

For the following program using dsolve to solved a differential equation with a sum of exponential inputs, the time required has a huge dependence on subtle difference in paramters.

For example, if Cl := 0.32, calculation time is 1.4 sec.    If Cl := 0.33,  calculation time is 39 sec.

Also, calculation time seems to have huge dependence  on whether or not I truncate M

Can someone please explain what is going on?

restart;
st := time();
N := 4;

T := 5.0/60;
M := 6905;
dose := t -> M*sum(Heaviside(t - 24*k/N)*exp((-t + 24*k/N)/T), k = 0 .. 2*N - 1);
Cl := 0.32;
deq := diff(C(t), t) = dose(t) - Cl*C(t);
sol := t -> rhs(dsolve({deq, C(0) = 0}));
p := plot(sol(t), t = 0 .. 48);
time() - st;
                             1.360
 

Hi,

I am the administrator of Maple in my school, and all the students use Maple in part of their exams. Is it possible  to block the access to ChatGPT thru eg. the firewall or otherwise during exams. 

The reason for this question is that the students must have access to some internet sources during exams, but definately not CharGPT.

Kind regards 

Per Kirkegaard

Hello, I try to solve the equations of the odometric model with the Maple 2024 but I have not the answers as with the hands, can you help me to verify it ?

dsolve(diff(phi(t), t) = tan(10*t)/5)

dsolve(diff(x(t), t) = V*cos(ln(1 + tan(10*t)^2)/100))

dsolve(diff(y(t), t) = V*sin(ln(1 + tan(10*t)^2)/100))

Best regards, Edern Ollivier.

I noticed that Student:-ODEs:-ODESteps does not use the newer subscripted constant of integrations for solution of odes which looks much nicer.

Is there a way to make it use same constant of integrations as dsolve() does? Compare  

This is on a worksheet using typesetting level extended. Worksheet is attached


 

restart

18836

interface(version);

`Standard Worksheet Interface, Maple 2024.0, Windows 10, March 01 2024 Build ID 1794891`

Physics:-Version();

`The "Physics Updates" version in the MapleCloud is 1724 and is the same as the version installed in this computer, created 2024, April 15, 17:29 hours Pacific Time.`

#to make Maple use the new constant of integrations. Is this still needed in Maple 2024?
dsolve(diff(y(x),x$9)=1,arbitraryconstants=subscripted):
pdsolve(diff(psi(x,t),x$9)=0,arbitraryfunctions=subscripted):

ode := diff(y(x), x$2) + 2*y(x) = 0;
Student:-ODEs:-ODESteps(ode,y(x));

ode := diff(y(x), x, x)+2*y(x) = 0

"[[,,"Let's solve"],[,,((ⅆ)^2)/(ⅆx^2) y(x)+2 y(x)=0],["•",,"Highest derivative means the order of the ODE is" 2],[,,((ⅆ)^2)/(ⅆx^2) y(x)],["•",,"Characteristic polynomial of ODE"],[,,r^2+2=0],["•",,"Use quadratic formula to solve for" r],[,,r=(0+/-([]))/2],["•",,"Roots of the characteristic polynomial"],[,,r=(-ⅈ sqrt(2),ⅈ sqrt(2))],["•",,"1st solution of the ODE"],[,,y[1](x)=cos(sqrt(2) x)],["•",,"2nd solution of the ODE"],[,,y[2](x)=sin(sqrt(2) x)],["•",,"General solution of the ODE"],[,,y(x)=C1 y[1](x)+C2 y[2](x)],["•",,"Substitute in solutions"],[,,y(x)=C1 cos(sqrt(2) x)+C2 sin(sqrt(2) x)]]"

#compare to this output
dsolve(ode,y(x));

y(x) = c__1*sin(2^(1/2)*x)+c__2*cos(2^(1/2)*x)


 

Download make_step_solution_use_new_constant_of_integration.mw

 

Is there a way to disable Maples AI Formula Assistant? This could be relevant when using Maple for a test.

I found that sometimes Maple gives

               Error, (in Typesetting:-Parse) too many levels of recursion

When using the Latex command on the output of Student:-ODEs:-ODESteps

Below is worksheet showing it works for some and gives error for others. Is there a workaround for this? I'd like to convert the steps to Latex.

This happens in worksheet using either Display->Typesetting level as EXTENDED or STANDARD

restart;

interface(version);

`Standard Worksheet Interface, Maple 2024.0, Windows 10, March 01 2024 Build ID 1794891`

Physics:-Version();

`The "Physics Updates" version in the MapleCloud is 1722 and is the same as the version installed in this computer, created 2024, April 12, 17:58 hours Pacific Time.`

ode:=diff(y(x),x)=0;
the_output:=Student:-ODEs:-ODESteps(ode,y(x)):
latex(the_output)

diff(y(x), x) = 0

\begin{array}{ccc}
 & {} & \textrm{Let's solve}
\\
 {} & {} & \frac{d}{d x}y \! \left(x \right)=0
\\
 \textrm{•} & {} & \textrm{Highest derivative means the order of the ODE is}1
\\
 {} & {} & \frac{d}{d x}y \! \left(x \right)
\\
 \textrm{•} & {} & \textrm{Integrate both sides with respect to}x  
\\
 {} & {} & \int \left(\frac{d}{d x}y \! \left(x \right)\right)d x =\int 0d x +\mathit{C1}  
\\
 \textrm{•} & {} & \textrm{Evaluate integral}
\\
 {} & {} & y \! \left(x \right)=\mathit{C1}  
\\
 \textrm{•} & {} & \textrm{Solve for}y \! \left(x \right)
\\
 {} & {} & y \! \left(x \right)=\mathit{C1}  
\end{array}

ode := diff(y(x), x, x, x ) + 3*diff(y(x), x, x) + 4*diff(y(x), x) + 2*y(x) = 0;
the_output:=Student:-ODEs:-ODESteps(ode,y(x)):
latex(the_output)

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

Error, (in Typesetting:-Parse) too many levels of recursion

 

 

Download latex_error_ODE_steps_maple_2024_april_13_2024.mw

update: Reported to Maplesoft support.

I have a proceure that returns 7 values. I cac get it to return ang single specific value ousing e.g [2] to get the second.
Or a range[3..6] for the third to sixth.

Is there a way to get specific seperated values e.g [1] and[[6]. The procedure is burried in a package so it is difficult to post.

This second order (Euler type) ode has no solution for the given two initial conditions. but Maple gives solution with one unresolved constant of integration.

ode:=x^2*diff(y(x),x$2)-2*y(x)=0;
ic:=y(0)=4,D(y)(0)=-1;

sol_no_IC:=dsolve(ode)

The IC's are given at x=0 as a trick to see what Maple will do. We see that at x=0 there is division by zero. So no solution exist for these IC's. But see what happens

sol_with_IC:=dsolve([ode,ic])

It seems Maple simply threw away the part of the solution it could not handle due to the x=0 and just returned the rest.

odetest(sol_with_IC,[ode,ic])

The correct answer should have been the NULL solution (i.e. no solution). 

What Am I missing here? Why does Maple do this? Should Maple have returned such a solution?

Maple 2024 on windows 10.

update:

Reported to Maplesoft support.

update:

Here is another example ode. This is first order ode. Maple gives a solution that does not satisfy the initial condition also. I wish I can understand how Maple comes up with these solutions since when I solve these by hand I see it is not possible to satisfy the IC, hence no solution exist.

14876

interface(version);

`Standard Worksheet Interface, Maple 2024.0, Windows 10, March 01 2024 Build ID 1794891`

Physics:-Version();

`The "Physics Updates" version in the MapleCloud is 1722 and is the same as the version installed in this computer, created 2024, April 12, 17:58 hours Pacific Time.`

restart;

14876

ode:=diff(y(x),x)+y(x)/x=x^2;
ic:=y(0)=a;

diff(y(x), x)+y(x)/x = x^2

y(0) = a

dsolve(ode)

y(x) = ((1/4)*x^4+c__1)/x

sol:=dsolve([ode,ic])

y(x) = (1/4)*x^3

odetest(sol,[ode,ic])

[0, a]

Student:-ODEs:-ODESteps([ode,ic])

Error, (in Student:-ODEs:-applyICO1) numeric exception: division by zero

 

 

Download another_strange_solution_ode_maple_2024.mw

I have a simple tank design worksheet that calculates dimensions of a tank that I need to build to hold a given amount of liquid.  My question is this - when I include a "with(Units);" statement, the volume function gets rendered in operator prefix notation.  Why is this?  Is there a setting to prevent this from happening?  Thanks.

Without "with(Units);"...

With "with(Units);"...