2.1.92 Problem 90

Solved using first_order_ode_riccati
Maple
Mathematica
Sympy

Internal problem ID [8803]
Book : Own collection of miscellaneous problems
Section : section 1.0
Problem number : 90
Date solved : Friday, April 25, 2025 at 05:11:43 PM
CAS classification : [_Riccati]

Solved using first_order_ode_riccati

Time used: 0.782 (sec)

Solve

yy2xx2=0

In canonical form the ODE is

y=F(x,y)=x2+y2+x

This is a Riccati ODE. Comparing the ODE to solve

y=x2+y2+x

With Riccati ODE standard form

y=f0(x)+f1(x)y+f2(x)y2

Shows that f0(x)=x2+x, f1(x)=0 and f2(x)=1. Let

y=uf2u(1)=uu

Using the above substitution in the given ODE results (after some simplification)in a second order ODE to solve for u(x) which is

(2)f2u(x)(f2+f1f2)u(x)+f22f0u(x)=0

But

f2=0f1f2=0f22f0=x2+x

Substituting the above terms back in equation (2) gives

u(x)+(x2+x)u(x)=0

Unable to solve. Will ask Maple to solve this ode now.

Solution obtained is

u(x)=2(c2(x+12)hypergeom([34i16],[32],i(2x+1)24)+c1hypergeom([14i16],[12],i(2x+1)24)2)eix(x+1)2

Taking derivative gives

u(x)=2(c2hypergeom([34i16],[32],i(2x+1)24)+(124+i2)c2(x+12)hypergeom([74i16],[52],i(2x+1)24)(2x+1)+(116+i4)c1hypergeom([54i16],[32],i(2x+1)24)(2x+1))eix(x+1)2+2(c2(x+12)hypergeom([34i16],[32],i(2x+1)24)+c1hypergeom([14i16],[12],i(2x+1)24)2)(i(x+1)2ix2)eix(x+1)2

Doing change of constants, the solution becomes

y=(2(hypergeom([34i16],[32],i(2x+1)24)+(124+i2)(x+12)hypergeom([74i16],[52],i(2x+1)24)(2x+1)+(116+i4)c5hypergeom([54i16],[32],i(2x+1)24)(2x+1))eix(x+1)2+2((x+12)hypergeom([34i16],[32],i(2x+1)24)+c5hypergeom([14i16],[12],i(2x+1)24)2)(i(x+1)2ix2)eix(x+1)2)eix(x+1)22((x+12)hypergeom([34i16],[32],i(2x+1)24)+c5hypergeom([14i16],[12],i(2x+1)24)2)

Which simplifies to

y=(4ix2+4ix+i4)hypergeom([34i16],[32],i(2x+1)24)+4((112i)(x+12)hypergeom([74i16],[52],i(2x+1)24)+c5((14i)hypergeom([54i16],[32],i(2x+1)24)+ihypergeom([14i16],[12],i(2x+1)24))2)(x+12)2hypergeom([34i16],[32],i(2x+1)24)(2x+1)+2c5hypergeom([14i16],[12],i(2x+1)24)
Figure 2.156: Slope field yy2xx2=0

Summary of solutions found

y=(4ix2+4ix+i4)hypergeom([34i16],[32],i(2x+1)24)+4((112i)(x+12)hypergeom([74i16],[52],i(2x+1)24)+c5((14i)hypergeom([54i16],[32],i(2x+1)24)+ihypergeom([14i16],[12],i(2x+1)24))2)(x+12)2hypergeom([34i16],[32],i(2x+1)24)(2x+1)+2c5hypergeom([14i16],[12],i(2x+1)24)
Maple. Time used: 0.002 (sec). Leaf size: 128
ode:=diff(y(x),x)-y(x)^2-x-x^2 = 0; 
dsolve(ode,y(x), singsol=all);
 
y=2(ix2+ix1+14i)c1hypergeom([34i16],[32],i(2x+1)24)+2((112i)(x+12)c1hypergeom([74i16],[52],i(2x+1)24)+(18i2)hypergeom([54i16],[32],i(2x+1)24)+ihypergeom([14i16],[12],i(2x+1)24)2)(x+12)(2x+1)c1hypergeom([34i16],[32],i(2x+1)24)+hypergeom([14i16],[12],i(2x+1)24)

Maple trace

Methods for first order ODEs: 
--- Trying classification methods --- 
trying a quadrature 
trying 1st order linear 
trying Bernoulli 
trying separable 
trying inverse linear 
trying homogeneous types: 
trying Chini 
differential order: 1; looking for linear symmetries 
trying exact 
Looking for potential symmetries 
trying Riccati 
trying Riccati Special 
trying Riccati sub-methods: 
   trying Riccati to 2nd Order 
   -> Calling odsolve with the ODE, diff(diff(y(x),x),x) = (-x^2-x)*y(x), y(x) 
      *** Sublevel 2 *** 
      Methods for second order ODEs: 
      --- Trying classification methods --- 
      trying a quadrature 
      checking if the LODE has constant coefficients 
      checking if the LODE is of Euler type 
      trying a symmetry of the form [xi=0, eta=F(x)] 
      checking if the LODE is missing y 
      -> Trying a Liouvillian solution using Kovacics algorithm 
      <- No Liouvillian solutions exists 
      -> Trying a solution in terms of special functions: 
         -> Bessel 
         -> elliptic 
         -> Legendre 
         -> Whittaker 
            -> hyper3: Equivalence to 1F1 under a power @ Moebius 
         -> hypergeometric 
            -> heuristic approach 
            -> hyper3: Equivalence to 2F1, 1F1 or 0F1 under a power @ Moebius 
            <- hyper3 successful: indirect Equivalence to 0F1 under ``^ @ Moebi\ 
us`` is resolved 
         <- hypergeometric successful 
      <- special function solution successful 
   <- Riccati to 2nd Order successful
 

Maple step by step

Let’s solveddxy(x)y(x)2xx2=0Highest derivative means the order of the ODE is1ddxy(x)Solve for the highest derivativeddxy(x)=y(x)2+x+x2
Mathematica. Time used: 0.275 (sec). Leaf size: 298
ode=D[y[x],x]-y[x]^2-x-x^2==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
y(x)i((2x+1)ParabolicCylinderD(12i8,(12+i2)(2x+1))c1(2x+1)ParabolicCylinderD(12+i8,(1+i)x+(12+i2))+(2+2i)(ParabolicCylinderD(12i8,(12+i2)(2x+1))ic1ParabolicCylinderD(12+i8,(1+i)x+(12+i2))))2(ParabolicCylinderD(12i8,(12+i2)(2x+1))+c1ParabolicCylinderD(12+i8,(1+i)x+(12+i2)))y(x)(1+i)ParabolicCylinderD(12+i8,(1+i)x+(12+i2))ParabolicCylinderD(12+i8,(1+i)x+(12+i2))12i(2x+1)y(x)(1+i)ParabolicCylinderD(12+i8,(1+i)x+(12+i2))ParabolicCylinderD(12+i8,(1+i)x+(12+i2))12i(2x+1)
Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-x**2 - x - y(x)**2 + Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
TypeError : bad operand type for unary -: list