Internal
problem
ID
[720]
Book
:
Differential
equations
and
linear
algebra,
3rd
ed.,
Edwards
and
Penney
Section
:
Section
1.5.
Linear
first
order
equations.
Page
56
Problem
number
:
17
Date
solved
:
Tuesday, March 04, 2025 at 11:34:05 AM
CAS
classification
:
[_linear]
With initial conditions
ode:=y(x)+(1+x)*diff(y(x),x) = cos(x); ic:=y(0) = 1; dsolve([ode,ic],y(x), singsol=all);
ode=y[x]+(1+x)*D[y[x],x] == Cos[x]; ic=y[0]==1; DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
from sympy import * x = symbols("x") y = Function("y") ode = Eq((x + 1)*Derivative(y(x), x) + y(x) - cos(x),0) ics = {y(0): 1} dsolve(ode,func=y(x),ics=ics)