Hi everybody!

I need to use the Crank-Nicolson method to solve the following Heat Equation (PDE), but unfortunately I haven't found yet any efficient material about it, neither books nor the web. I know what is its form, and other details about it, but in fact - how to do that thing - I have no idea...

My Equation:

(1) U(x,t)'t = a*U(x,t)''x

Initial & Boundary Conditions:

(2) U(x,0) = T0

(3) -k*U'(0,t)x = q

(4) -k*U'(d,t)x = h*(U(d,t)-T1)

when a, TO, T1, k, q, d, and h are all constants!

Pay attention that the conditions (3) and (4) are on the derivative of U.

Thanks (:

RedFox.