First-Order Linear Differential Equation Calculator
Solve equations in the form:
Tip: this tool computes a closed-form solution and evaluates y(x) numerically.
What is a linear differential equation?
A linear differential equation is an equation involving a function and its derivatives where the function appears only to the first power (not squared, multiplied by itself, or inside nonlinear functions like sin(y)). In many science and engineering problems, linear ODEs are a core model.
The calculator above focuses on a common first-order linear constant-coefficient form:
This includes growth/decay with forcing, thermal processes, RC circuits, and many simplified dynamic systems.
How this calculator solves the equation
1) Normalize the equation
When a ≠ 0, divide through by a:
2) Solve the linear ODE
- If p ≠ 0, the general solution is y(x) = C·e-p x + q/p.
- If p = 0, the equation becomes y' = q, so y(x) = qx + C.
3) Apply the initial condition
The condition y(x0) = y0 determines C uniquely for standard cases, giving the specific solution that fits your system.
Worked example
Suppose:
- a = 2, b = 3, c = 12
- y(0) = 1
Then y' + (3/2)y = 6, so p = 1.5 and q = 6.
Steady-state term is q/p = 4, and the final solution is:
Using y(0)=1 gives C = -3, so:
Why first-order linear equations matter
- Physics: cooling/heating (Newton’s law), damped first-order dynamics.
- Electrical engineering: RC charging/discharging equations.
- Biology: simple population or concentration models with input/output.
- Economics: adjustment models toward long-run equilibrium.
Notes and limitations
This calculator is designed for constant coefficients (a, b, c as numbers). If your equation has x-dependent coefficients like y' + P(x)y = Q(x), the integrating factor method still works, but symbolic integration may be required and is beyond this simple numeric tool.
If you need that extended version, you can still use this page as a conceptual guide and verify special constant-coefficient cases quickly.