Maple 2020 Questions and Posts

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

I am trying to run a Groebner Basis computation below in a for loop a few times to get an average running time.

start := time[real]():
gb := Groebner[Basis](polynomials, tdeg(op(vars)), characteristic=2^29-3):
finish := time[real]() - start:

Because Maple apparently caches the result, i was wondering if there is a way to undo this caching? Or better yet, is there a built-in tool taht would do this time measurement multiple times?

This seems like a serious limitation of Maple module, unless I am missing something.

I am trying to refactor one of my module, putting some code in separate .mpl file, say B.mpl,  and then do, from the main module

   $include  "B.mpl"; 

 But Maple complain now that, since B.mpl has export in it, that I can't do that. 

But the code inside B.mpl works fine if I copy it back and paste it inside the module, in the same location where the $include  "B.mpl";  is

Here is an example. (Since I can't use $include  "B.mpl";  in worksheet, Maple does not like it, I replaced it in this example by read "B.mpl";

(btw, both the syntax  module A()   and A:=module() seem to be equivalent), the problem shows up with either form)

I also tried with ";" and witout ";" at the end of the $include , it still gives same error.

 

restart;

currentdir("....."); #set directory to where the folder is


module A()

read "B.mpl";

 export foo:=proc()
  0;
 end proc;
end module;

Where the file B.mpl is

export boo:=proc()
return 0;
end proc; 

How is one supposed to refactor long file to separate files if can't leave export on those proc's?  

If I put everything in one .mpl file, it works

module A()

#read "B.mpl";  

export boo:=proc()  #this proc was in B.mpl
return 0;
end proc; 

 export foo:=proc()
  0;
 end proc;
end module;

I did more testing, and found that this seems to be an issue in Maple 2020.2. Because I just tried the same thing in Maple 2019 and it worked there ! i.e. no error.

Any one knows what is going on? 

Maple 2020.2, Physics 884.   Windows 10.

Here is screen shot. Same code. Works OK in Maple 2019.2 but gives error in 2020.2

 

 

 

Hi,

How do I integrate with Units[Standard]?

For example:


 

restart

with(Units[Standard]):

I__RMS__T := int((18*Unit('A')+9*t*Unit('s')*Unit('A')/(.9*Unit('s')))^2, t = 0.1e-1*Unit('s') .. 10*Unit('s'))

Error, (in Units:-Standard:-+) the units `1` and `s` have incompatible dimensions

 

I__RMS__T := int((18*Unit('A')+9*t*Unit('A')/(.9*Unit('s')))^2, t = 0.1e-1*Unit('s') .. 10*Unit('s'))

Error, (in Units:-Standard:-+) the units `A` and `A/s` have incompatible dimensions

 

 

 

It doesn't seem like I can around this. Is there a way to ignore the units error and just calculate the value?
 

Download test.mw

What type of mathematics can perform the type of transformation seen in the uploaded worksheet?

Could it be done with the Maple plottools transform command?

Could it be a projective transformation using homogeneous coordinates?

Could it be a complex conformal transformation?

Transformation.mw

Dear all,

In some step of my program, Maple cannot understand that the two following vectors are equal:

V1 := Vector[column](8, [1, 2, 2, 1, 3, A, B, 1/(A + B)^2]);

V2 := Vector[column](8, [1, 2, 2, 1, 3, A, B, 1/(A^2 + 2*A*B + B^2)]);

I tried to use the following two commands:

LinearAlgebra:-Equal(V1[6 .. 8], V2[6 .. 8]);

verify(V1, V2, 'Vector(expand)');

but Maple still returns 'false' instead of 'true'

Could somebody help me please ?
Best regards,

I'd like to define a proc, which takes first argument to be either an ode (i.e. type `=`) or set of ode's, or list of ode's.

However, I do not know how to tell Maple that the list or set, if that is the type, to be a list of `=` and no other type.

Here is what I tried to make it more clear

If I do this

restart;

interface(warnlevel=4);
kernelopts('assertlevel'=2): 


foo:=proc(ode::{`=`, set,list},func::`function`,$)
   print("ode=",ode);
   print("func=",func);
end proc:

Then Maple will check that the first argument is ANY one of `=`, set or list. 

But does not check if the list or set contains only equations of type `=`.  So I am able to call the above like this

ode1:=diff(y(x),x)=1:
ode2:=diff(y(x),x)=x:
foo(ode1,y(x));  #this is OK
foo([ode1,a],y(x))  #this is wrong

Which is wrong, since `a` is not of type `=`.

Next I tried this (I also wanted to check that if first argument is list or set, that it is not empty, so added extra check)

restart;
interface(warnlevel=4);
kernelopts('assertlevel'=2):

foo:=proc(ode::{`=`, 
                   And(set,satisfies(x-> (numelems(x)<>0 and type(x,`=`))  )),
                   And(list,satisfies(x-> (numelems(x)<>0 and type(x,`=`))  ))
                   },
                   func::`function`,$                                   
                   )

  print("ode=",ode);
  print("func=",func);
end proc;

But the above gives an error

ode1:=diff(y(x),x)=1:
ode2:=diff(y(x),x)=x:

foo([ode1,a],y(x))  

I also tried

foo:=proc(ode::{`=`, 
                   And(set,satisfies(x-> type(x,`=`)  )),
                   And(list,satisfies(x-> type(x,`=`) ))
                   },
                   func::`function`,$                                   
                   )

   print("ode=",ode);
   print("func=",func);

end proc;

Also gives erorr when called 

foo([ode1,ode2],y(x))

Ofcourse, I can just leave the check as in first case above, and in the proc itself, do the check myself manually by going over each entry in the list or set to make sure each entry is of type `=`. 

But I wanted Maple to do this work for me, if possible.

What is the correct syntax for doing so?

Maple 2020.2

 

I am trying to plot generator reactive output (Q) over a range of generator power output (P) with field current (Ifldc) and terminal voltage (Et) constant using “solve”. The system of equations includes an interpolating fiction Ifld(el).

I’m looking for some help as to how to configure a solution. Attached are a few of my failed attempts.

The upload of my file deleats the "solve" fo my first try it is:

     


 

``

``

MvaGen := 1354; PfGen := .935; KvGen := 24

                   

           Xd__u := 1.89 - Synchronous reactance of d-axis, Unsatuarted

              Xq__u := 1.80 - Synchronous reactance of q-axis, Unsatuarted

              X__l := .26   - leakage reactance d or q-axis``

``

            Ifld__base := 3114

``

Open Ckt Sat Curve DS807-1a

     First col=Ifld amps   

     Second col= el voltage behind leakage reactance

 

OC_SatDat := Matrix(16, 2, {(1, 1) = 0, (1, 2) = 0., (2, 1) = 655.6456, (2, 2) = .3422578, (3, 1) = 1009.961, (3, 2) = .5331404, (4, 1) = 1253.12, (4, 2) = .6492209, (5, 1) = 1562.724, (5, 2) = .8014143, (6, 1) = 1893.545, (6, 2) = .9329786, (7, 1) = 2201.68, (7, 2) = 1.033593, (8, 1) = 2487.276, (8, 2) = 1.108416, (9, 1) = 2793.943, (9, 2) = 1.157452, (10, 1) = 3122.338, (10, 2) = 1.203911, (11, 1) = 3690.959, (11, 2) = 1.263294, (12, 1) = 4259.141, (12, 2) = 1.307202, (13, 1) = 4827.028, (13, 2) = 1.340795, (14, 1) = 5351.085, (14, 2) = 1.366646, (15, 1) = 5787.775, (15, 2) = 1.387329, (16, 1) = 6224.391, (16, 2) = 1.405433})

  ido := It*sin(theta+delta)

Plot OC saturation with field current in pu

 

with(LinearAlgebra)

with(ArrayTools)

with(plots)

      OC_Sat_Ifld_pu := Column(OC_SatDat, [1])/Ifld__base

         OC_Sat := Concatenate(2, Column(OC_SatDat, [2]), OC_Sat_Ifld_pu) 

````

iterpolate values of field current vs el from OC sat curve

 

                                    pts_el := Column(OC_Sat, [1]); pts_Ifldpu := Column(OC_Sat, [2])

 

 

                         Ifield as a function of el  ->  Ifld := LinearInterpolation(pts_el, pts_Ifldpu)

``

 

Solve for Q with

    

P = .935; Iflc := 1.88; Et := 1.0

 

NULL

TRY1

``

 Eq1 := Ir = P/Et; Eq2 := Ix = Q/Et    Eq3 := It*sqrt(Ir^2+Ix^2)     Eq4:=theta = arctan(Q, P)

``

    Eq5 := el = abs(Et+X__l*(Ix+I*Ir))      Eq6 := `&Psi;AG__d` = Xad__u*Ifld(el)   Eq7:=K__ds = el/`&Psi;AG__d`

     NULL 

NULL Eq8 := Xd__s = K__ds*Xad__u+X__l   Eq9 := `&Psi;AG__q` = Xaq__u*Ifld(el)    Eq10 := K__qs = el/`&Psi;AG__q`

 

   Eq11 := Xq__s = X__l+K__qs(el)*Xaq__u      Eq12 := Eq = Et+Xq__s(el)*(Q/Et+I*P/Et)

NULLNULL

    

Eq13 := delta = argument(Eq)        Eq14 := eqo = Et*cos(delta)    Eq15 := ido = It*sin(theta+delta)

``

Eq16 := EI = Xd__s*Iflec; Eq17 := EI = Ido*Xd__s+eqo

``

 
syst := {E15, Eq1, Eq10, Eq11, Eq12, Eq13, Eq14, Eq16, Eq17, Eq2, Eq3, Eq4, Eq5, Eq6, Eq7, Eq8, Eq9}

 

   

NULL

solve(sys, {Eq, Ir, It, Ix, K__ds, K__qs, Q, Xd__s, Xq__s, el, eqo, ido, theta, `&Psi;AG__d`, `&Psi;AG__q`})

Warning, solving for expressions other than names or functions is not recommended.

 

 

NULL         

TRY 2

              NULL

`` Ix := proc (Q) options operator, arrow; Q/Et end proc   It := proc (Q) options operator, arrow; sqrt(Ir^2+Ix^2) end proc     theta := proc (Q) options operator, arrow; arctan(Q, P) end proc

``

 el := proc (Q) options operator, arrow; abs(Et+X__l*(Ix(Q)+I*Ir)) end proc      `&Psi;AG__d` := proc (Q) options operator, arrow; Xad__u*Ifld(el(Q)) end proc   K__ds := proc (Q) options operator, arrow; el(Q)/`&Psi;AG__d`(el(Q)) end proc``

NULL Xd__s := proc (Q) options operator, arrow; X__l+K__ds(el(Q))*Xad__u end proc   `&Psi;AG__q` := proc (Q) options operator, arrow; Xaq__u*Ifld(el(Q)) end proc    K__qs := proc (Q) options operator, arrow; el(Q)/`&Psi;AG__q`(el(Q)) end proc

Xq__s := proc (Q) options operator, arrow; X__l+K__qs(Q)*Xaq__u end proc      Eq := proc (Q) options operator, arrow; Et+Xq__s(Q)*(Q/Et+I*P/Et) end proc

``

delta := proc (Q) options operator, arrow; argument(Eq(Q)) end proc        eqo := proc (Q) options operator, arrow; Et*cos(delta(Q)) end proc    ido := proc (Q) options operator, arrow; It*sin(theta(Q)+delta(Q)) end proc``

``

EI := proc (Q) options operator, arrow; Xd__s(Q)*Iflec end proc    EI := proc (Q) options operator, arrow; eqo(Q)+Xd__s(Q)*Ido(Q) end proc

``

NULL

solve(EI(Q) = eqo(Q)+Xd__s(Q)*Ido(Q), {Eq, Ir, It, Ix, K__ds, K__qs, Q, Xd__s, Xq__s, el, eqo, ido, theta, `&Psi;AG__d`, `&Psi;AG__q`})

{Eq = Eq, Ir = Ir, It = It, Ix = Ix, K__ds = K__ds, K__qs = K__qs, Q = Q, Xd__s = Xd__s, Xq__s = Xq__s, el = el, eqo = eqo, ido = ido, theta = theta, `&Psi;AG__d` = `&Psi;AG__d`, `&Psi;AG__q` = `&Psi;AG__q`}

(1)

NULL

TRY3

 

     "Eq20:=Ir=P/(Et):     Eq21:=Ix=Q->Q/(Et):"

Error, invalid operator parameter name

"Eq20:=Ir=P/Et: Eq21:=Ix=Q->Q/Et:"

 

``

``

``

``


 

Download Qcalc1.mw

 

What is your choice for creating a good table?

For example;

 

f:=(x,t)->x*t;
g:=(x,t)->x^2*t;

How to create a table as follows? (Appearance similar to the following is not required. I am open to all options)

Hi, I am doing a project about three body problem. I am solving a DE system with 12 DEs and plotting it with phase portrait. It is all good if I am only using vars in scene. like this:

pp1 := phaseportrait([eq1(t), eq2(t), eq3(t), eq4(t), eq5(t), eq6(t), eq7(t), eq8(t), eq9(t), eq10(t), eq11(t), eq12(t)], [x1(t), y1(t), vx1(t), vy1(t), x2(t), y2(t), vx2(t), vy2(t), x3(t), y3(t), vx3(t), vy3(t)], t = 0 .. 8.75*10^7, [[x1(0) = X1, y1(0) = Y1, vx1(0) = VX1, vy1(0) = VY1, x2(0) = X2, y2(0) = Y2, vx2(0) = VX2, vy2(0) = VY2, x3(0) = X3, y3(0) = Y3, vx3(0) = VX3, vy3(0) = VY3]], scene = [x1(t), y1(t)], stepsize = 1000, x1 = 0 .. 10^6, y1 = 0 .. 6*10^6, color = [red], scaling = constrained):

But I cannot plot any combinations of my variables. I have orthogonalized all the velocity, and I can plot [t,vx(t)] or [t, vy(t)]. But I cannot plot [t, (vx(t)^2+vy(t)^2)^1/2]:

vel1 := phaseportrait([eq1(t), eq2(t), eq3(t), eq4(t), eq5(t), eq6(t), eq7(t), eq8(t), eq9(t), eq10(t), eq11(t), eq12(t)], [x1(t), y1(t), vx1(t), vy1(t), x2(t), y2(t), vx2(t), vy2(t), x3(t), y3(t), vx3(t), vy3(t)], t = 0 .. 3.5*10^7, [[x1(0) = X1, y1(0) = Y1, vx1(0) = VX1, vy1(0) = VY1, x2(0) = X2, y2(0) = Y2, vx2(0) = VX2, vy2(0) = VY2, x3(0) = X3, y3(0) = Y3, vx3(0) = VX3, vy3(0) = VY3]], scene = [t, (vx3(t)^2 + vy3(t)^2)^(1/2)], stepsize = 1000, linecolor = [purple], scaling = constrained);
Error, (in DEtools/phaseportrait) Invalid scene; must be list of vars: scene = [t, (vx3(t)^2+vy3(t)^2)^(1/2)]
 

Is there a way to let me plot the v(t) ?

why setting interface(warnlevel=0); makes dsolve change the form of the final solution to an ODE?

Is this to be expected? Help on warnlevel 0 says to just suppress all warnings

In this example, both solutions are equivalent. One is just simpler than the other.

But now I am worried if this setting could affect dsolve in other ways not yet anticipated.
 

restart;

interface(version);

`Standard Worksheet Interface, Maple 2020.2, Windows 10, November 11 2020 Build ID 1502365`

Physics:-Version();

`The "Physics Updates" version in the MapleCloud is 884 and is the same as the version installed in this computer, created 2020, November 25, 16:49 hours Pacific Time.`

interface(warnlevel=0);

3

ic:=y(0)=3:
ode := diff(y(x),x)*y(x)/(1+1/2*sqrt(1+diff(y(x),x)^2))=-x:
sol_1:=dsolve([ode,ic],y(x),singsol=all);

y(x) = -3+(1/3)*(-9*x^2+324)^(1/2), y(x) = 1+(1/3)*(-9*x^2+36)^(1/2)

restart;

ic:=y(0)=3:
ode := diff(y(x),x)*y(x)/(1+1/2*sqrt(1+diff(y(x),x)^2))=-x:
sol_2:=dsolve([ode,ic],y(x),singsol=all);

y(x) = -3+(-x^2+36)^(1/2), y(x) = 1+(-x^2+4)^(1/2)


 

Download warnlevel_difference.mw

btw, the same thing happens with warnlevel 2. i.e. answers look different.

But with warnlevel 3 and 4, now dsolve gives the same answer. 

SInce it seems default is warnlevel 3, it seems internally, dsolve takes different path depending on warnlevel setting? 

Edit

Here is a movie. I am using windows 10.

 

Edit: Here is another video. Tried now with fresh start of Maple. i.e. closed Maple and started it again.  Using worksheet. No other worksheet was open. This is what I found. Initially it gives the longer solution. After couple of tries, it then changed to the simpler one

 

I found a condition for p, q that N=pq can be factored in plynominal time using Maple 2020.
Is fllowing Hypothesis and Proof is right?

Hypothesis

       N=pq  p and q are large prime respectively.
         R=q/p  q > p  R is very close to an small integer or a simple rational number.
       
        N=pq can be factorized in time polynomial

Proof
        point[p, q] is on y=N/x
        y=N/x  and y=Rx cross at point[p, q]
        N is n digit
        upper  2 digits N2  round off the 3rd digit
        upper  3 digits N3  round off the 4th digit
        upper  4 digits N4  round off the 5th digit
        
        y=N2/x and y=Rx cross at point[p2,q2]
        y=N3/x and y=Rx cross at point[p3,q3]
        y=N4/x and y=Rx cross at point[p4, p4]

        But we only know N.

        Let line up candidates point[p2,q2] , point[p3,q3] and point[p4, p4]


       N2 < 99  i=1..10 j=1..10
       R2=i/j
       f2=N2/R2 - j^2
       dn2=abs(N2-R2*j^2)   

      N4 < 9999  i=1..99 j=1.. sqrt(N4)
      R4=i/j
      f4=N4/R4 - j^2
      dn4=abs(N4-R4*j^2)

     Point[j, i] that have  small f2 and dn2 can be nominated as candidate for point[p2, q2]
     Point[j, i] that have  small f3 and dn3 can be nominated as candidate for point[p3, q3]
     Point[j, i] that have  small f4 and dn4 can be nominated as candidate for point[p4, q4]

    Find cross point[px, qx] of y=R2x and y=N/x , y=R3x, y=N/x and y=R4x, y=N/x
    Find the nearest prime pn for px and the nearest prime qn for qx
   
   pn*qn=N  bingo!

   Number of candidates are finit.
   You can factorized N=pq in time polynomial.
                                   
                                                                       Q.E.D. ?

In addition, using "https://www.mapleprimes.com/questions/228532-Strange-Factorization"

Rang from p - half digits of p to p + half degits of p and /or range q - half digits of q to q + half degits of q  N=pq can be factored in plynominal time.

Hi, could someone tell me what this comma inside the arctan means?

Screenshot: https://photos.app.goo.gl/ZHyfdqcxWDgvgMZL7

i want to compute and draw  lattice points from a given lattice basis.

for example 2d cartesian coordinate system;

thank 

 

 

Hello Maple experts;

We've talked about this subject before. odetest not verifying dsolve output. And very useful input was given:

https://www.mapleprimes.com/questions/227546-How-To-Make-Odetest-Verify-Dsolve

https://www.mapleprimes.com/questions/227638-How-To-Make-Odetest-Give-Zero-On-Its

Here, I thought to give a collection from my ode database of ode's that are solved by Maple, but odetest does not give zero, all in one place. 

I know this is a hard problem to get odetest to always verify its own solution. May be each case needs custom solution?

It would be nice if this area in Maple could be improved on more if possible (Maple is already a CAS leader in solving ODE's).

If some of the experts here like to see if they can get odetest to give zero on some of these examples, they are welcome to and will be useful to see. I only tried just simplify().

I depend on odetest to tell me if my solution is correct or not, and getting false negative makes me spend more time trying to find where my error in my solution, where there might be no error there, and it is just that odetest could not verify it.

These are all from different text books. I put the reference on each ODE where it was obtained from.

Two of these ODE can also hang or take very long time. I indicated that there so one might want to skip these two.

edit added new one, #1822, uploaded new worksheet


 

interface(version);

`Standard Worksheet Interface, Maple 2020.2, Windows 10, November 11 2020 Build ID 1502365`

Physics:-Version()

`The "Physics Updates" version in the MapleCloud is 884 and is the same as the version installed in this computer, created 2020, November 25, 16:49 hours Pacific Time.`

#796
#Book: Elementary differential equations with boundary value problems. William F. Trench. Brooks/Cole 2001
#Section: Section 1.2 Page 14
#Problem number: 9.
restart;
ode:=diff(y(x),x) = abs(y(x))+1;
sol:=dsolve(ode,y(x));
odetest(sol[1],ode):
simplify(%);

diff(y(x), x) = abs(y(x))+1

y(x) = -exp(-x)/_C1+1, y(x) = exp(x)*_C1-1

(-abs((-exp(-x)+_C1)/_C1)*_C1+exp(-x)-_C1)/_C1

#878
#Book: Elementary differential equations with boundary value problems. William F. Trench. Brooks/Cole 2001
#Section: Section 2.3 Page 55
#Problem number: 10.
restart;
ode:=diff(y(x),x) = x*(y(x)^2-1)^(2/3);
sol:=dsolve(ode,y(x));
odetest(sol,ode):
simplify(%);

diff(y(x), x) = x*(y(x)^2-1)^(2/3)

(1/2)*x^2-(-signum(y(x)^2-1))^(2/3)*y(x)*hypergeom([1/2, 2/3], [3/2], y(x)^2)/signum(y(x)^2-1)^(2/3)+_C1 = 0

-x*(4*y(x)^2*(y(x)^2-1)^(2/3)*signum(y(x)^2-1)^(1/3)*hypergeom([3/2, 5/3], [5/2], y(x)^2)+9*(y(x)^2-1)^(2/3)*signum(y(x)^2-1)^(1/3)*hypergeom([1/2, 2/3], [3/2], y(x)^2)+9*(-signum(y(x)^2-1))^(1/3))

#903
#Book: Elementary differential equations with boundary value problems. William F. Trench. Brooks/Cole 2001
#Section: Section 2.4 Page 57
#Problem number: 13.
restart;
ode:=diff(y(x),x)-y(x) = x*y(x)^(1/2);
ic:=y(0)=4;
sol:=dsolve([ode,ic],y(x));
odetest(sol,ode):
simplify(%);

diff(y(x), x)-y(x) = x*y(x)^(1/2)

y(0) = 4

y(x) = 16*(exp((1/2)*x))^2-8*x*exp((1/2)*x)+x^2-16*exp((1/2)*x)+4*x+4

-x*(((-8*x-16)*exp((1/2)*x)+x^2+4*x+16*exp(x)+4)^(1/2)-4*exp((1/2)*x)+x+2)

#1330
#Book: Differential equations and their applications, 3rd ed., M. Braun
#Section: Section 1.10. Page 80
#Problem number: 5.
restart;
ode:=diff(y(t),t) = 1+y(t)+y(t)^2*cos(t);
sol:=dsolve(ode,y(t)):
timelimit(60,odetest(sol,ode)); #WARNING, will either hang or take long time then timeout

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

#1498
#Book: Differential Gleichungen, Kamke, 3rd ed
#Section: section 1.0
#Problem number: 25.
restart;
ode:=diff(y(x),x) = c*x^(-1+v)+b*x^(2*v)-a*y(x)^2;
sol:=dsolve(ode,y(x)):
odetest(sol,ode): #output too long to post

diff(y(x), x) = c*x^(-1+v)+b*x^(2*v)-a*y(x)^2

#1822
#Book: Advanced Mathematica, Book2, Perkin and Perkin, 1992
#Section: Chapter 11.3, page 316
restart;
ode:=x*y(x)*diff(y(x),x) = (y(x)^2-9)^(1/2);
ic:=y(exp(4)) = 5;
sol:=dsolve([ode,ic],y(x));
odetest(sol,[ode,ic]);
#needs:
odetest(sol,[ode,ic]) assuming x>1

x*y(x)*(diff(y(x), x)) = (y(x)^2-9)^(1/2)

y(exp(4)) = 5

y(x) = (9+ln(x)^2)^(1/2)

[-ln(x)*(csgn(ln(x))-1), 0]

[0, 0]

#1966
#Book: Differential equations for engineers by Wei-Chau XIE, Cambridge Press 2010
#Section: Chapter 2
#Problem number: 92.
restart;
ode:=2*x*diff(y(x),x)-y(x) = ln(diff(y(x),x));
sol:=dsolve(ode,y(x));
odetest(sol[1],ode):
simplify(%);
odetest(sol[2],ode);
simplify(%);

2*x*(diff(y(x), x))-y(x) = ln(diff(y(x), x))

y(x) = 1+(4*_C1*x+1)^(1/2)-ln((1/2)*(1+(4*_C1*x+1)^(1/2))/x), y(x) = 1-(4*_C1*x+1)^(1/2)-ln(-(1/2)*(-1+(4*_C1*x+1)^(1/2))/x)

-ln(2)+ln((1+(4*_C1*x+1)^(1/2))/x)-ln((2*x*_C1+(4*_C1*x+1)^(1/2)+1)/(x*(1+(4*_C1*x+1)^(1/2))))

-ln(2)+ln(-(-1+(4*_C1*x+1)^(1/2))/x)-ln((-2*x*_C1+(4*_C1*x+1)^(1/2)-1)/(x*(-1+(4*_C1*x+1)^(1/2))))

-ln(2)+ln((-(4*_C1*x+1)^(1/2)+1)/x)-ln((-2*x*_C1+(4*_C1*x+1)^(1/2)-1)/(x*(-1+(4*_C1*x+1)^(1/2))))

#2031
#Book: Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
#Section: Various 3
#Problem number: 57.
ode:=diff(y(x),x) = a*x^(n-1)+b*x^(2*n)+c*y(x)^2;
sol:=dsolve(ode,y(x)):
odetest(sol,ode):
simplify(%)

diff(y(x), x) = a*x^(n-1)+b*x^(2*n)+c*y(x)^2

(1/2)*(-20*(I*a*c*(n+6/5)*b^(3/2)+(1/5)*b*a*(2*x^(n+1)*b+a)*c^(3/2)+(6/5)*(n+4/3)*(I*b^(5/2)*x^(n+1)*c-b^2*c^(1/2)*(n+1)))*(n+1)*WhittakerW(-(I*c^(1/2)*a+(-2*n-2)*b^(1/2))/(b^(1/2)*(2*n+2)), 1/(2*n+2), (2*I)*b^(1/2)*c^(1/2)*x^(n+1)/(n+1))+WhittakerW(-I*c^(1/2)*a/(b^(1/2)*(2*n+2)), 1/(2*n+2), (2*I)*b^(1/2)*c^(1/2)*x^(n+1)/(n+1))*(-(7*I)*a*c*(n^2+(16/7)*n+8/7)*b^(3/2)-5*a^2*b*(n+6/5)*c^(3/2)+3*b^2*(2+n)*(n+4/3)*n*c^(1/2)+I*c^2*a^3*b^(1/2)))*_C1/(c^(3/2)*b^(3/2)*(I*c^(1/2)*a+(-3*n-4)*b^(1/2))*x^2*(WhittakerW(-I*c^(1/2)*a/(b^(1/2)*(2*n+2)), 1/(2*n+2), (2*I)*b^(1/2)*c^(1/2)*x^(n+1)/(n+1))*_C1+WhittakerM(-I*c^(1/2)*a/(b^(1/2)*(2*n+2)), 1/(2*n+2), (2*I)*b^(1/2)*c^(1/2)*x^(n+1)/(n+1))))

#2372
#Book: Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
#Section: Various 14
#Problem number: 407
ode:=diff(y(x),x)*(x^3+1)^(2/3)+(1+y(x)^3)^(2/3) = 0;
sol:=dsolve(ode,y(x)):
odetest(sol,ode):
simplify(%)

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

-9*((4/9)*(1+y(x)^3)^(2/3)*Pi*3^(1/2)*LegendreP(-1/3, -1/3, (-y(x)^3+1)/(1+y(x)^3))*(-x^3)^(1/6)+(-(4/9)*(1+y(x)^3)^(1/3)*Pi*3^(1/2)*(x^3+1)^(1/3)*LegendreP(-1/3, -1/3, (-x^3+1)/(x^3+1))+GAMMA(2/3)*(-x^3)^(1/6)*((-y(x)^6-y(x)^3)*hypergeom([4/3, 5/3], [7/3], -y(x)^3)+x^3*(1+y(x)^3)^(1/3)*hypergeom([4/3, 5/3], [7/3], -x^3)*(x^3+1)^(2/3)))*(-y(x)^3)^(1/6))/((-x^3)^(1/6)*(9*hypergeom([4/3, 5/3], [7/3], -y(x)^3)*y(x)^3*(-y(x)^3)^(1/6)*(1+y(x)^3)^(1/3)*GAMMA(2/3)-4*Pi*3^(1/2)*LegendreP(-1/3, -1/3, (-y(x)^3+1)/(1+y(x)^3))))

#3035
#Book: Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
#Section: Various 37
#Problem number: 1118.
restart;
ode:=(diff(y(x),x)^2+1)^(1/2)+a*diff(y(x),x) = x;
sol:=[dsolve(ode,y(x))]:
odetest(sol[1],ode):
simplify(%);
odetest(sol[2],ode):
simplify(%)

((diff(y(x), x))^2+1)^(1/2)+a*(diff(y(x), x)) = x

((a^2+x^2-1)^(1/2)*(a^2-1)*((a^4+(x^2-1)*a^2+2*a*x*(a^2+x^2-1)^(1/2)+x^2)/(a^2-1)^2)^(1/2)+a^3+a*x^2+x*(a^2+x^2-1)^(1/2)-a)/((a^2+x^2-1)^(1/2)*(a^2-1))

-((-a^2+1)*(a^2+x^2-1)^(1/2)*((a^4+(x^2-1)*a^2-2*a*x*(a^2+x^2-1)^(1/2)+x^2)/(a^2-1)^2)^(1/2)+a^3+a*x^2-x*(a^2+x^2-1)^(1/2)-a)/((a^2+x^2-1)^(1/2)*(a^2-1))

#3036
#Book: Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
#Section: Various 37
#Problem number: 1119.
restart;
ode:=(diff(y(x),x)^2+1)^(1/2)+a*diff(y(x),x) = y(x);
sol:=[dsolve(ode,y(x))];
odetest(sol[1],ode):
simplify(%);
odetest(sol[2],ode):
simplify(%)

((diff(y(x), x))^2+1)^(1/2)+a*(diff(y(x), x)) = y(x)

[x-Intat(-(a-1)*(a+1)/(-a*_a+(_a^2+a^2-1)^(1/2)), _a = y(x))-_C1 = 0, x-Intat((a-1)*(a+1)/(a*_a+(_a^2+a^2-1)^(1/2)), _a = y(x))-_C1 = 0]

(((y(x)^2*a^2+a^4-2*y(x)*(y(x)^2+a^2-1)^(1/2)*a+y(x)^2-a^2)/(a^2-1)^2)^(1/2)*a^2-(y(x)^2+a^2-1)^(1/2)*a+y(x)-((y(x)^2*a^2+a^4-2*y(x)*(y(x)^2+a^2-1)^(1/2)*a+y(x)^2-a^2)/(a^2-1)^2)^(1/2))/(a^2-1)

(((y(x)^2*a^2+a^4+2*y(x)*(y(x)^2+a^2-1)^(1/2)*a+y(x)^2-a^2)/(a^2-1)^2)^(1/2)*a^2+(y(x)^2+a^2-1)^(1/2)*a-((y(x)^2*a^2+a^4+2*y(x)*(y(x)^2+a^2-1)^(1/2)*a+y(x)^2-a^2)/(a^2-1)^2)^(1/2)+y(x))/(a^2-1)

#3040
#Book: Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
#Section: Various 37
#Problem number: 1126.
restart;
ode:=a*x*(diff(y(x),x)^2+1)^(1/2)+x*diff(y(x),x)-y(x) = 0;
sol:=[dsolve(ode,y(x))];
odetest(sol[1],ode): #too large to display
odetest(sol[2],ode): #too large to display

a*x*((diff(y(x), x))^2+1)^(1/2)+x*(diff(y(x), x))-y(x) = 0

[x-exp(arcsinh(((-a^2*x^2+x^2+y(x)^2)^(1/2)*a+y(x))/((a^2-1)*x))/a)*_C1/((-a^2*x^2+a^2*y(x)^2+2*(-a^2*x^2+x^2+y(x)^2)^(1/2)*a*y(x)+x^2+y(x)^2)/((a^2-1)^2*x^2))^(1/2) = 0, x-exp(-arcsinh(((-a^2*x^2+x^2+y(x)^2)^(1/2)*a-y(x))/((a^2-1)*x))/a)*_C1/(-(a^2*x^2-a^2*y(x)^2+2*(-a^2*x^2+x^2+y(x)^2)^(1/2)*a*y(x)-x^2-y(x)^2)/((a^2-1)^2*x^2))^(1/2) = 0]

#3054
#Book: Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
#Section: Various 37
#Problem number: 1146.
restart;
ode:=ln(diff(y(x),x))+4*x*diff(y(x),x)-2*y(x) = 0;
sol:=[dsolve(ode,y(x))];
odetest(sol[1],ode):
simplify(%);
odetest(sol[2],ode):
simplify(%);

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

[y(x) = (1/2)*ln((1/4)*(-1+(16*_C1*x+1)^(1/2))/x)-1/2+(1/2)*(16*_C1*x+1)^(1/2), y(x) = (1/2)*ln(-(1/4)*(1+(16*_C1*x+1)^(1/2))/x)-1/2-(1/2)*(16*_C1*x+1)^(1/2)]

ln(2)+ln((8*x*_C1-(16*_C1*x+1)^(1/2)+1)/(x*(-1+(16*_C1*x+1)^(1/2))))-ln((-1+(16*_C1*x+1)^(1/2))/x)

ln(2)+ln((-8*x*_C1-(16*_C1*x+1)^(1/2)-1)/(x*(1+(16*_C1*x+1)^(1/2))))-ln((-1-(16*_C1*x+1)^(1/2))/x)

#3128
#Book: Differential Equations, By George Boole F.R.S. 1865
#Section: Chapter 7
#Problem number: 7.
restart;
ode:=y(x) = a*diff(y(x),x)+(diff(y(x),x)^2+1)^(1/2);
sol:=[dsolve(ode,y(x))];
odetest(sol[1],ode):
simplify(%);
odetest(sol[2],ode):
simplify(%);

y(x) = a*(diff(y(x), x))+((diff(y(x), x))^2+1)^(1/2)

[x-Intat(-(a-1)*(a+1)/(-a*_a+(_a^2+a^2-1)^(1/2)), _a = y(x))-_C1 = 0, x-Intat((a-1)*(a+1)/(a*_a+(_a^2+a^2-1)^(1/2)), _a = y(x))-_C1 = 0]

((y(x)^2+a^2-1)^(1/2)*a-y(x)-((y(x)^2*a^2+a^4-2*y(x)*(y(x)^2+a^2-1)^(1/2)*a+y(x)^2-a^2)/(a^2-1)^2)^(1/2)*(a^2-1))/(a^2-1)

(-(y(x)^2+a^2-1)^(1/2)*a-y(x)-((y(x)^2*a^2+a^4+2*y(x)*(y(x)^2+a^2-1)^(1/2)*a+y(x)^2-a^2)/(a^2-1)^2)^(1/2)*(a^2-1))/(a^2-1)

#3129
#Book: Differential Equations, By George Boole F.R.S. 1865
#Section: Chapter 7
#Problem number: 8.
restart;
ode:=x = a*diff(y(x),x)+(diff(y(x),x)^2+1)^(1/2);
sol:=[dsolve(ode,y(x))];
odetest(sol[1],ode):
simplify(%);
odetest(sol[2],ode):
simplify(%);

x = a*(diff(y(x), x))+((diff(y(x), x))^2+1)^(1/2)

[y(x) = (1/2)*x*(a^2+x^2-1)^(1/2)/((a-1)*(a+1))+(1/2)*ln(x+(a^2+x^2-1)^(1/2))*a^2/((a-1)*(a+1))-(1/2)*ln(x+(a^2+x^2-1)^(1/2))/((a-1)*(a+1))+(1/2)*a*x^2/((a-1)*(a+1))+_C1, y(x) = -(1/2)*x*(a^2+x^2-1)^(1/2)/((a-1)*(a+1))-(1/2)*ln(x+(a^2+x^2-1)^(1/2))*a^2/((a-1)*(a+1))+(1/2)*ln(x+(a^2+x^2-1)^(1/2))/((a-1)*(a+1))+(1/2)*a*x^2/((a-1)*(a+1))+_C1]

-((a^2+x^2-1)^(1/2)*(a^2-1)*((2*a*x*(a^2+x^2-1)^(1/2)+a^4+(x^2-1)*a^2+x^2)/(a^2-1)^2)^(1/2)+a^3+a*x^2+x*(a^2+x^2-1)^(1/2)-a)/((a^2+x^2-1)^(1/2)*(a^2-1))

((-a^2+1)*(a^2+x^2-1)^(1/2)*((a^4+(x^2-1)*a^2-2*a*x*(a^2+x^2-1)^(1/2)+x^2)/(a^2-1)^2)^(1/2)+a^3+a*x^2-x*(a^2+x^2-1)^(1/2)-a)/((a^2+x^2-1)^(1/2)*(a^2-1))

#3136
#Book: Differential Equations, By George Boole F.R.S. 1865
#Section: Chapter 7
#Problem number: 15
restart;
ode:=y(x) =x*diff(y(x),x)+a*x*(diff(y(x),x)^2+1)^(1/2);
sol:=[dsolve(ode,y(x))];
odetest(sol[1],ode):
simplify(%):# output too large
odetest(sol[2],ode):
simplify(%):# output too large

y(x) = x*(diff(y(x), x))+a*x*((diff(y(x), x))^2+1)^(1/2)

[x-exp(arcsinh(((-a^2*x^2+x^2+y(x)^2)^(1/2)*a+y(x))/((a^2-1)*x))/a)*_C1/((-a^2*x^2+a^2*y(x)^2+2*(-a^2*x^2+x^2+y(x)^2)^(1/2)*a*y(x)+x^2+y(x)^2)/((a^2-1)^2*x^2))^(1/2) = 0, x-exp(-arcsinh(((-a^2*x^2+x^2+y(x)^2)^(1/2)*a-y(x))/((a^2-1)*x))/a)*_C1/(-(a^2*x^2-a^2*y(x)^2+2*(-a^2*x^2+x^2+y(x)^2)^(1/2)*a*y(x)-x^2-y(x)^2)/((a^2-1)^2*x^2))^(1/2) = 0]

#3138
#Book: Differential Equations, By George Boole F.R.S. 1865
#Section: Chapter 7
#Problem number: 17
restart;
ode:=x+y(x)*diff(y(x),x) = a*(diff(y(x),x)^2+1)^(1/2);
sol:=[dsolve(ode,y(x))];
odetest(sol[1],ode): #WARNING. hangs. try with timelimit

[y(x) = (a*(tan(RootOf(a^2*_Z^2*cos(2*_Z)+2*_C1*a*_Z*cos(2*_Z)+4*sin(_Z)*a*x*_Z-a^2*_Z^2+_C1^2*cos(2*_Z)+a^2*cos(2*_Z)+4*sin(_Z)*_C1*x-2*_C1*a*_Z-_C1^2+a^2-2*x^2))^2+1)^(1/2)-x)/tan(RootOf(a^2*_Z^2*cos(2*_Z)+2*_C1*a*_Z*cos(2*_Z)+4*sin(_Z)*a*x*_Z-a^2*_Z^2+_C1^2*cos(2*_Z)+a^2*cos(2*_Z)+4*sin(_Z)*_C1*x-2*_C1*a*_Z-_C1^2+a^2-2*x^2)), y(x) = (a*(tan(RootOf(a^2*_Z^2*cos(2*_Z)+2*_C1*a*_Z*cos(2*_Z)-4*sin(_Z)*a*x*_Z-a^2*_Z^2+_C1^2*cos(2*_Z)+a^2*cos(2*_Z)-4*sin(_Z)*_C1*x-2*_C1*a*_Z-_C1^2+a^2-2*x^2))^2+1)^(1/2)-x)/tan(RootOf(a^2*_Z^2*cos(2*_Z)+2*_C1*a*_Z*cos(2*_Z)-4*sin(_Z)*a*x*_Z-a^2*_Z^2+_C1^2*cos(2*_Z)+a^2*cos(2*_Z)-4*sin(_Z)*_C1*x-2*_C1*a*_Z-_C1^2+a^2-2*x^2))]

 


edit 12/23/2020

Found one more.

#3647
restart;
ode:=diff(y(x),x)=2*(x*sqrt(y(x))-1)*y(x);
ic:=y(0)=1;
sol:=dsolve([ode,ic]);
odetest(sol,ode);

The above becomes zero only for x>-1 

ps. I added this to the worksheet, but since upload now does not work, did not re upload so not to lose the display above. Will do that later when it is working.

 

edit 12/25/2020

Found one more.

#3607
#Book: Fundamentals of Differential Equations. By Nagle, Saff and Snider. 9th edition. Boston. Pearson 2018.
#Section: Chapter 2, First order differential equations. Section 2.2 Exercises. page 46
#Problem number: 19.

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

edit 12/26/2020

Found one more

#3613
#Book: Fundamentals of Differential Equations. By Nagle, Saff and Snider. 9th edition. Boston. Pearson 2018.
#Section: Chapter 2, First order differential equations. Section 2.2 Exercises. page 46
#Problem number: 26.

restart;
ode:=(x+1)*diff(y(x),x)+y(x)^(1/2) = 0;
ic:=y(0) = 1;
sol:=dsolve([ode,ic],y(x));
res:=odetest(sol,ode);

PDEtools:-Solve(res=0,x) assuming real;

edit 1/10/2021

Found one more

#2406
#Book: Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
#Problem number: 406.

restart;
ode:=(x^3+1)^(2/3)*diff(y(x),x)+(y(x)^3+1)^(2/3) = 0;
sol:=dsolve(ode,y(x));

check:=simplify(odetest(sol,ode));  #tried other simplication, can't get it to zero. But sol is correct

 

Download examples_of_odes_that_do_not_odetest.mw

Dear all,
I would like to get the Null Vectors of some matrix B but not those which are returned by NullSpace(B), i would like to get specific structure of the Kernel, i mean, i want to get the following structure of the Kernel when the matrix B is 10*10 for example:

Kernel= {
Vector[column](10, [0, 0, 0, 0, 0, 0, 0, 0, 0, alpha]),
Vector[column](10, [0, 0, 0, 0, 0, 0, 0, 0, alpha, beta]),
Vector[column](10, [0, 0, 0, 0, 0, 0, 0, alpha,beta, gamma]),
Vector[column](10, [0, 0, 0, 0, 0, 0, alpha, beta, gamma, delta])
              }
Is it possible to do that with Maple ? Have you some ideas ? 
In other words,  could you help me please ?

Best regards

First 26 27 28 29 30 31 32 Last Page 28 of 55