# Question:why Maple give completely different result for odetest depending on how the solution is written?

## Question:why Maple give completely different result for odetest depending on how the solution is written?

Maple 2022

What is the correct way to write the explicit solution before calling odetest to verify it on an ode? is it

sol:= y(x)= the RHS  (1)

or

sol:= y(x) - the RHS = 0 (2)

I am asking because Maple sometimes gives very different result from odetest depending on which form the explicit solution is written. It is very hard to keep trying different forms each time.  Here is an example below.

Maple 2022.1 on windows 10.   Is this a bug? I do not think it should  make a difference, but it does and I have no idea why. Is there an option or way to make sure the same result is obtained each time regardless how the explicit soltion is written?

I have a theory as to why this might happen: When using (1) odetest sees y(x) on the LHS on its own, and then uses odetest  code internally designed for explicit solution testing.

When using (2), it sees y(x) not on its own on the LHS and it assumes this is then an implicit solution and uses odetest code internally meant for implicit solution testing, hence the difference in output.

 > restart;
 > ode:=sqrt(y(x))+(1+x)*diff(y(x),x)=0: ic:=y(0) = 1: mysol:=y(x)=1/4*(ln(1+x)-2)^2: odetest(mysol,ode);

 > odetest((lhs-rhs)(mysol) = 0,ode);

 >
 >

Download why_different_result.mw

﻿