Internal
problem
ID
[18928]
Book
:
Differential
equations.
An
introduction
to
modern
methods
and
applications.
James
Brannan,
William
E.
Boyce.
Third
edition.
Wiley
2015
Section
:
Chapter
4.
Second
order
linear
equations.
Section
4.4
(Mechanical
and
electrical
vibration).
Problems
at
page
250
Problem
number
:
31
Date
solved
:
Thursday, October 02, 2025 at 03:33:02 PM
CAS
classification
:
[[_2nd_order, _missing_x]]
With initial conditions
ode:=m*diff(diff(y(x),x),x)+k*y(x) = 0; ic:=[y(0) = a, D(y)(0) = b]; dsolve([ode,op(ic)],y(x), singsol=all);
ode=m*D[y[x],{x,2}]+k*y[x]==0; ic={y[0]==a,Derivative[1][y][0] ==b}; DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
from sympy import * x = symbols("x") k = symbols("k") m = symbols("m") y = Function("y") ode = Eq(k*y(x) + m*Derivative(y(x), (x, 2)),0) ics = {y(0): a, Subs(Derivative(y(x), x), x, 0): b} dsolve(ode,func=y(x),ics=ics)