Imagine a linear decrease in concentration from left to right. Using Fick's first law,

$J = -D \frac{d \psi}{d x}$

for all x, from left to right, we have the same flux amount because the decrease is linear.

So $J(x) = m$

According to Fick's second law,

$\frac{d \psi}{d t} = -D \frac{d^2 \psi}{d x^2} = \frac{d J}{d x}$

So $\frac{d J(x)}{d x} = 0$

so dJ/dx is just 0 since the 2nd derivative of a line is 0. Yet this seems unintuitive. I would expect as long as there is a concentration gradient, there should be a change in concentration at each point until the concentration is completely uniform. There must be an error in my math or reasoning, where is it?


To clarify the boundary conditions, imagine a closed box with no out flow or in flow at the edges.

  • 1
    $\begingroup$ If there is a concentration gradient, the concentration will change - but only later. At the very same time, there's just nonzero "acceleration", and it takes nonzero time for it to acquire a velocity. Your complaint is completely analogous to the complaint that $d^2 h/dt^2 = -g$ for the height of an apple is wrong because the apple should always fall down, even if it has a zero velocity. Well, velocity is independent of the acceleration. It's only the acceleration that is equal to $-g$, and the initial velocity may be 0 or anything. The same with velocity of the concentration. $\endgroup$ Commented Feb 12, 2011 at 7:14

2 Answers 2


As Ted Bunn said, the linear concentration profile is only a steady state if there is a steady inflow at one end and a steady outflow at the other. This net flow is what preserves the concentration gradient.

With the "closed box" boundary condition instead, there is indeed an error in your reasoning because the linear profile is no longer a steady state. So, to make things explicit, you should have instead:

$$\left.J(x)\right|_{t=0} = m$$ $$\left.\frac{\partial\psi}{\partial t}\right|_{t=0} = 0$$ for all x in the interior of the box.

However, these results do not imply that $\psi(x)$ is always constant. At time $t=0$, there is a constant flow from left to right, but because the box is closed this means that the concentration at the left edge of the box is decreasing and the concentration at the right edge is increasing (even though it hasn't yet begun to change anywhere in the interior - If you want, you can say that $\partial\psi/\partial t(t=0)$ has the form of two Dirac delta functions).

The only way I know to get the full solution is expanding in a Fourier series. For concreteness, say the box extends from $x=-1/2$ to $x=1/2$. The correct basis of eigenfunctions to use for this boundary condition contains functions whose derivative is zero at the edges of the box, namely $\sin(n \pi x)$ for odd n and $\cos(n \pi x)$ for even n. Since the initial condition is an odd function, the cosines don't appear. Also, for convenience, set the initial slope equal to $\pi^2/4$.

$$\psi(x,t=0) = \frac{\pi^2}{8} - \frac{\pi^2}{4} x = \frac{\pi^2}{8} - \sum_{n\text{ odd}} \frac{\sin(n\pi x)}{n^2}$$ (where the last equality is from the well-known Fourier series of a triangle wave) $$\psi(x,t) = \frac{\pi^2}{8} - \sum_{n\text{ odd}} \frac{\sin(n\pi x)}{n^2} e^{-nt/\tau}$$

where $\tau$ is a time scale that depends on the diffusion constant and dimensions (if you want, I can work out what it actually is, but it's irrelevant for the discussion).

If you plot this function at different $t$ values increasing from zero, you can clearly see that the concentration is becoming smoothed out and tending toward a uniform concentration of the average value, $\pi^2/8$.

Thus, even though at $t = 0$ it seems like the concentration isn't changing anywhere ($\partial\psi/\partial t$ = 0), it immediately begins changing, and diffusion does eventually lead to a uniform concentration.

Here are some plots I made, using terms through $n=15$:

enter image description here enter image description here enter image description here enter image description here

  • $\begingroup$ Thanks for the great answer. I have to remember to keep in mind the interesting stuff tends to happen at the boundary conditions so I always need to consider them for these types of physics problems. $\endgroup$
    – bmillare
    Commented Feb 12, 2011 at 16:09

The error is in your intuition. Your calculation is correct.

One thing that might help your intuition is to think about what happens at the edges of the region under consideration. There must be a steady inflow from one end and a steady outflow from the other end. Fluid is continually flowing "downhill" (from high concentration to low), but the source at the "top" constantly replenishes things, so the concentration gradient remains.

I don't know if that helps, but it's the best I can do.

  • 1
    $\begingroup$ Perhaps it's tidier to focus explicitly on the edges, and rephrase the problem/solution as a boundary value problem? $\endgroup$
    – genneth
    Commented Feb 12, 2011 at 1:31
  • 2
    $\begingroup$ I thought (although I guess it isn't explicitly stated) that the question was considering diffusion in a closed box with no inflow or outflow through the edges. $\endgroup$
    – David Z
    Commented Feb 12, 2011 at 2:34
  • 1
    $\begingroup$ @David, thats a good point, I didn't state the boundary conditions, but what I had in mind is what you said, a closed box with no inflow or outflow through the edges. I'll update the question. $\endgroup$
    – bmillare
    Commented Feb 12, 2011 at 5:28
  • $\begingroup$ I see. I was thinking that the $d\psi/dx$ retained its constant value even at the edges, which implies the inflow / outflow. Now that I understand the intended situation correctly, I agree with Keenan Pepper's excellent answer. $\endgroup$
    – Ted Bunn
    Commented Feb 12, 2011 at 14:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.