A discrete element method for composite media: one-dimensional heat conduction