Interacting hard rods on a lattice: Distribution of microstates and density functionals Article uri icon