Peak and gravity constraints in Gaussian primordial density fields: an application of the Hoffman-Ribak method | Synapse