ecl-logo Documentation

UnitCoordinatesQ

UnitCoordinatesQ[val]bool

returns true if val is a set of coordinate pairs, either as a list of numbers, list of quanitties, or quantity array.

UnitCoordinatesQ[val,unitSpec]bool

also tests that the values in val match the units or constraints in unitSpec.

Details

    Input
    Output
    Attributes
  • HoldRest

Examples

Basic Examples  (5)

Match a list of numeric coordinates:

Match a list of quantity coordinates:

Match a quantity array of coordinates:

Match a list of quantity coordinates where each coordinates is {time,distance}:

Match a list of quantity coordinates along with constraints on the coordinate values:

Additional Examples  (8)

Does not match if unit dimensions incompatible:

Does not match if magnitude comparisons fail:

Mixed list of constraints:

List of date coordinates in a list:

List of date coordinates in a list with constraint:

List of date coordinates in a QA:

List of date coordinates in a QA with constraint:

Does not match a list of numeric coordinates if unit spec does not match:

Attributes  (1)

HoldRest  (1)

UnitCoordinatesQ has a HoldRest attribute: