In this paper we compare two different sampling methods for probing th
e distribution of conformations of a flexible molecule. The first meth
od makes use of a form of umbrella sampling which effectively enhances
the crossing of energy barriers. The second method, the so-called blu
e moon ensemble, is based on the use of an holonomic constraint which
fixes the reaction coordinate. We apply these methods to the evaluatio
n of the configurational free energy associated with the dihedral angl
e of one n-butane molecule in CCl4 and in gas phase. We analyse the na
ture and the influence, in the blue moon approach, of the compensating
term which arises from constraining the reaction coordinate and setti
ng its velocity to zero.