salim-barzani

1555 Reputation

9 Badges

1 years, 12 days

MaplePrimes Activity


These are questions asked by salim-barzani

I’m trying to test a specific function as a solution to a nonlinear ODE in Maple. The equation is of the Riccati type, and my candidate solution involves parameters A, B, and C.

I've used assuming to specify the condition (4AC−B2)>0 and (4AC - B^2) <0, but when I use odetest to verify the solution, I still get a nonzero result. Additionally, when I apply the assumption, Maple sometimes introduces a negation sign in the output (e.g., changing sqrt(...) into -sqrt(...)), which wasn't part of the original solution.

restart

with(PDEtools)

with(LinearAlgebra)

with(Physics)

with(SolveTools)

undeclare(prime)

`There is no more prime differentiation variable; all derivatives will be displayed as indexed functions`

(1)

E := diff(G(xi), xi) = A+B*G(xi)+C*G(xi)^2

diff(G(xi), xi) = A+B*G(xi)+C*G(xi)^2

(2)

S1 := G(xi) = (sqrt(4*A*C-B^2)*tan((1/2)*sqrt(4*A*C-B^2)*(d[0]+xi))-B)/(2*C)

G(xi) = (1/2)*((4*A*C-B^2)^(1/2)*tan((1/2)*(4*A*C-B^2)^(1/2)*(d[0]+xi))-B)/C

(3)

odetest(S1, E)

0

(4)

S2 := G(xi) = -(sqrt(4*A*C-B^2)*cot((1/2)*sqrt(4*A*C-B^2)*(d[0]+xi))+B)/(2*C)

G(xi) = -(1/2)*((4*A*C-B^2)^(1/2)*cot((1/2)*(4*A*C-B^2)^(1/2)*(d[0]+xi))+B)/C

(5)

odetest(S2, E)

0

(6)

assume(4*A*C-B^2 < 0)

S3 := G(xi) = -(sqrt(4*A*C-B^2)*tanh((1/2)*sqrt(4*A*C-B^2)*(d[0]+xi))+B)/(2*C)

G(xi) = -(1/2)*((4*A*C-B^2)^(1/2)*tanh((1/2)*(4*A*C-B^2)^(1/2)*(d[0]+xi))+B)/C

(7)

odetest(S3, E)

-2*A+(1/2)*B^2/C

(8)

Download A2.mw

i did every thing coreectly but nothing happen not apply where is my mistake?

``

restart

with(PDEtools)

with(LinearAlgebra)

with(Physics)

with(SolveTools)

undeclare(prime)

`There is no more prime differentiation variable; all derivatives will be displayed as indexed functions`

(1)

NULL

S := (diff(G(xi), xi))^2-r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2) = 0

(diff(G(xi), xi))^2-r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2) = 0

(2)

SS := diff(G(xi), xi) = sqrt(r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2))

diff(G(xi), xi) = (r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2))^(1/2)

(3)

Se := sqrt(r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2)) = diff(G(xi), xi)

(r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2))^(1/2) = diff(G(xi), xi)

(4)

dub := diff(SS, xi)

diff(diff(G(xi), xi), xi) = (1/2)*(2*r^2*G(xi)*(a+b*G(xi)+l*G(xi)^2)*(diff(G(xi), xi))+r^2*G(xi)^2*(b*(diff(G(xi), xi))+2*l*G(xi)*(diff(G(xi), xi))))/(r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2))^(1/2)

(5)

Dubl2 := simplify(diff(diff(G(xi), xi), xi) = (1/2)*(2*r^2*G(xi)*(a+b*G(xi)+l*G(xi)^2)*(diff(G(xi), xi))+r^2*G(xi)^2*(b*(diff(G(xi), xi))+2*l*G(xi)*(diff(G(xi), xi))))/(r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2))^(1/2))

diff(diff(G(xi), xi), xi) = (1/2)*r^2*G(xi)*(diff(G(xi), xi))*(4*l*G(xi)^2+3*b*G(xi)+2*a)/(r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2))^(1/2)

(6)

subs(SA, Dubl2)

diff((r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2))^(1/2), xi) = (1/2)*r^2*G(xi)*(4*l*G(xi)^2+3*b*G(xi)+2*a)

(7)

subs(Se, Dubl2)

diff(diff(G(xi), xi), xi) = (1/2)*r^2*G(xi)*(diff(G(xi), xi))*(4*l*G(xi)^2+3*b*G(xi)+2*a)/(r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2))^(1/2)

(8)

subs(lhs(Se) = rhs(Se), Dubl2)

diff(diff(G(xi), xi), xi) = (1/2)*r^2*G(xi)*(diff(G(xi), xi))*(4*l*G(xi)^2+3*b*G(xi)+2*a)/(r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2))^(1/2)

(9)
 

NULL

Download subs.mw

I tried solving this ODE, but my result is very different from the expected one. How can I correctly obtain the solution? Also, is there a way to include both the positive and negative signs (±) in the equation so that the final result reflects both possibilities?

restart

with(PDEtools)

with(LinearAlgebra)

with(Physics)

with(SolveTools)

undeclare(prime)

`There is no more prime differentiation variable; all derivatives will be displayed as indexed functions`

(1)

_local(gamma)

Warning, A new binding for the name `gamma` has been created. The global instance of this name is still accessible using the :- prefix, :-`gamma`.  See ?protect for details.

 

declare(Omega(x, t)); declare(U(xi)); declare(u(x, y, z, t)); declare(Q(xi)); declare(V(xi))

Omega(x, t)*`will now be displayed as`*Omega

 

U(xi)*`will now be displayed as`*U

 

u(x, y, z, t)*`will now be displayed as`*u

 

Q(xi)*`will now be displayed as`*Q

 

V(xi)*`will now be displayed as`*V

(2)

``

ode := f*g^3*(diff(diff(U(xi), xi), xi))-4*f*p*U(xi)-6*k*l*U(xi)-f^3*g*(diff(diff(U(xi), xi), xi))+6*f*g*U(xi)^2 = 0

f*g^3*(diff(diff(U(xi), xi), xi))-4*f*p*U(xi)-6*k*l*U(xi)-f^3*g*(diff(diff(U(xi), xi), xi))+6*f*g*U(xi)^2 = 0

(3)

S := (diff(G(xi), xi))^2-r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2) = 0

(diff(G(xi), xi))^2-r^2*G(xi)^2*(a+b*G(xi)+l*G(xi)^2) = 0

(4)

S1 := dsolve(S, G(xi))

G(xi) = (1/2)*(-b+(-4*a*l+b^2)^(1/2))/l, G(xi) = -(1/2)*(b+(-4*a*l+b^2)^(1/2))/l, G(xi) = -4*a*exp(c__1*r*a^(1/2))/(exp(xi*r*a^(1/2))*(4*a*l-b^2+2*b*exp(c__1*r*a^(1/2))/exp(xi*r*a^(1/2))-(exp(c__1*r*a^(1/2)))^2/(exp(xi*r*a^(1/2)))^2)), G(xi) = -4*a*exp(xi*r*a^(1/2))/(exp(c__1*r*a^(1/2))*(4*a*l-b^2+2*b*exp(xi*r*a^(1/2))/exp(c__1*r*a^(1/2))-(exp(xi*r*a^(1/2)))^2/(exp(c__1*r*a^(1/2)))^2))

(5)

S2 := S1[3]

G(xi) = -4*a*exp(c__1*r*a^(1/2))/(exp(xi*r*a^(1/2))*(4*a*l-b^2+2*b*exp(c__1*r*a^(1/2))/exp(xi*r*a^(1/2))-(exp(c__1*r*a^(1/2)))^2/(exp(xi*r*a^(1/2)))^2))

(6)

normal(G(xi) = -4*a*exp(c__1*r*a^(1/2))/(exp(xi*r*a^(1/2))*(4*a*l-b^2+2*b*exp(c__1*r*a^(1/2))/exp(xi*r*a^(1/2))-(exp(c__1*r*a^(1/2)))^2/(exp(xi*r*a^(1/2)))^2)), ':-expanded')

G(xi) = 4*a*exp(c__1*r*a^(1/2))*exp(xi*r*a^(1/2))/(-4*a*l*(exp(xi*r*a^(1/2)))^2+b^2*(exp(xi*r*a^(1/2)))^2-2*b*exp(c__1*r*a^(1/2))*exp(xi*r*a^(1/2))+(exp(c__1*r*a^(1/2)))^2)

(7)

simplify(G(xi) = 4*a*exp(c__1*r*a^(1/2))*exp(xi*r*a^(1/2))/(-4*a*l*(exp(xi*r*a^(1/2)))^2+b^2*(exp(xi*r*a^(1/2)))^2-2*b*exp(c__1*r*a^(1/2))*exp(xi*r*a^(1/2))+(exp(c__1*r*a^(1/2)))^2))

G(xi) = -4*a*exp(a^(1/2)*r*(c__1+xi))/(4*a*l*exp(2*xi*r*a^(1/2))-b^2*exp(2*xi*r*a^(1/2))+2*b*exp(a^(1/2)*r*(c__1+xi))-exp(2*c__1*r*a^(1/2)))

(8)

convert(%, trig)

G(xi) = -4*a*(cosh(a^(1/2)*r*(c__1+xi))+sinh(a^(1/2)*r*(c__1+xi)))/(4*a*l*(cosh(2*xi*r*a^(1/2))+sinh(2*xi*r*a^(1/2)))-b^2*(cosh(2*xi*r*a^(1/2))+sinh(2*xi*r*a^(1/2)))+2*b*(cosh(a^(1/2)*r*(c__1+xi))+sinh(a^(1/2)*r*(c__1+xi)))-cosh(2*c__1*r*a^(1/2))-sinh(2*c__1*r*a^(1/2)))

(9)

convert(S1[3], trig)

G(xi) = -4*a*(cosh(c__1*r*a^(1/2))+sinh(c__1*r*a^(1/2)))/((cosh(xi*r*a^(1/2))+sinh(xi*r*a^(1/2)))*(4*a*l-b^2+2*b*(cosh(c__1*r*a^(1/2))+sinh(c__1*r*a^(1/2)))/(cosh(xi*r*a^(1/2))+sinh(xi*r*a^(1/2)))-(cosh(c__1*r*a^(1/2))+sinh(c__1*r*a^(1/2)))^2/(cosh(xi*r*a^(1/2))+sinh(xi*r*a^(1/2)))^2))

(10)

simplify(G(xi) = -4*a*(cosh(c__1*r*a^(1/2))+sinh(c__1*r*a^(1/2)))/((cosh(xi*r*a^(1/2))+sinh(xi*r*a^(1/2)))*(4*a*l-b^2+2*b*(cosh(c__1*r*a^(1/2))+sinh(c__1*r*a^(1/2)))/(cosh(xi*r*a^(1/2))+sinh(xi*r*a^(1/2)))-(cosh(c__1*r*a^(1/2))+sinh(c__1*r*a^(1/2)))^2/(cosh(xi*r*a^(1/2))+sinh(xi*r*a^(1/2)))^2)))

G(xi) = -4*a*(cosh(c__1*r*a^(1/2))+sinh(c__1*r*a^(1/2)))*(cosh(xi*r*a^(1/2))+sinh(xi*r*a^(1/2)))/((4*a*l-b^2)*cosh(xi*r*a^(1/2))^2+((8*a*l-2*b^2)*sinh(xi*r*a^(1/2))+2*b*(cosh(c__1*r*a^(1/2))+sinh(c__1*r*a^(1/2))))*cosh(xi*r*a^(1/2))+(4*a*l-b^2)*sinh(xi*r*a^(1/2))^2+2*b*(cosh(c__1*r*a^(1/2))+sinh(c__1*r*a^(1/2)))*sinh(xi*r*a^(1/2))-(cosh(c__1*r*a^(1/2))+sinh(c__1*r*a^(1/2)))^2)

(11)
   

Download tt.mw

In this work, I do not intend to expand all the variables across the monomials. Instead, I want to restrict the distribution to only the variables x,y,z,tx, y, z, tx,y,z,t, possibly raising them to appropriate powers as needed, until I obtain the desired solution and satisfy the conditions of my PDE tests. However, I am uncertain whether "monomial" is the correct term to use here.

S1.mw

trail-1.mw

I have a list of candidate solutions. Some of them satisfy my PDE test (i.e., they make the PDE equal to zero), while others do not. How can I separate the solutions that satisfy the PDE from those that do not?

Trail-pdetest.mw

5 6 7 8 9 10 11 Last Page 7 of 32