2.1.30 Problem 30

Solved using first_order_ode_riccati
Maple
Mathematica
Sympy

Internal problem ID [9013]
Book : First order enumerated odes
Section : section 1
Problem number : 30
Date solved : Friday, April 25, 2025 at 05:34:19 PM
CAS classification : [_Riccati]

Solved using first_order_ode_riccati

Time used: 0.145 (sec)

Solve

y=x+y+by2

In canonical form the ODE is

y=F(x,y)=by2+x+y

This is a Riccati ODE. Comparing the ODE to solve

y=by2+x+y

With Riccati ODE standard form

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

Shows that f0(x)=x, f1(x)=1 and f2(x)=b. Let

y=uf2u(1)=uub

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=bf22f0=b2x

Substituting the above terms back in equation (2) gives

bu(x)bu(x)+b2xu(x)=0

This is Airy ODE. It has the general form

au+bu+cux=F(x)

Where in this case

a=bb=bc=b2F=0

Therefore the solution to the homogeneous Airy ODE becomes

u=c1ex2AiryAi(b3x14b2b8/3)+c2ex2AiryBi(b3x14b2b8/3)

Will add steps showing solving for IC soon.

Taking derivative gives

u(x)=c1ex2AiryAi(b3x14b2b8/3)2c1ex2b1/3AiryAi(1,b3x14b2b8/3)+c2ex2AiryBi(b3x14b2b8/3)2c2ex2b1/3AiryBi(1,b3x14b2b8/3)

Doing change of constants, the solution becomes

y=c3ex2AiryAi(b3x14b2b8/3)2c3ex2b1/3AiryAi(1,b3x14b2b8/3)+ex2AiryBi(b3x14b2b8/3)2ex2b1/3AiryBi(1,b3x14b2b8/3)b(c3ex2AiryAi(b3x14b2b8/3)+ex2AiryBi(b3x14b2b8/3))

Which simplifies to

y=2c3b1/3AiryAi(1,4bx14b2/3)+2b1/3AiryBi(1,4bx14b2/3)c3AiryAi(4bx14b2/3)AiryBi(4bx14b2/3)2b(c3AiryAi(4bx14b2/3)+AiryBi(4bx14b2/3))

Summary of solutions found

y=2c3b1/3AiryAi(1,4bx14b2/3)+2b1/3AiryBi(1,4bx14b2/3)c3AiryAi(4bx14b2/3)AiryBi(4bx14b2/3)2b(c3AiryAi(4bx14b2/3)+AiryBi(4bx14b2/3))
Maple. Time used: 0.009 (sec). Leaf size: 105
ode:=diff(y(x),x) = x+y(x)+b*y(x)^2; 
dsolve(ode,y(x), singsol=all);
 
y=2AiryAi(1,4bx14b2/3)b1/3c1AiryAi(4bx14b2/3)c1+2AiryBi(1,4bx14b2/3)b1/3AiryBi(4bx14b2/3)2b(AiryAi(4bx14b2/3)c1+AiryBi(4bx14b2/3))

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 sub-methods: 
   <- Abel AIR successful: ODE belongs to the 0F1 0-parameter (Airy type) class
 

Maple step by step

Let’s solveddxy(x)=x+y(x)+by(x)2Highest derivative means the order of the ODE is1ddxy(x)Solve for the highest derivativeddxy(x)=x+y(x)+by(x)2
Mathematica. Time used: 0.205 (sec). Leaf size: 211
ode=D[y[x],x]==x+y[x]+b*y[x]^2; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
y(x)(b)2/3AiryBi(14bx(b)2/3)+2bAiryBiPrime(14bx(b)2/3)+c1(2bAiryAiPrime(14bx(b)2/3)(b)2/3AiryAi(14bx(b)2/3))2(b)5/3(AiryBi(14bx(b)2/3)+c1AiryAi(14bx(b)2/3))y(x)2b3AiryAiPrime(14bx(b)2/3)AiryAi(14bx(b)2/3)+12b
Sympy
from sympy import * 
x = symbols("x") 
b = symbols("b") 
y = Function("y") 
ode = Eq(-b*y(x)**2 - x - y(x) + Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
TypeError : bad operand type for unary -: list