Resources For Teachers For Tutors For Students & Parents Pricing
Year 12 Specialist (Unit 3 & 4) Rates of change and differential equations

Differential equations (function of y)

20 practice questions 0 video lessons Theory + worked examples

Solve differential equations where the gradient depends only on y in Year 12 Specialist Mathematics for Queensland (QCAA). When the rate of change depends on the amount alone, you take reciprocals, integrate, and make the variable the subject.

You will learn to find general solutions (a family of curves) and to use an initial condition to pin down the particular solution — the method behind exponential growth, decay and Newton cooling models throughout the rates-of-change topic.

Create a free accountTrack your progress and save your work as you go.
Create free account

Theory

A differential equation of the form \(\dfrac{dy}{dx}=g(y)\) gives the gradient as a function of \(y\) alone. In Year 12 Specialist Mathematics (QCAA, Queensland) you solve it by turning it upside down — \(\dfrac{dx}{dy}=\dfrac{1}{g(y)}\) — then integrating to get \(x\) in terms of \(y\). Making \(y\) the subject gives the general solution; an initial condition fixes the constant for the particular solution.

A first-order differential equation of the form \(\dfrac{dy}{dx}=g(y)\) tells you the gradient in terms of \(y\) alone. You cannot integrate \(g(y)\) directly with respect to \(x\), because \(y\) is the unknown function of \(x\).

The key move is to take reciprocals: since \(\dfrac{dy}{dx}\) and \(\dfrac{dx}{dy}\) are reciprocals, \(\dfrac{dx}{dy}=\dfrac{1}{g(y)}\). Now the right-hand side is a function of \(y\), so you can integrate both sides with respect to \(y\): \(x=\displaystyle\int\dfrac{1}{g(y)}\,dy\). This is the same idea as separation of variables, written \(\displaystyle\int\dfrac{1}{g(y)}\,dy=\int 1\,dx\).

Integrating introduces one arbitrary constant \(c\). Rearranging to make \(y\) the subject gives the general solution — a whole family of curves, one for each value of the constant.

An initial condition (a known value of \(y\) at a given \(x\)) selects one member of that family. Substituting it to find the constant gives the particular solution, the single curve through that point.

The general solution of dy/dx = y is the family of curves y = A e to the x Three exponential curves y equals A times e to the x are drawn for A equal to a half, one and two. Together they form the family of general solutions. The curve with A equal to one passes through the point (0, 1); that initial condition selects one member of the family, the particular solution. x y (0, 1) y=eˣ A=2 A=½
General solution of \(\dfrac{dy}{dx}=y\): the family \(y=Ae^{x}\). The condition \(y(0)=1\) picks \(A=1\) (the bold curve) — the particular solution.
Cooling curve T = 25 + 60 e to the minus t A cooling curve for temperature T against time t. It starts at T equals eighty-five when t is zero and falls, levelling off towards the dashed horizontal asymptote at T equals twenty-five, the surrounding temperature. t T T=25 (0, 85) T=25+60e⁻ᵗ
Particular solution of the cooling equation \(\dfrac{dT}{dt}=-(T-25)\) with \(T(0)=85\): \(T=25+60e^{-t}\) starts at \(85\) and levels off at \(T=25\).

To solve \(\dfrac{dy}{dx}=g(y)\), take reciprocals and integrate with respect to \(y\):

\[ \dfrac{dx}{dy}=\dfrac{1}{g(y)}\ \Rightarrow\ x+c=\int\dfrac{1}{g(y)}\,dy \]
dxdy=1g(y)

Equivalently, separate the variables and integrate each side:

\[ \int\dfrac{1}{g(y)}\,dy=\int 1\,dx=x+c \]

The most common case is a rate proportional to the amount, \(\dfrac{dy}{dx}=ky\), whose general solution is exponential:

\[ \dfrac{dy}{dx}=ky\ \Rightarrow\ y=Ae^{kx} \]
y=Aekx

For a shifted linear rate \(\dfrac{dy}{dx}=k(y-a)\) the solution levels off from or towards \(y=a\):

\[ \dfrac{dy}{dx}=k(y-a)\ \Rightarrow\ y=a+Ae^{kx} \]
General then particular. Integrating always leaves one constant, so the general solution is a family. Apply the initial condition after you have the general solution to find the constant and pin down the particular solution.

Solving \(\dfrac{dy}{dx}=g(y)\)

  1. Take reciprocals: write \(\dfrac{dx}{dy}=\dfrac{1}{g(y)}\), so the right-hand side is a function of \(y\) you can integrate.
  2. Integrate both sides: \(x+c=\displaystyle\int\dfrac{1}{g(y)}\,dy\). Remember the single constant \(c\); for \(\int\dfrac{1}{y}\,dy\) you get \(\ln|y|\).
  3. Make \(y\) the subject: rearrange to \(y=\dots\) This is the general solution. When you exponentiate, the constant becomes a multiplier \(A=e^{c}\).
  4. Apply the initial condition: substitute the known \(x\) and \(y\) to find the constant, then write the particular solution.
Example 1 — Exponential growth (general)
Find the general solution of \(\dfrac{dy}{dx}=5y\).
Solution

Take reciprocals so the right-hand side is a function of \(y\):

\(\dfrac{dx}{dy}\)\(=\)\(\dfrac{1}{5y}\)

Integrate both sides with respect to \(y\):

\(x\)\(=\)\(\dfrac{1}{5}\int\dfrac{1}{y}\,dy\)
\(x+c\)\(=\)\(\dfrac{1}{5}\ln|y|\)

Make \(y\) the subject; the constant becomes a multiplier \(A=e^{5c}\):

\(\ln|y|\)\(=\)\(5x+5c\)
\(y\)\(=\)\(e^{5x}\,e^{5c}\)
\(y\)\(=\)\(Ae^{5x}\)

The general solution is \(y=Ae^{5x}\).

The general solution of dy/dx = y is the family of curves y = A e to the x Three exponential curves y equals A times e to the x are drawn for A equal to a half, one and two. Together they form the family of general solutions. The curve with A equal to one passes through the point (0, 1); that initial condition selects one member of the family, the particular solution. x y (0, 1) y=eˣ A=2 A=½
Example 2 — Shifted linear rate (general)
Find the general solution of \(\dfrac{dy}{dx}=4-y\).
Solution

Write the right-hand side as \(-(y-4)\), then take reciprocals:

\(\dfrac{dy}{dx}\)\(=\)\(-(y-4)\)
\(\dfrac{dx}{dy}\)\(=\)\(\dfrac{-1}{y-4}\)

Integrate both sides with respect to \(y\):

\(x\)\(=\)\(-\int\dfrac{1}{y-4}\,dy\)
\(x+c\)\(=\)\(-\ln|y-4|\)

Make \(y\) the subject; set \(A=e^{-c}\):

\(\ln|y-4|\)\(=\)\(-x-c\)
\(y-4\)\(=\)\(Ae^{-x}\)
\(y\)\(=\)\(4+Ae^{-x}\)

The general solution is \(y=4+Ae^{-x}\).

Example 3 — Power of \(y\) (particular)
Find the particular solution of \(\dfrac{dy}{dx}=y^{2}\) given that \(y=2\) when \(x=0\).
Solution

Take reciprocals and integrate the power of \(y\):

\(\dfrac{dx}{dy}\)\(=\)\(\dfrac{1}{y^{2}}\)
\(x+c\)\(=\)\(\int y^{-2}\,dy\)
\(x+c\)\(=\)\(-\dfrac{1}{y}\)

Apply \(y=2\) when \(x=0\) to find \(c\):

\(0+c\)\(=\)\(-\dfrac{1}{2}\)
\(c\)\(=\)\(-\dfrac{1}{2}\)

Substitute \(c\) and make \(y\) the subject:

\(x-\dfrac{1}{2}\)\(=\)\(-\dfrac{1}{y}\)
\(y\)\(=\)\(-\dfrac{1}{x-\tfrac{1}{2}}\)
\(y\)\(=\)\(\dfrac{2}{1-2x}\)

The particular solution is \(y=\dfrac{2}{1-2x}\).

Example 4 — Newton's law of cooling (particular)
A drink cools so that \(\dfrac{dT}{dt}=-(T-25)\), where \(T\) is in \(^{\circ}\)C after \(t\) minutes and \(T=85\) when \(t=0\). Find the particular solution and the long-term temperature.
Solution

Take reciprocals and integrate with respect to \(T\):

\(\dfrac{dt}{dT}\)\(=\)\(\dfrac{-1}{T-25}\)
\(t+c\)\(=\)\(-\ln|T-25|\)

Make \(T\) the subject; set \(A=e^{-c}\):

\(T-25\)\(=\)\(Ae^{-t}\)

Apply \(T=85\) when \(t=0\) to find \(A\):

\(85-25\)\(=\)\(Ae^{0}\)
\(A\)\(=\)\(60\)
\(T\)\(=\)\(25+60e^{-t}\)

As \(t\to\infty\), \(e^{-t}\to 0\):

\(T\)\(\to\)\(25\)

The particular solution is \(T=25+60e^{-t}\); the long-term temperature is \(25^{\circ}\)C.

Cooling curve T = 25 + 60 e to the minus t A cooling curve for temperature T against time t. It starts at T equals eighty-five when t is zero and falls, levelling off towards the dashed horizontal asymptote at T equals twenty-five, the surrounding temperature. t T T=25 (0, 85) T=25+60e⁻ᵗ

Common pitfalls

Integrating \(g(y)\) with respect to \(x\). You cannot write \(\int g(y)\,dx\) because \(y\) depends on \(x\). Take reciprocals first: \(\dfrac{dx}{dy}=\dfrac{1}{g(y)}\), then integrate with respect to \(y\).
Losing the constant, or adding it too late. Include \(+c\) as soon as you integrate. When you exponentiate, \(e^{c}\) becomes a single multiplier \(A\) — don't add a separate constant afterwards.
Dropping the modulus on \(\ln|y|\). Integrating \(\dfrac{1}{y}\) gives \(\ln|y|\). After exponentiating, the sign is absorbed into \(A\), which may be positive or negative.
Forgetting the initial condition. A general solution still has an unknown constant. To get the particular solution you must substitute the given point and solve for that constant.

Frequently asked questions

How do you solve dy/dx = g(y)?

Take reciprocals to get \(\dfrac{dx}{dy}=\dfrac{1}{g(y)}\), integrate both sides with respect to \(y\) so that \(x+c=\displaystyle\int\dfrac{1}{g(y)}\,dy\), then make \(y\) the subject.

What is the difference between a general and a particular solution?

The general solution contains the arbitrary constant from integrating — a whole family of curves. A particular solution uses an initial condition to fix that constant, giving one curve.

Why do you turn dy/dx = g(y) into dx/dy = 1/g(y)?

Because \(g(y)\) is a function of \(y\), not \(x\), you cannot integrate it with respect to \(x\). The reciprocal \(\dfrac{dx}{dy}=\dfrac{1}{g(y)}\) has a right-hand side in \(y\), which you can integrate.

What is the solution of dy/dx = ky?

Separating variables gives \(\ln|y|=kx+c\), so \(y=Ae^{kx}\) with \(A=e^{c}\). This exponential model appears in growth, decay and cooling problems.

Where does the constant A come from?

It is the integration constant. After integrating you have \(\ln|y|=kx+c\); exponentiating turns \(e^{c}\) into a single multiplier \(A\), which can be any non-zero real number.

How do you handle a cooling equation like dT/dt = -(T - a)?

It is the shifted linear case. Integrating gives \(T=a+Ae^{-t}\); apply the starting temperature to find \(A\). The temperature levels off towards \(a\), the surrounding temperature.