The density of a material is defined as its mass per unit volume. The symbol of density is ρ
1. Formula
Mathematically:

where:
 (rho) is the density,
 is the mass,
 is the volume.
Different materials usually have different densities, so density is an important concept regarding buoyancy, metal purity and packaging.
In some cases density is expressed as the dimensionless quantities specific gravity (SG) or relative density (RD), in which case it is expressed in multiples of the density of some other standard material, usually water or air/gas.
2. History
In a wellknown story, Archimedes was given the task of determining whether King Hiero's goldsmith was embezzling gold during the manufacture of a wreath dedicated to the gods and replacing it with another, cheaper alloy. ^{[1]}
Archimedes knew that the irregularly shaped wreath could be crushed into a cube whose volume could be calculated easily and compared with the weight; but the king did not approve of this.
Baffled, Archimedes took a relaxing immersion bath and observed from the rise of the warm water upon entering that he could calculate the volume of the gold crown through the displacement of the water. Allegedly, upon this discovery, he went running naked through the streets shouting, "Eureka! Eureka!" (Greek "I found it"). As a result, the term "eureka" entered common parlance and is used today to indicate a moment of enlightenment.
This story first appeared in written form in Vitruvius' books of architecture, two centuries after it supposedly took place. ^{[2]} Some scholars have doubted the accuracy of this tale, saying among other things that the method would have required precise measurements that would have been difficult to make at the time. ^{[3]} ^{[4]}
3. Measurement of density
For a homogeneous object, the mass divided by the volume gives the density. The mass is normally measured with an appropriate scale or balance; the volume may be measured directly (from the geometry of the object) or by the displacement of a fluid. Hydrostatic weighing is a method that combines these two.
If the body is not homogeneous or heterogeneous, the density is a function of the coordinates , where is elementary volume with coordinates . The mass of the body then can be expressed as
 ,
where the integration is over the volume of the body V.
A very common instrument for the direct measurement of the density of a liquid is the hydrometer, which measures the volume displaced by an object of known mass. A common laboratory device for measuring fluid density is a pycnometer; a related device for measuring the absolute density of a solid is a gas pycnometer. Another instrument used to determine the density of a liquid or a gas is the digital density meter  based on the oscillating Utube principle.
The density of a solid material can be ambiguous, depending on exactly how its volume is defined, and this may cause confusion in measurement. A common example is sand: if gently filled into a container, the density will be low; when the same sand is compacted into the same container, it will occupy less volume and consequently exhibit a greater density. This is because sand, like all powders and granular solids contains a lot of air space in between individual grains; this overall density is called the bulk density, which differs significantly from the density of an individual grain of sand.
4. Common units
The SI unit for density is:
 kilograms per cubic metre (kg/m³)
The following nonSI metric units all have exactly the same numerical value, 1000 times the SI value in (kg/m³). Liquid water has a density of about 1kg/L (exactly 1.000 kg/L by definition at 4 °C), making any of these units numerically convenient to use as most solids and liquids have densities between 0.1 and 20 kg/L.; density is usually given in these units rather than the SI unit.
 kilograms per litre (kg/L).
 kilograms per cubic decimeter (kg/dm³),
 grams per millilitre (g/mL),
 grams per cubic centimeter (g/cc or g/cm³).
In U.S. customary units density can be stated in:
 Avoirdupois ounces per cubic inch (oz/cu in)
 Avoirdupois pounds per cubic inch (lb/cu in)
 pounds per cubic foot (lb/cu ft)
 pounds per cubic yard (lb/cu yd)
 pounds per U.S. liquid gallon or per U.S. dry gallon (lb/gal)
 pounds per U.S. bushel (lb/bu)
 slugs per cubic foot.
In principle there are Imperial units different from the above as the Imperial gallon and bushel differ from the U.S. units, but in practice they are no longer used, though found in older documents. The density of precious metals could conceivably be based on Troy ounces and pounds, a possible cause of confusion.
5. Changes of density
In general density can be changed by changing either the pressure or the temperature. Increasing the pressure will always increase the density of a material. Increasing the temperature generally decreases the density, but there are notable exceptions to this generalisation. For example, the density of water increases between its melting point at 0 °C and 4 °C and similar behaviour is observed in silicon at low temperatures.
The effect of pressure and temperature on the densities of liquids and solids is small so that a typical compressibility for a liquid or solid is 10^{6}bar^{1} (1 bar=0.1 MPa) and a typical thermal expansivity is 10^{5}K^{1}.
In contrast, the density of gases is strongly affected by pressure. Boyle's law says that the density of an ideal gas is given by

where is the universal gas constant, is the pressure, the molar mass, and the absolute temperature.
This means that a gas at 300 K and 1 bar will have its density doubled by increasing the pressure to 2 bar or by reducing the temperature to 150 K.
Osmium is the densest known substance at standard conditions for temperature and pressure.
6. Density of water
Temp (°C)  Density (kg/m^{3}) 

100  958.4 
80  971.8 
60  983.2 
40  992.2 
30  995.6502 
25  997.0479 
22  997.7735 
20  998.2071 
15  999.1026 
10  999.7026 
4  999.9720 
0  999.8395 
−10  998.117 
−20  993.547 
−30  983.854 
The density of water in kilograms per cubic meter (SI unit) at various temperatures in degrees Celsius. The values below 0 °C refer to supercooled water. 
7. Density of air
T in °C ρ in kg/m ^{3} (at 1 atm) 25 1.423 20 1.395 15 1.368 10 1.342 5 1.316 0 1.293 5 1.269 10 1.247 15 1.225 20 1.204 25 1.184 30 1.164 35 1.146
8. Density of solutions
The density of a solution is the sum of the mass (massic) concentrations of the components of that solution. Mass (massic) concentration of a given component ρ_{i} in a solution can be called partial density of that component.
9. Density of composite material
ASTM specification D79200 ^{[5]} describes the steps to measure the density of a composite material.
where:
 is the density of the composite material, in g/cm^{3}
and
 is the weight of the specimen when hung in the air
 is the weight of the partly immersed wire holding the specimen
 is the weight of the specimen when immersed fully in distilled water, along with the partly immersed wire holding the specimen
 is the density in g/cm^{3} of the distilled water at 23°C