section_path: Definition/In general relativity and cosmology
section_name: In general relativity and cosmology
paragraph_text: In general relativity and cosmology
  
  In the context of relativity, mass is not an additive quantity, in the sense that one cannot add the rest masses of particles in a system to get the total rest mass of the system. In relativity, usually a more general view is that it is not the sum of rest masses, but the energy–momentum tensor that quantifies the amount of matter. This tensor gives the rest mass for the entire system. Matter, therefore, is sometimes considered as anything that contributes to the energy–momentum of a system, that is, anything that is not purely gravity. This view is commonly held in fields that deal with general relativity such as cosmology. In this view, light and other massless particles and fields are all part of matter.