
And now we come to a model that has way more compartments than the one before.

A model for heat conduction in a wire.

Let's draw imaginary lines after each millimeter of that wire

and treat each millimeter as one compartment.

Every single compartment is treated in the same way,

so we can just look at one single of them to get an idea of what happening, let's take no. 8.

Compartment no. 8 loses a specific percentage of its energy

per time to compartments no. 7 and no. 9.

To be specific, let's say it's going to lose 1%/ms to the left and 1%/ms to the right,

but there will also an energy flow from compartment no. 7 to no. 8 with the same

percentage of the energy of no. 7 and there will be an energy flow

from compartment no. 9 to compartment no. 8.

Again, the same percentage but of the energy content of compartment no. 9.

So after a short amount (h) of time, the temperature of the compartment no. 8

will be its initial temperature plus that amount of time

times 1%/ms to be gaining 1%/ms from compartment no. 7

and we are gaining 1%/ms from compartment no. 9 but we are losing 1%/ms to the left and to the right

so we're losing thrice that percentage.

One final thing to be doing to clean things up a little, let's get rid of this 1%/ms here.

If we work with seconds instead, 1 second amounts to 1000 ms, so we need 1000%/s.

1000% is 10so now, we have an equation for the temperature

of the compartment no. 8 after one time step.

Of course, this works similarly for all other compartments.

We've just change the numbers. Its about the left neighbor, the right neighbor, and ourselves.