  We propose a theory which describes the density relaxation of loosely packed,
cohesionless granular material under mechanical tapping. Using the compactivity
concept we develope a formalism of statistical mechanics which allows us to
calculate the density of a powder as a function of time and compactivity. A
simple fluctuation-dissipation relation which relates compactivity to the
amplitude and frequency of a tapping is proposed. Experimental data of
E.R.Nowak et al. [{\it Powder Technology} 94, 79 (1997) ] show how density of
initially deposited in a fluffy state powder evolves under carefully controlled
tapping towards a random close packing (RCP) density. Ramping the vibration
amplitude repeatedly up and back down again reveals the existence of reversible
and irreversible branches in the response. In the framework of our approach the
reversible branch (along which the RCP density is obtained) corresponds to the
steady state solution of the Fokker-Planck equation whereas the irreversible
one is represented by a superposition of "excited states" eigenfunctions. These
two regimes of response are analyzed theoretically and a qualitative
explanation of the hysteresis curve is offered.
