The determination of porosity is paramount because it determines the ultimate volume of a rock type that can contain hydrocarbons. For this job bulk volume can be determined by direct measurement or by fluid displacement. Calipers can be used to measure uniform samples directly, and bulk volume is calculated from the measured dimensions. This technique is not suited for non-cylindrical samples. For this type of samples bulk volume can also be determined by immersing a small sample in a non-wetting fluid. However, grain volume can be measured by the Boyle's law method. To measure grain volume, the sample is placed into a chamber of known volume. Helium, from a reference cell at known pressure, is then expanded into the sample chamber. The equilibrium pressure of the system is monitored and Boyle's Law is used to calculate the grain volume. Finally pore volume is determined by difference between bulk and grain volume and porosity is the ratio of pore volume to bulk volume of the sample.
This type of test is done on both whole cores and plug samples.