-
See Also
- UnitConvert
- CompatibleUnitQ
- UnitSimplify
-
- Interpreter Types
- Quantity
- Related Guides
- Tech Notes
UnitDimensions[unit]
returns a list of base dimensions associated with the specified unit.
UnitDimensions[quantity]
returns a list of base dimensions associated with the unit of the specified quantity.
UnitDimensions
UnitDimensions[unit]
returns a list of base dimensions associated with the specified unit.
UnitDimensions[quantity]
returns a list of base dimensions associated with the unit of the specified quantity.
Details
- UnitDimensions returns a list of ordered dimension pairs, indicating the magnitude of the unit in that dimension.
- Physical dimensions are: "AmountUnit", "ElectricCurrentUnit", "LengthUnit", "LuminousIntensityUnit", "MassUnit", "TemperatureUnit", and "TimeUnit".
- Additional unit dimensions include: "AngleUnit", "InformationUnit", "MoneyUnit", "PersonUnit" and "SolidAngleUnit".
- Temperatures and temperature differences share a common unit dimension.
- UnitDimensions accepts TimeSeries, EventSeries, and TemporalData inputs.
Examples
open all close allBasic Examples (2)
Get the dimensions associated with a unit:
UnitDimensions["Meters"]UnitDimensions[["1 newton"]]UnitDimensions[["8 volts"]]Get the dimensions associated with products of units:
UnitDimensions["Candelas" / "Inches" ^ 2]UnitDimensions[Quantity[3, "DegreesFahrenheit"*"Moles"]]Scope (3)
Get the unit dimensions from Quantity expressions in a time series:
data = EarthquakeData[All, {8, 10}, {{2011, 1, 1}, {2013, 1, 1}}, "Depth"]data[DateObject[{2012, 4, 11}]]UnitDimensions[data]%[DateObject[{2012, 4, 11}, "Day", "Gregorian", -6.]]Get the unit dimensions from Quantity expressions in structured arrays like QuantityArray or SymmetrizedArray objects:
UnitDimensions[QuantityArray[{1, 2, 3}, "Hectares"]]UnitDimensions[
SymmetrizedArray[{{1, 1} -> Quantity[2, "Liters"], {2, 1} -> Quantity[3, "Newtons"]}, {2, 2}, Symmetric[{1, 2}]]]Get the unit dimensions from Quantity expressions in SparseArray and Association specifications:
UnitDimensions[SparseArray[{1 -> Quantity[8, "Bits"], 2 -> Quantity[1, "Octets"]}]]UnitDimensions[<|"Distance" -> Quantity[260, "Miles"], "Duration" -> Quantity[3, "Hours"]|>]Applications (2)
Use UnitDimensions to examine the base dimension of a unit:
UnitDimensions["Pecks"]UnitDimensions["OortConstantA"]UnitDimensions["Ostents"]Use UnitDimensions to find the base dimension of a unit derived from SI base units:
UnitDimensions["Atmospheres"]UnitDimensions["HorsepowerMechanical"]Properties & Relations (9)
UnitDimensions returns the base dimension of a unit:
UnitDimensions[Quantity[3, "Spins"]]UnitDimensions[Quantity[7000, "WaterInches"]]The dimension pairs are returned lexically ordered:
UnitDimensions[Quantity[5, "Meters" * "Seconds"]]UnitDimensions[Quantity[5, "Seconds" * "Meters"]]UnitDimensions returns the argument of an IndependentUnit specification together with its power:
Quantity[3, "Kilometers" * IndependentUnit["myUnit"] ^ 2]UnitDimensions[%]UnitDimensions returns one dimension pair for a MixedUnit specification:
Quantity[MixedMagnitude[{5, 10}], MixedUnit[{"Feet", "Inches"}]]UnitDimensions[%]UnitDimensions ignores the date in DatedUnit specifications:
UnitDimensions[DatedUnit["Meters", 1889]]UnitDimensions[DatedUnit["USDollars", 2000]]An empty list is returned for units without dimension:
UnitDimensions[Quantity[72, "Percent"]]UnitDimensions[Quantity[98, "Scores"]]A unit given as a prefix only is dimensionless:
UnitDimensions[Quantity[100, "Hectometers"]]UnitDimensions[Quantity[100, "Hecto"]]UnitDimensions will automatically attempt to interpret an unknown unit string:
KnownUnitQ["feets"]UnitDimensions["feets"]KnownUnitQ["Feet"]UnitDimensions threads over lists:
UnitDimensions[{Quantity[7, "Meters"], Quantity[8, "Bits"], Quantity[5, "Ounces"]}]UnitDimensions[{Quantity[7, "Minutes"], {Quantity[2, "Radians"]}, Quantity[5, "Steradians"]}]Possible Issues (2)
Tech Notes
Related Guides
Text
Wolfram Research (2012), UnitDimensions, Wolfram Language function, https://reference.wolfram.com/language/ref/UnitDimensions.html (updated 2022).
CMS
Wolfram Language. 2012. "UnitDimensions." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2022. https://reference.wolfram.com/language/ref/UnitDimensions.html.
APA
Wolfram Language. (2012). UnitDimensions. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/UnitDimensions.html
BibTeX
@misc{reference.wolfram_2026_unitdimensions, author="Wolfram Research", title="{UnitDimensions}", year="2022", howpublished="\url{https://reference.wolfram.com/language/ref/UnitDimensions.html}", note=[Accessed: 13-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_unitdimensions, organization={Wolfram Research}, title={UnitDimensions}, year={2022}, url={https://reference.wolfram.com/language/ref/UnitDimensions.html}, note=[Accessed: 13-June-2026]}