  We describe an algorithm for constructing N-body realisations of equilibrium
stellar systems. The algorithm complements existing orbit-based modelling
techniques using linear programming or other optimization algorithms. The
equilibria are constructed by integrating an N-body system while slowly
adjusting the masses of the particles until the time-averaged density field and
other observables converge to a prescribed value. The procedure can be arranged
to maximise a linear combination of the entropy of the system and the $\chi^2$
statistic for the observables. The equilibria so produced may be useful as
initial conditions for N-body simulations or for modelling observations of
individual galaxies.
