A scalar in physics and other areas of science is also ascalar in mathematics, as an element of amathematical field used to define avector space. For example, the magnitude (or length) of an electricfield vector is calculated as thesquare root of itsabsolute square (theinner product of the electric field with itself); so, the inner product's result is an element of the mathematical field for the vector space in which the electric field is described. As the vector space in this example and usual cases in physics is defined over the mathematical field ofreal numbers orcomplex numbers, the magnitude is also an element of the field, so it is mathematically a scalar. Since the inner product is independent of any vector space basis, the electric field magnitude is also physically a scalar.
The mass of an object is unaffected by a change of vector space basis so it is also a physical scalar, described by a real number as an element of the real number field. Since a field is a vector space with addition defined based onvector addition and multiplication defined asscalar multiplication, the mass is also a mathematical scalar.
Since scalars mostly may be treated as special cases of multi-dimensional quantities such asvectors andtensors,physical scalar fields might be regarded as a special case of more general fields, likevector fields,spinor fields, andtensor fields.
Like otherphysical quantities, a physicalquantity of scalar is also typically expressed by anumerical value and aphysical unit, not merely a number, to provide its physical meaning. It may be regarded as theproduct of the number and the unit (e.g., 1 km as a physical distance is the same as 1,000 m). A physical distance does not depend on the length of each base vector of the coordinate system where the base vector length corresponds to the physical distance unit in use. (E.g., 1 m base vector length means themeter unit is used.) A physical distance differs from ametric in the sense that it is not just a real number while the metric is calculated to a real number, but the metric can be converted to the physical distance by converting each base vector length to the corresponding physical unit.
Any change of a coordinate system may affect the formula for computing scalars (for example, theEuclidean formula for distance in terms of coordinates relies on the basis beingorthonormal), but not the scalars themselves. Vectors themselves also do not change by a change of a coordinate system, but their descriptions changes (e.g., a change of numbers representing aposition vector by rotating a coordinate system in use).
An example of a scalar quantity istemperature: the temperature at a given point is a single number. Velocity, on the other hand, is a vector quantity.
Other examples of scalar quantities aremass,charge,volume,time,speed,[2]pressure, andelectric potential at a point inside a medium. Thedistance between two points in three-dimensional space is a scalar, but thedirection from one of those points to the other is not, since describing a direction requires two physical quantities such as the angle on the horizontal plane and the angle away from that plane.Force cannot be described using a scalar, since force has both direction andmagnitude; however, the magnitude of a force alone can be described with a scalar, for instance thegravitational force acting on a particle is not a scalar, but its magnitude is. The speed of an object is a scalar (e.g., 180 km/h), while itsvelocity is not (e.g. a velocity of 180 km/h in a roughly northwest direction might consist of 108 km/h northward and 144 km/h westward). Some other examples of scalar quantities in Newtonian mechanics areelectric charge andcharge density.
Inphysics, a pseudoscalar denotes aphysical quantity analogous to a scalar. Both arephysical quantities which assume a single value which is invariant underproper rotations. However, under theparity transformation, pseudoscalars flip their signs while scalars do not. Asreflections through a plane are the combination of a rotation with the parity transformation, pseudoscalars also change signs under reflections.