The formula for density is the mass of an object divided by its volume. The formula can be expressed as d = m/V, where d is density, m is mass, and V is volume. Density is commonly expressed in units of grams per cubic centimeter or kilograms per cubic meter. The formula can be rearranged to calculate mass or volume given the other two measures. An easy way to remember the formula and the different rearrangements is to use a density mass volume triangle. It is important to be aware of the units being used when using the density formula to calculate density, mass, or volume. Sometimes, it may be necessary to convert a measure into different units.