calculus calculators

First-Order ODE Solver

Solves first-order linear ODEs of the form a·y' + b·y = c with an initial condition y(0). Use it for physics, engineering, or math coursework whenever you need y(x) instantly.

About this calculator

A first-order linear ODE with constant coefficients has the form a·(dy/dx) + b·y = c. Dividing through by a gives dy/dx + (b/a)·y = c/a, a standard linear equation. The homogeneous solution is y_h = C·e^(−b/a · x), where C is determined by the initial condition. A particular (constant) solution is y_p = −c/b (when b ≠ 0). The general solution is therefore y(x) = C·e^(−b/a · x) + (−c/b). Applying y(0) = y₀ gives C = y₀ − y_p, so the full solution is y(x) = (y₀ − y_p)·e^(−b/a · x) + y_p. This covers decay, growth, and forced-equilibrium scenarios common in RC circuits, population models, and heat transfer.

How to use

Suppose the equation is 2·y' + 4·y = 8 with y(0) = 1, and you want y(3). Enter a = 2, b = 4, c = 8, y(0) = 1, x = 3. The calculator computes r = −b/a = −2, y_p = −c/b = −2, C = y(0) − y_p = 1 − (−2) = 3. Then y(3) = 3·e^(−2·3) + (−2) = 3·e^(−6) − 2 ≈ 3·0.00248 − 2 ≈ −1.9925. The result is displayed instantly without manual integration.

Frequently asked questions

What form of differential equation does this solver handle?

This calculator handles first-order linear ODEs with constant coefficients of the form a·(dy/dx) + b·y = c. It does not solve nonlinear equations, systems of ODEs, or equations where the coefficients are functions of x. If your equation fits this form, simply identify a, b, and c and enter them directly. The solver also requires a single initial condition y(0) to determine the unique particular solution.

Why does the solution use an exponential function?

The homogeneous part of a first-order linear ODE always has the form C·e^(rx), where r = −b/a is the characteristic root. This exponential behavior arises because the rate of change of y is proportional to y itself — the defining property of exponential growth or decay. When a forcing constant c is present, a particular solution shifts the equilibrium away from zero. The full solution is the sum of these two components, capturing both the transient and steady-state behavior.

When should I set the constant term c to zero in the ODE solver?

Set c = 0 when your differential equation is homogeneous, meaning no external forcing term is present. Examples include unforced RC circuits (no voltage source) or uninhibited population growth/decay. In that case the particular solution y_p = 0 and the solution simplifies to y(x) = y₀·e^(−b/a · x). The behavior is purely exponential, growing if −b/a > 0 and decaying if −b/a < 0.